diff --git a/source/App/EncoderApp/EncApp.cpp b/source/App/EncoderApp/EncApp.cpp
index 650b41827acdd82a38c5c2628c457812c73655cd..8264ed35c8627e51b0bd93e2e1b04a835b0239d6 100644
--- a/source/App/EncoderApp/EncApp.cpp
+++ b/source/App/EncoderApp/EncApp.cpp
@@ -1353,7 +1353,7 @@ void EncApp::xInitLibCfg()
   m_cEncLib.setReshapeCW                                         ( m_reshapeCW );
   m_cEncLib.setReshapeCSoffset                                   ( m_CSoffset );
   m_cEncLib.setMaxNumALFAPS                                      (m_maxNumAlfAps);
-  m_cEncLib.setConstantJointCbCrSignFlag                         (m_constantJointCbCrSignFlag);
+  m_cEncLib.setConstantJointCbCrSignFlag                         (m_constantJointCbCrSignFlag != 0);
 #if JVET_O0756_CALCULATE_HDRMETRICS
   for (int i=0; i<hdrtoolslib::NB_REF_WHITE; i++)
   {
diff --git a/source/Lib/DecoderLib/VLCReader.cpp b/source/Lib/DecoderLib/VLCReader.cpp
index 0c19caaf960ada8a2e6afb8ebdfd0650a899e041..3192b492f306cf416ea970b34ca2e931e7f009bb 100644
--- a/source/Lib/DecoderLib/VLCReader.cpp
+++ b/source/Lib/DecoderLib/VLCReader.cpp
@@ -2705,7 +2705,7 @@ void HLSyntaxReader::parsePictureHeader( PicHeader* picHeader, ParameterSetManag
     if (pps->getAlfInfoInPhFlag())
     {
       READ_FLAG(uiCode, "ph_alf_enabled_flag");
-      picHeader->setAlfEnabledFlag(COMPONENT_Y, uiCode);
+      picHeader->setAlfEnabledFlag(COMPONENT_Y, uiCode != 0);
 
       int alfCbEnabledFlag = 0;
       int alfCrEnabledFlag = 0;
@@ -3214,7 +3214,7 @@ void HLSyntaxReader::parsePictureHeader( PicHeader* picHeader, ParameterSetManag
       }
       else
       {
-        picHeader->setPicColFromL0Flag(1);
+        picHeader->setPicColFromL0Flag(true);
       }
       if ((picHeader->getPicColFromL0Flag() == 1 && picHeader->getRPL(0)->getNumRefEntries() > 1) ||
         (picHeader->getPicColFromL0Flag() == 0 && picHeader->getRPL(1)->getNumRefEntries() > 1))
@@ -3229,7 +3229,7 @@ void HLSyntaxReader::parsePictureHeader( PicHeader* picHeader, ParameterSetManag
     }
     else
     {
-      picHeader->setPicColFromL0Flag(0);
+      picHeader->setPicColFromL0Flag(false);
     }
 
 
@@ -3273,13 +3273,13 @@ void HLSyntaxReader::parsePictureHeader( PicHeader* picHeader, ParameterSetManag
     }
     else
     {
-      if (sps->getBdofControlPresentInPhFlag() == 0)
+      if (!sps->getBdofControlPresentInPhFlag())
       {
-        picHeader->setBdofDisabledFlag(1 - (int)(sps->getBDOFEnabledFlag()));
+        picHeader->setBdofDisabledFlag(!sps->getBDOFEnabledFlag());
       }
       else
       {
-        picHeader->setBdofDisabledFlag(1);
+        picHeader->setBdofDisabledFlag(true);
       }
     }
 
@@ -3290,13 +3290,13 @@ void HLSyntaxReader::parsePictureHeader( PicHeader* picHeader, ParameterSetManag
     }
     else
     {
-      if (sps->getDmvrControlPresentInPhFlag() == 0)
+      if (!sps->getDmvrControlPresentInPhFlag())
       {
-        picHeader->setDmvrDisabledFlag(1 - (int)(sps->getUseDMVR()));
+        picHeader->setDmvrDisabledFlag(!sps->getUseDMVR());
       }
       else
       {
-        picHeader->setDmvrDisabledFlag(1);
+        picHeader->setDmvrDisabledFlag(true);
       }
     }
 
@@ -4274,12 +4274,12 @@ void HLSyntaxReader::parseSliceHeader (Slice* pcSlice, PicHeader* picHeader, Par
   if (sps->getSAOEnabledFlag() && !pps->getSaoInfoInPhFlag())
   {
     READ_FLAG(uiCode, "sh_sao_luma_used_flag");
-    pcSlice->setSaoEnabledFlag(CHANNEL_TYPE_LUMA, (bool) uiCode);
+    pcSlice->setSaoEnabledFlag(CHANNEL_TYPE_LUMA, uiCode != 0);
 
     if (hasChroma)
     {
       READ_FLAG(uiCode, "sh_sao_chroma_used_flag");
-      pcSlice->setSaoEnabledFlag(CHANNEL_TYPE_CHROMA, (bool) uiCode);
+      pcSlice->setSaoEnabledFlag(CHANNEL_TYPE_CHROMA, uiCode != 0);
     }
   }
 
@@ -4292,14 +4292,14 @@ void HLSyntaxReader::parseSliceHeader (Slice* pcSlice, PicHeader* picHeader, Par
     }
     else
     {
-      pcSlice->setDeblockingFilterOverrideFlag(0);
+      pcSlice->setDeblockingFilterOverrideFlag(false);
     }
     if (pcSlice->getDeblockingFilterOverrideFlag())
     {
       if (!pps->getPPSDeblockingFilterDisabledFlag())
       {
         READ_FLAG(uiCode, "sh_deblocking_filter_disabled_flag");
-        pcSlice->setDeblockingFilterDisable(uiCode ? 1 : 0);
+        pcSlice->setDeblockingFilterDisable(uiCode != 0);
       }
       else
       {
diff --git a/source/Lib/EncoderLib/EncCfg.h b/source/Lib/EncoderLib/EncCfg.h
index b40440efc19ba401025709c68d0cf84235919c61..3ed39d3892f848278ff95b535ef81b5a14626e28 100644
--- a/source/Lib/EncoderLib/EncCfg.h
+++ b/source/Lib/EncoderLib/EncCfg.h
@@ -2587,7 +2587,7 @@ public:
   void         setMaxNumALFAPS(int n)                                 { m_maxNumAlfAps = n; }
   int          getMaxNumALFAPS()                                const { return m_maxNumAlfAps; }
   void         setConstantJointCbCrSignFlag(bool b)                   { m_constantJointCbCrSignFlag = b; }
-  int          getConstantJointCbCrSignFlag()                   const { return m_constantJointCbCrSignFlag; }
+  bool         getConstantJointCbCrSignFlag()                   const { return m_constantJointCbCrSignFlag; }
 
   void         setUseALF( bool b ) { m_alf = b; }
   bool         getUseALF()                                      const { return m_alf; }
diff --git a/source/Lib/EncoderLib/EncGOP.cpp b/source/Lib/EncoderLib/EncGOP.cpp
index c669f359f7c322f120b8559c4f639cff62b37bf2..73a66cfbc1ebe6fa866dca132ff376b4593cc0ba 100644
--- a/source/Lib/EncoderLib/EncGOP.cpp
+++ b/source/Lib/EncoderLib/EncGOP.cpp
@@ -2896,27 +2896,27 @@ void EncGOP::compressGOP(int pocLast, int numPicRcvd, PicList &rcListPic, std::l
     {
       if (gopId == 0)   // first picture in SOP (i.e. forward B)
       {
-        picHeader->setEnableTMVPFlag(0);
+        picHeader->setEnableTMVPFlag(false);
       }
       else
       {
         // Note: pcSlice->getColFromL0Flag() is assumed to be always 0 and getcolRefIdx() is always 0.
-        picHeader->setEnableTMVPFlag(1);
+        picHeader->setEnableTMVPFlag(true);
       }
     }
     else if (m_pcEncLib->getTMVPModeId() == 1)
     {
-      picHeader->setEnableTMVPFlag(1);
+      picHeader->setEnableTMVPFlag(true);
     }
     else
     {
-      picHeader->setEnableTMVPFlag(0);
+      picHeader->setEnableTMVPFlag(false);
     }
 
     // disable TMVP when current picture is the only ref picture
     if (pcSlice->isIRAP() && pcSlice->getSPS()->getIBCFlag())
     {
-      picHeader->setEnableTMVPFlag(0);
+      picHeader->setEnableTMVPFlag(false);
     }
 
     if( pcSlice->getSliceType() != I_SLICE && picHeader->getEnableTMVPFlag() )
@@ -2987,7 +2987,7 @@ void EncGOP::compressGOP(int pocLast, int numPicRcvd, PicList &rcListPic, std::l
       }
       else
       {
-        picHeader->setEnableTMVPFlag( 0 );
+        picHeader->setEnableTMVPFlag( false );
       }
     }
 
@@ -3217,10 +3217,14 @@ void EncGOP::compressGOP(int pocLast, int numPicRcvd, PicList &rcListPic, std::l
     }
     if (pcSlice->getSPS()->getJointCbCrEnabledFlag())
     {
-      if (m_pcCfg->getConstantJointCbCrSignFlag()) 
-        pcPic->cs->picHeader->setJointCbCrSignFlag(m_pcCfg->getConstantJointCbCrSignFlag()-1);
+      if (m_pcCfg->getConstantJointCbCrSignFlag())
+      {
+        pcPic->cs->picHeader->setJointCbCrSignFlag(false);
+      }
       else
+      {
         m_pcSliceEncoder->setJointCbCrModes(*pcPic->cs, Position(0, 0), pcPic->cs->area.lumaSize());
+      }
     }
     if (!pcSlice->getSPS()->getSpsRangeExtension().getReverseLastSigCoeffEnabledFlag() || pcSlice->getSliceQp() > 12)
     {
diff --git a/source/Lib/EncoderLib/VLCWriter.cpp b/source/Lib/EncoderLib/VLCWriter.cpp
index 9efd42ea2b3a9f9534dc4f69ce605c659ef127cb..78ed0648c32c58b2c2ebe5c1779e831ba52a8f58 100644
--- a/source/Lib/EncoderLib/VLCWriter.cpp
+++ b/source/Lib/EncoderLib/VLCWriter.cpp
@@ -1822,7 +1822,7 @@ void HLSWriter::codePictureHeader( PicHeader* picHeader, bool writeRbspTrailingB
     }
     else
     {
-      picHeader->setVirtualBoundariesPresentFlag( 0 );
+      picHeader->setVirtualBoundariesPresentFlag( false );
       picHeader->setNumVerVirtualBoundaries( 0 );
       picHeader->setNumHorVirtualBoundaries( 0 );
     }
@@ -1928,7 +1928,7 @@ void HLSWriter::codePictureHeader( PicHeader* picHeader, bool writeRbspTrailingB
   }
   else
   {
-    picHeader->setSplitConsOverrideFlag(0);
+    picHeader->setSplitConsOverrideFlag(false);
   }
   // Q0781, two-flags
   if (picHeader->getPicIntraSliceAllowedFlag())
@@ -2057,7 +2057,7 @@ void HLSWriter::codePictureHeader( PicHeader* picHeader, bool writeRbspTrailingB
     }
     else
     {
-      picHeader->setBdofDisabledFlag(0);
+      picHeader->setBdofDisabledFlag(false);
     }
 
   // picture level DMVR disable flags
@@ -2067,7 +2067,7 @@ void HLSWriter::codePictureHeader( PicHeader* picHeader, bool writeRbspTrailingB
     }
     else
     {
-      picHeader->setDmvrDisabledFlag(0);
+      picHeader->setDmvrDisabledFlag(false);
     }
 
   // picture level PROF disable flags
@@ -2568,7 +2568,7 @@ void HLSWriter::codeSliceHeader         ( Slice* pcSlice, PicHeader *picHeader )
       }
       else
       {
-        pcSlice->setDeblockingFilterOverrideFlag(0);
+        pcSlice->setDeblockingFilterOverrideFlag(false);
       }
       if (pcSlice->getDeblockingFilterOverrideFlag())
       {