diff --git a/source/Lib/CommonLib/DepQuant.cpp b/source/Lib/CommonLib/DepQuant.cpp
index 7d2903c8ddc10018c4bb52fc622379910b00c83d..ca9a543523cf4c9684ba548c9f1b1b8b3658f204 100644
--- a/source/Lib/CommonLib/DepQuant.cpp
+++ b/source/Lib/CommonLib/DepQuant.cpp
@@ -1573,7 +1573,11 @@ DepQuant::~DepQuant()
 
 void DepQuant::quant( TransformUnit &tu, const ComponentID &compID, const CCoeffBuf &pSrc, TCoeff &uiAbsSum, const QpParam &cQP, const Ctx& ctx )
 {
+#if JVET_Q0089_SLICE_LOSSLESS_CODING_CHROMA_BDPCM
+  if ( tu.cs->picHeader->getDepQuantEnabledFlag() && !(tu.mtsIdx[compID] == MTS_SKIP && !tu.cs->slice->getTSResidualCodingDisabledFlag()))
+#else
   if ( tu.cs->picHeader->getDepQuantEnabledFlag() && (tu.mtsIdx[compID] != MTS_SKIP) )
+#endif
   {
     //===== scaling matrix ====
     const int         qpDQ            = cQP.Qp(tu.mtsIdx[compID] == MTS_SKIP) + 1;
@@ -1607,7 +1611,11 @@ void DepQuant::quant( TransformUnit &tu, const ComponentID &compID, const CCoeff
 
 void DepQuant::dequant( const TransformUnit &tu, CoeffBuf &dstCoeff, const ComponentID &compID, const QpParam &cQP )
 {
+#if JVET_Q0089_SLICE_LOSSLESS_CODING_CHROMA_BDPCM
+  if( tu.cs->picHeader->getDepQuantEnabledFlag() && !(tu.mtsIdx[compID] == MTS_SKIP && !tu.cs->slice->getTSResidualCodingDisabledFlag()))
+#else
   if( tu.cs->picHeader->getDepQuantEnabledFlag() && (tu.mtsIdx[compID] != MTS_SKIP))
+#endif
   {
     const int         qpDQ            = cQP.Qp(tu.mtsIdx[compID] == MTS_SKIP) + 1;
     const int         qpPer           = qpDQ / 6;
diff --git a/source/Lib/CommonLib/QuantRDOQ.cpp b/source/Lib/CommonLib/QuantRDOQ.cpp
index a811c59b29f0ee05db5adef222ffabcdbed06a9d..c9d12955a6c93416db511d6bb744bb05c24d7ad6 100644
--- a/source/Lib/CommonLib/QuantRDOQ.cpp
+++ b/source/Lib/CommonLib/QuantRDOQ.cpp
@@ -541,7 +541,18 @@ void QuantRDOQ::quant(TransformUnit &tu, const ComponentID &compID, const CCoeff
         }
         else
         {
+#if JVET_Q0089_SLICE_LOSSLESS_CODING_CHROMA_BDPCM
+          if (tu.cs->slice->getTSResidualCodingDisabledFlag())
+          {
+            xRateDistOptQuant( tu, compID, pSrc, uiAbsSum, cQP, ctx );
+          }
+          else
+          {
+            xRateDistOptQuantTS( tu, compID, pSrc, uiAbsSum, cQP, ctx );
+          }
+#else
           xRateDistOptQuantTS( tu, compID, pSrc, uiAbsSum, cQP, ctx );
+#endif
         }
       }
       else