Index: branches/HTM-14.1-update-dev1-RWTH/source/App/TAppEncoder/TAppEncCfg.cpp
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/App/TAppEncoder/TAppEncCfg.cpp	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/App/TAppEncoder/TAppEncCfg.cpp	(revision 1239)
@@ -2292,5 +2292,5 @@
 
   dimBitOffset[ 0 ] = 0; 
-  for (Int j = 1; j <= ((Int) m_dimIds.size() - m_splittingFlag ? 1 : 0); j++ )
+  for (Int j = 1; j <= (((Int) m_dimIds.size() - m_splittingFlag) ? 1 : 0); j++ )
   {
     dimBitOffset[ j ] = dimBitOffset[ j - 1 ] + m_dimensionIdLen[ j - 1]; 
Index: branches/HTM-14.1-update-dev1-RWTH/source/App/TAppRenderer/TAppRendererCfg.cpp
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/App/TAppRenderer/TAppRendererCfg.cpp	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/App/TAppRenderer/TAppRendererCfg.cpp	(revision 1239)
@@ -306,11 +306,11 @@
 
   Int iNumNonNULL;
-  for (iNumNonNULL = 0; (iNumNonNULL < m_iNumberOfInputViews)  && m_pchDepthInputFileList[iNumNonNULL]; iNumNonNULL++);  xConfirmPara( iNumNonNULL < m_iNumberOfInputViews,  "Number of DepthInputFiles  must be greater than or equal to number of BaseViewNumbers" );
-  for (iNumNonNULL = 0; (iNumNonNULL < m_iNumberOfInputViews)  && m_pchVideoInputFileList[iNumNonNULL]; iNumNonNULL++);  xConfirmPara( iNumNonNULL < m_iNumberOfInputViews,  "Number of DepthInputFiles  must be greater than or equal to number of BaseViewNumbers" );
+  for (iNumNonNULL = 0; (iNumNonNULL < m_iNumberOfInputViews)  && m_pchDepthInputFileList[iNumNonNULL]; iNumNonNULL++) {};  xConfirmPara( iNumNonNULL < m_iNumberOfInputViews,  "Number of DepthInputFiles  must be greater than or equal to number of BaseViewNumbers" );
+  for (iNumNonNULL = 0; (iNumNonNULL < m_iNumberOfInputViews)  && m_pchVideoInputFileList[iNumNonNULL]; iNumNonNULL++) {};  xConfirmPara( iNumNonNULL < m_iNumberOfInputViews,  "Number of DepthInputFiles  must be greater than or equal to number of BaseViewNumbers" );
 
 
   if ( !m_bSweep )
   {
-  for (iNumNonNULL = 0; (iNumNonNULL < m_iNumberOfOutputViews) && m_pchSynthOutputFileList[iNumNonNULL]; iNumNonNULL++); xConfirmPara( iNumNonNULL < m_iNumberOfOutputViews, "Number of SynthOutputFiles must be greater than or equal to number of SynthViewNumbers" );
+    for (iNumNonNULL = 0; (iNumNonNULL < m_iNumberOfOutputViews) && m_pchSynthOutputFileList[iNumNonNULL]; iNumNonNULL++) {}; xConfirmPara( iNumNonNULL < m_iNumberOfOutputViews, "Number of SynthOutputFiles must be greater than or equal to number of SynthViewNumbers" );
   }
   else
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TAppCommon/TAppComCamPara.cpp
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TAppCommon/TAppComCamPara.cpp	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TAppCommon/TAppComCamPara.cpp	(revision 1239)
@@ -1373,7 +1373,7 @@
   Int  iSourceViewNum = m_aiBaseViews[ iViewIdx ];
   Double dBaseLine = 0.0;
-  Double dFL1, dCS1, dCP1, dZN1, dZF1; 
-  Bool bInterpolated;
-  double dPos[3];
+  Double dFL1 = 0.0, dCS1 = 0.0, dCP1 = 0.0, dZN1 = 0.0, dZF1 = 0.0;
+  Bool bInterpolated = false;
+  double dPos[3] = {0.0, 0.0, 0.0};
 
   if( m_iNumberOfBaseViews == 3 )
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibCommon/TComCodingStatistics.h
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibCommon/TComCodingStatistics.h	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibCommon/TComCodingStatistics.h	(revision 1239)
@@ -102,4 +102,8 @@
   STATS__CABAC_BITS__DMMMODE,
   STATS__CABAC_BITS__DMM1_BITS_EP,
+#endif
+#if NH_3D_SDC_INTRA
+  STATS__CABAC_BITS__SDC_INTRA_FLAG,
+  STATS__CABAC_BITS__SDC_DELTADC_FLAG,
 #endif
 
@@ -164,4 +168,8 @@
    ,"STATS__CABAC_BITS__DMM1_BITS_EP"
 #endif
+#if NH_3D_SDC_INTRA
+    ,"STATS__CABAC_BITS__SDC_INTRA_FLAG"
+    ,"STATS__CABAC_BITS__SDC_DELTADC_FLAG"
+#endif
   };
   assert(STATS__NUM_STATS == sizeof(statNames)/sizeof(Char *) && name < STATS__NUM_STATS);
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibCommon/TComSlice.cpp
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibCommon/TComSlice.cpp	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibCommon/TComSlice.cpp	(revision 1239)
@@ -2032,6 +2032,6 @@
 Int TComVPS::scalTypeToScalIdx( ScalabilityType scalType ) const
 {
-  assert( scalType >= 0 && scalType <= MAX_NUM_SCALABILITY_TYPES ); 
-  assert( scalType == MAX_NUM_SCALABILITY_TYPES || getScalabilityMaskFlag( scalType ) );
+  assert( (Int)scalType >= 0 && (Int)scalType <= MAX_NUM_SCALABILITY_TYPES );
+  assert( (Int)scalType == MAX_NUM_SCALABILITY_TYPES || getScalabilityMaskFlag( scalType ) );
   Int scalIdx = 0; 
   for( Int curScalType = 0; curScalType < scalType; curScalType++ )
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecCAVLC.cpp
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecCAVLC.cpp	(revision 1239)
@@ -1831,5 +1831,5 @@
   else
   {
-    vpsVui->setVpsNumVideoSignalInfoMinus1( pcVPS->getMaxLayersMinus1() - pcVPS->getVpsBaseLayerInternalFlag() ? 0 : 1 ); 
+    vpsVui->setVpsNumVideoSignalInfoMinus1( (pcVPS->getMaxLayersMinus1() - pcVPS->getVpsBaseLayerInternalFlag()) ? 0 : 1 );
   }
 
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecGop.h
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecGop.h	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecGop.h	(revision 1239)
@@ -81,5 +81,5 @@
   TComLoopFilter*       m_pcLoopFilter;
 #if NH_MV
-  TDecTop*              m_decTop; 
+  //TDecTop*              m_decTop;
 #endif
 
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecSbac.cpp
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecSbac.cpp	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecSbac.cpp	(revision 1239)
@@ -2349,5 +2349,5 @@
   if( pcCU->isIntra( absPartIdx ) && pcCU->getSDCFlag( absPartIdx ))
   {
-    m_pcTDecBinIf->decodeBin( symbol, m_cDdcFlagSCModel.get( 0, 0, 0 ) );
+    m_pcTDecBinIf->decodeBin( symbol, m_cDdcFlagSCModel.get( 0, 0, 0 ) RExt__DECODER_DEBUG_BIT_STATISTICS_PASS_OPT_ARG(STATS__CABAC_BITS__SDC_DELTADC_FLAG) );
     assert( pcCU->getPartitionSize( absPartIdx ) == SIZE_2Nx2N );
     assert( pcCU->getTransformIdx(absPartIdx) == 0 );
@@ -2509,5 +2509,5 @@
   UInt uiSymbol = 0;
 
-  m_pcTDecBinIf->decodeBin( uiSymbol, m_cSDCFlagSCModel.get( 0, 0, 0 ) );
+  m_pcTDecBinIf->decodeBin( uiSymbol, m_cSDCFlagSCModel.get( 0, 0, 0 ) RExt__DECODER_DEBUG_BIT_STATISTICS_PASS_OPT_ARG(STATS__CABAC_BITS__SDC_INTRA_FLAG) );
 #if H_MV_ENC_DEC_TRAC
   DTRACE_CU("dc_only_flag", uiSymbol)
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecTop.h
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecTop.h	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibDecoder/TDecTop.h	(revision 1239)
@@ -107,5 +107,5 @@
   UInt    m_uiBitDepthForLUT;
   UInt    m_iLog2Precision;
-  UInt    m_uiInputBitDepth;
+  // UInt    m_uiInputBitDepth;
 
   // look-up tables
Index: branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibEncoder/TEncSearch.cpp
===================================================================
--- branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 1237)
+++ branches/HTM-14.1-update-dev1-RWTH/source/Lib/TLibEncoder/TEncSearch.cpp	(revision 1239)
@@ -3143,13 +3143,12 @@
 
 #if NH_3D_DMM
+    const TComRectangle &puRect=tuRecurseWithPU.getRect(COMPONENT_Y);
+    const UInt uiAbsPartIdx=tuRecurseWithPU.GetAbsPartIdxTU();
+    
+    Pel* piOrg         = pcOrgYuv ->getAddr( COMPONENT_Y, uiAbsPartIdx );
+    Pel* piPred        = pcPredYuv->getAddr( COMPONENT_Y, uiAbsPartIdx );
+    UInt uiStride      = pcPredYuv->getStride( COMPONENT_Y );
     if( m_pcEncCfg->getIsDepth() )
     {
-      const TComRectangle &puRect=tuRecurseWithPU.getRect(COMPONENT_Y);
-      const UInt uiAbsPartIdx=tuRecurseWithPU.GetAbsPartIdxTU();
-
-      Pel* piOrg         = pcOrgYuv ->getAddr( COMPONENT_Y, uiAbsPartIdx );
-      Pel* piPred        = pcPredYuv->getAddr( COMPONENT_Y, uiAbsPartIdx );
-      UInt uiStride      = pcPredYuv->getStride( COMPONENT_Y );
-
       if( puRect.width >= DMM_MIN_SIZE && puRect.width <= DMM_MAX_SIZE &&  puRect.width == puRect.height &&
           ((m_pcEncCfg->getUseDMM() &&  pcCU->getSlice()->getIntraSdcWedgeFlag()) || pcCU->getSlice()->getIntraContourFlag()) )
@@ -3229,5 +3228,5 @@
     DEBUG_STRING_NEW(sPU)
     UInt       uiBestPUMode  = 0;
-#if H_3D_FAST_INTRA_SDC
+#if NH_3D_ENC_DEPTH
     UInt    uiBestPUModeConv  = 0;
     UInt    uiSecondBestPUModeConv  = 0;
@@ -3242,7 +3241,7 @@
     Double     dBestPUCost   = MAX_DOUBLE;
 
-#if H_3D_FAST_INTRA_SDC
+#if NH_3D_ENC_DEPTH
     Double  dBestPUCostConv   = MAX_DOUBLE;
-    UInt varCU      = m_pcRdCost->calcVAR(piOrg, uiStride, uiWidth,uiHeight,pcCU->getDepth(0));
+    UInt varCU      = m_pcRdCost->calcVAR(piOrg, uiStride, puRect.width, puRect.height, pcCU->getDepth(0), pcCU->getSlice()->getSPS()->getMaxCUWidth());
     UInt rdSDC = m_pcEncCfg->getIsDepth() ? numModesForFullRD : 0;
 #endif
@@ -3251,5 +3250,5 @@
     Pel     apBestDCOffsets[2] = {0,0};
 #endif
-#if H_3D_FAST_INTRA_SDC
+#if NH_3D_ENC_DEPTH
     for( UInt uiMode = 0; uiMode < numModesForFullRD + rdSDC; uiMode++ )
 #else
@@ -3269,9 +3268,9 @@
     {
       // set luma prediction mode
-#if !H_3D_FAST_INTRA_SDC
+#if !NH_3D_ENC_DEPTH
       UInt uiOrgMode = uiRdModeList[uiMode];
 #endif
 
-#if H_3D_FAST_INTRA_SDC
+#if NH_3D_ENC_DEPTH
       UInt uiOrgMode;
       if (uiMode < numModesForFullRD)
@@ -3299,5 +3298,5 @@
 
 #if NH_3D_SDC_INTRA
-#if H_3D_FAST_INTRA_SDC
+#if NH_3D_ENC_DEPTH
       Bool bTestSDC = ( ( m_pcEncCfg->getUseSDC() &&  pcCU->getSlice()->getIntraSdcWedgeFlag() ) && pcCU->getSDCAvailable(uiPartOffset) && uiMode >= numModesForFullRD);
 #else
@@ -3307,5 +3306,5 @@
       for( UInt uiSDC=0; uiSDC<=(bTestSDC?1:0); uiSDC++ )
       {
-#if H_3D_FAST_INTRA_SDC
+#if NH_3D_ENC_DEPTH
         if (!uiSDC && uiMode >= numModesForFullRD) continue;
 #endif
@@ -3392,5 +3391,5 @@
 #if NH_3D_ENC_DEPTH
       xRecurIntraCodingLumaQT( pcOrgYuv, pcPredYuv, pcResiYuv, resiLumaPU, uiPUDistY, true, dPUCost, tuRecurseWithPU DEBUG_STRING_PASS_INTO(sMode), (zeroResi != 0) );
-#if H_3D_FAST_INTRA_SDC    
+#if NH_3D_ENC_DEPTH
               if( dPUCost < dBestPUCostConv )
               {
@@ -3624,5 +3623,5 @@
     if( !tuRecurseWithPU.IsLastSection() )
     {
-      const TComRectangle &puRect=tuRecurseWithPU.getRect(COMPONENT_Y);
+      //const TComRectangle &puRect=tuRecurseWithPU.getRect(COMPONENT_Y);
       const UInt  uiCompWidth   = puRect.width;
       const UInt  uiCompHeight  = puRect.height;
