Ticket #603: Bugfix_Ticket603.patch
File Bugfix_Ticket603.patch, 2.4 KB (added by Tanizawa, 12 years ago) |
---|
-
source/Lib/TLibCommon/TypeDef.h
40 40 41 41 //! \ingroup TLibCommon 42 42 //! \{ 43 44 #define BUGFIX_TICKET603 1 ///< bugfix for #603 45 43 46 #define TEMPORAL_ID_RESTRICTION 1 ///< I0600: Semantics of temporal_id changed 44 47 #define PREVREFPIC_DEFN 1 ///< I0345: prevRefPic defined as previous reference picture that is at same or lower 45 48 ///< temporal layer. -
source/Lib/TLibDecoder/TDecCAVLC.cpp
2691 2691 2692 2692 Int iDeltaChroma; 2693 2693 READ_SVLC( iDeltaChroma, "delta_chroma_offset_lX" ); // se(v): delta_chroma_offset_l0[i][j] 2694 #if BUGFIX_TICKET603 2695 Int Shift = ((1<<(g_uiBitDepth+g_uiBitIncrement-1))); 2696 Int Pred = ( Shift - ( ( Shift*wp[j].iWeight)>>(wp[j].uiLog2WeightDenom) ) ); 2697 wp[j].iOffset = iDeltaChroma + Pred; 2698 #else 2694 2699 wp[j].iOffset = iDeltaChroma - ( ( (g_uiIBDI_MAX>>1)*wp[j].iWeight)>>(wp[j].uiLog2WeightDenom) ) + (g_uiIBDI_MAX>>1); 2700 #endif 2695 2701 } 2696 2702 } 2697 2703 else -
source/Lib/TLibEncoder/TEncCavlc.cpp
1719 1719 Int iDeltaWeight = (wp[j].iWeight - (1<<wp[1].uiLog2WeightDenom)); 1720 1720 WRITE_SVLC( iDeltaWeight, "delta_chroma_weight_lX" ); // se(v): delta_chroma_weight_lX 1721 1721 1722 #if BUGFIX_TICKET603 1723 Int Shift = ((1<<(g_uiBitDepth+g_uiBitIncrement-1))); 1724 Int Pred = ( Shift - ( ( Shift*wp[j].iWeight)>>(wp[j].uiLog2WeightDenom) ) ); 1725 Int iDeltaChroma = (wp[j].iOffset - Pred); 1726 #else 1722 1727 Int iDeltaChroma = (wp[j].iOffset + ( ( (g_uiIBDI_MAX>>1)*wp[j].iWeight)>>(wp[j].uiLog2WeightDenom) ) - (g_uiIBDI_MAX>>1)); 1728 #endif 1723 1729 WRITE_SVLC( iDeltaChroma, "delta_chroma_offset_lX" ); // se(v): delta_chroma_offset_lX 1724 1730 } 1725 1731 }