Changeset 1313 in 3DVCSoftware for trunk/source/Lib/TLibCommon/TComPattern.h
- Timestamp:
- 13 Aug 2015, 17:38:13 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/Lib/TLibCommon/TComPattern.h
r1179 r1313 2 2 * License, included below. This software may be subject to other third party 3 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 4 * granted under this license. 5 5 * 6 * Copyright (c) 2010-2015, ITU/ISO/IEC6 * Copyright (c) 2010-2015, ITU/ISO/IEC 7 7 * All rights reserved. 8 8 * … … 40 40 41 41 // Include files 42 #include <stdio.h>43 42 #include "CommonDef.h" 44 43 … … 51 50 52 51 class TComDataCU; 52 class TComTU; 53 53 54 54 /// neighbouring pixel access class for one component … … 56 56 { 57 57 private: 58 Int m_iOffsetLeft; 59 Int m_iOffsetAbove; 60 Pel* m_piPatternOrigin; 61 58 Pel* m_piROIOrigin; 59 62 60 public: 63 61 Int m_iROIWidth; 64 62 Int m_iROIHeight; 65 63 Int m_iPatternStride; 66 67 /// return starting position of buffer 68 Pel* getPatternOrigin() { return m_piPatternOrigin; } 69 64 Int m_bitDepth; 65 70 66 /// return starting position of ROI (ROI = &pattern[AboveOffset][LeftOffset]) 71 67 __inline Pel* getROIOrigin() 72 68 { 73 return m_pi PatternOrigin + m_iPatternStride * m_iOffsetAbove + m_iOffsetLeft;69 return m_piROIOrigin; 74 70 } 75 71 76 72 /// set parameters from Pel buffer for accessing neighbouring pixels 77 Void setPatternParamPel ( Pel* piTexture, 78 Int iRoiWidth, 79 Int iRoiHeight, 80 Int iStride, 81 Int iOffsetLeft, 82 Int iOffsetAbove ); 83 84 /// set parameters of one color component from CU data for accessing neighbouring pixels 85 Void setPatternParamCU ( TComDataCU* pcCU, 86 UChar iComp, 87 UChar iRoiWidth, 88 UChar iRoiHeight, 89 Int iOffsetLeft, 90 Int iOffsetAbove, 91 UInt uiAbsZorderIdx ); 73 Void setPatternParamPel( Pel* piTexture, Int iRoiWidth, Int iRoiHeight, Int iStride, Int bitDepth ); 92 74 }; 93 75 … … 97 79 private: 98 80 TComPatternParam m_cPatternY; 99 TComPatternParam m_cPatternCb;100 TComPatternParam m_cPatternCr;101 #if H_3D_IC81 // TComPatternParam m_cPatternCb; 82 //TComPatternParam m_cPatternCr; 83 #if NH_3D_IC 102 84 Bool m_bICFlag; 103 85 #endif 104 #if H_3D_INTER_SDC86 #if NH_3D_SDC_INTER 105 87 Bool m_bSDCMRSADFlag; 106 88 #endif 107 static const UChar m_aucIntraFilter[5]; 108 89 90 109 91 public: 110 92 111 93 // ROI & pattern information, (ROI = &pattern[AboveOffset][LeftOffset]) 112 94 Pel* getROIY() { return m_cPatternY.getROIOrigin(); } … … 114 96 Int getROIYHeight() { return m_cPatternY.m_iROIHeight; } 115 97 Int getPatternLStride() { return m_cPatternY.m_iPatternStride; } 98 Int getBitDepthY() { return m_cPatternY.m_bitDepth; } 116 99 117 #if H_3D_IC100 #if NH_3D_IC 118 101 Bool getICFlag() { return m_bICFlag; } 119 102 Void setICFlag( Bool bICFlag ) { m_bICFlag = bICFlag; } 120 103 #endif 121 #if H_3D_INTER_SDC104 #if NH_3D_SDC_INTER 122 105 Bool getSDCMRSADFlag() { return m_bSDCMRSADFlag; } 123 106 Void setSDCMRSADFlag( Bool bSDCMRSADFlag ) { m_bSDCMRSADFlag = bSDCMRSADFlag; } 124 107 #endif 125 108 126 // access functions of ADI buffers127 Int* getAdiOrgBuf ( Int iCuWidth, Int iCuHeight, Int* piAdiBuf );128 Int* getAdiCbBuf ( Int iCuWidth, Int iCuHeight, Int* piAdiBuf );129 Int* getAdiCrBuf ( Int iCuWidth, Int iCuHeight, Int* piAdiBuf );130 131 Int* getPredictorPtr ( UInt uiDirMode, UInt uiWidthBits, Int* piAdiBuf );132 109 // ------------------------------------------------------------------------------------------------------------------- 133 110 // initialization functions 134 111 // ------------------------------------------------------------------------------------------------------------------- 135 112 136 113 /// set parameters from Pel buffers for accessing neighbouring pixels 137 Void initPattern ( Pel* piY, 138 Pel* piCb, 139 Pel* piCr, 140 Int iRoiWidth, 141 Int iRoiHeight, 142 Int iStride, 143 Int iOffsetLeft, 144 Int iOffsetAbove ); 145 146 /// set parameters from CU data for accessing neighbouring pixels 147 Void initPattern ( TComDataCU* pcCU, 148 UInt uiPartDepth, 149 UInt uiAbsPartIdx ); 150 151 /// set luma parameters from CU data for accessing ADI data 152 Void initAdiPattern ( TComDataCU* pcCU, 153 UInt uiZorderIdxInPart, 154 UInt uiPartDepth, 155 Int* piAdiBuf, 156 Int iOrgBufStride, 157 Int iOrgBufHeight, 158 Bool& bAbove, 159 Bool& bLeft 160 ,Bool bLMmode = false // using for LM chroma or not 161 ); 162 163 /// set chroma parameters from CU data for accessing ADI data 164 Void initAdiPatternChroma ( TComDataCU* pcCU, 165 UInt uiZorderIdxInPart, 166 UInt uiPartDepth, 167 Int* piAdiBuf, 168 Int iOrgBufStride, 169 Int iOrgBufHeight, 170 Bool& bAbove, 171 Bool& bLeft ); 172 173 private: 174 175 /// padding of unavailable reference samples for intra prediction 176 Void fillReferenceSamples (Int bitDepth, Pel* piRoiOrigin, Int* piAdiTemp, Bool* bNeighborFlags, Int iNumIntraNeighbor, Int iUnitSize, Int iNumUnitsInCu, Int iTotalUnits, UInt uiCuWidth, UInt uiCuHeight, UInt uiWidth, UInt uiHeight, Int iPicStride, Bool bLMmode = false); 177 178 179 /// constrained intra prediction 180 Bool isAboveLeftAvailable ( TComDataCU* pcCU, UInt uiPartIdxLT ); 181 Int isAboveAvailable ( TComDataCU* pcCU, UInt uiPartIdxLT, UInt uiPartIdxRT, Bool* bValidFlags ); 182 Int isLeftAvailable ( TComDataCU* pcCU, UInt uiPartIdxLT, UInt uiPartIdxLB, Bool* bValidFlags ); 183 Int isAboveRightAvailable ( TComDataCU* pcCU, UInt uiPartIdxLT, UInt uiPartIdxRT, Bool* bValidFlags ); 184 Int isBelowLeftAvailable ( TComDataCU* pcCU, UInt uiPartIdxLT, UInt uiPartIdxLB, Bool* bValidFlags ); 185 114 Void initPattern( Pel* piY, Int iRoiWidth, Int iRoiHeight, Int iStride, Int bitDepthLuma ); 186 115 }; 187 116
Note: See TracChangeset for help on using the changeset viewer.