Changeset 5 in 3DVCSoftware for trunk/source
- Timestamp:
- 12 Dec 2011, 18:35:44 (13 years ago)
- Location:
- trunk/source
- Files:
-
- 143 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/App/TAppCommon/TAppComCamPara.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppCommon/TAppComCamPara.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppCommon/program_options_lite.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 #include <stdlib.h> -
trunk/source/App/TAppCommon/program_options_lite.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 #include <iostream> -
trunk/source/App/TAppDecoder/TAppDecCfg.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppDecoder/TAppDecCfg.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppDecoder/TAppDecTop.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 48 81 m_apcBitstream = NULL; 49 82 } 50 #if SB_MEM_FIX51 83 if( m_pchBitstreamFile ) 52 84 { … … 57 89 free(m_pchReconFile); 58 90 } 59 #endif60 91 } 61 92 -
trunk/source/App/TAppDecoder/TAppDecTop.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 36 69 std::vector<TVideoIOYuv*> m_acTVideoIOYuvReconFileList; 37 70 std::vector<TVideoIOYuv*> m_acTVideoIOYuvDepthReconFileList; 38 71 39 72 Bool m_bUsingDepth; 40 73 41 74 // for output control 42 //SB can be deleted?43 75 Bool m_abDecFlag[ MAX_GOP ]; ///< decoded flag in one GOP 44 76 // Int m_iPOCLastDisplay; ///< last POC in display order … … 50 82 FILE* m_pScaleOffsetFile; 51 83 CamParsCollector m_cCamParsCollector; 84 #if DEPTH_MAP_GENERATION 52 85 TComSPSAccess m_cSPSAccess; 53 86 TComAUPicAccess m_cAUPicAccess; 54 87 #endif 88 55 89 public: 56 90 TAppDecTop(); 57 91 virtual ~TAppDecTop() {} 58 92 59 93 Void create (); ///< create internal members 60 94 Void destroy (); ///< destroy internal members … … 68 102 // GT FIX END 69 103 104 #if DEPTH_MAP_GENERATION 70 105 TComSPSAccess* getSPSAccess () { return &m_cSPSAccess; } 71 106 TComAUPicAccess* getAUPicAccess() { return &m_cAUPicAccess; } 72 107 #endif 108 73 109 protected: 74 110 Void xCreateDecLib (); ///< create internal classes 75 111 Void xDestroyDecLib (); ///< destroy internal classes 76 112 Void xInitDecLib (); ///< initialize decoder class 77 113 78 114 Void xWriteOutput ( TComList<TComPic*>* pcListPic ); ///< write YUV to file 79 115 }; -
trunk/source/App/TAppDecoder/decmain.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppEncoder/TAppEncCfg.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 39 72 { 40 73 m_aidQP = NULL; 41 //GTVSO74 #if HHI_VSO 42 75 m_aaiERViewRefLutInd.resize( MAX_INPUT_VIEW_NUM ); 43 //GT VSO end 76 #endif 44 77 } 45 78 … … 89 122 free (m_pchBaseViewCameraNumbers); 90 123 124 #if HHI_VSO 91 125 if ( m_pchVSOConfig != NULL) 92 126 free ( m_pchVSOConfig ); 127 #endif 93 128 94 129 } … … 172 207 173 208 /* Coding structure paramters */ 174 ("Code cPictureStoreSize,cpss", m_uiCodedPictureStoreSize, 16u, "Size of coded picture Buffer")209 ("CodedPictureStoreSize,cpss", m_uiCodedPictureStoreSize, 16u, "Size of coded picture Buffer") 175 210 #if DCM_DECODING_REFRESH 176 211 ("DecodingRefreshType,-dr",m_iDecodingRefreshType, 0, "intra refresh, (0:none 1:CDR 2:IDR)") … … 178 213 ("GOPSize,g", m_iGOPSize, 1, "GOP size of temporal structure") 179 214 ("RateGOPSize,-rg",m_iRateGOPSize, -1, "GOP size of hierarchical QP assignment (-1: implies inherit GOPSize value)") 180 #if ! SB_NO_LowDelayCoding215 #if !HHI_NO_LowDelayCoding 181 216 ("LowDelayCoding", m_bUseLDC, false, "low-delay mode") 182 217 #endif … … 221 256 ("LoopFilterBetaOffset", m_iLoopFilterBetaOffset, 0 ) 222 257 223 //GT campara 258 /* Camera Paremetes */ 224 259 ("CameraParameterFile,cpf", m_pchCameraParameterFile, (Char *) 0, "Camera Parameter File Name") 225 260 ("BaseViewCameraNumbers" , m_pchBaseViewCameraNumbers, (Char *) 0, "Numbers of base views") 226 //GT campara end 261 227 262 228 263 /* View Synthesis Optimization */ 229 //GT VSO 264 265 #if HHI_VSO 230 266 ("VSOConfig", m_pchVSOConfig , (Char *) 0 , "VSO configuration") 231 267 ("VSO", m_bUseVSO , false , "Use VSO" ) 232 268 // GT: For development, will be removed later 233 269 ("VSOMode", m_uiVSOMode , (UInt) 4 , "VSO Mode") 234 ("LambdaScaleVSO", m_dLambdaScaleVSO , (Double) 0. 6, "Lambda Scaling for VSO")270 ("LambdaScaleVSO", m_dLambdaScaleVSO , (Double) 0.5 , "Lambda Scaling for VSO") 235 271 ("ForceLambdaScaleVSO", m_bForceLambdaScaleVSO , false , "Force using Lambda Scale VSO also in non-VSO-Mode") 236 #if RDO_DIST_INT272 #if HHI_VSO_DIST_INT 237 273 ("AllowNegDist", m_bAllowNegDist , true , "Allow negative Distortion in VSO") 238 274 #endif … … 242 278 ("VSERViewReferences_%d,evr_%d" , m_aaiERViewRefInd , vector<Int>() , MAX_INPUT_VIEW_NUM, "Numbers of external virtual reference views to be used for this view") 243 279 ("VSBaseViewReferences_%d,bvr_%d", m_aaiBaseViewRefInd , vector<Int>() , MAX_INPUT_VIEW_NUM, "Numbers of external virtual reference views to be used for this view") 244 //GT VSO end 280 #endif 245 281 246 282 /* Coding tools */ … … 281 317 ("FEN", m_bUseFastEnc, false, "fast encoder setting") 282 318 283 #if HHI_DMM_INTRA 284 ("DMM", m_bUseDepthModelModes, false, "add depth modes intra") 285 #endif 319 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 320 ("DMM", m_bUseDMM, false, "add depth modes intra") 321 #endif 322 #if HHI_MPI 286 323 ("MVI", m_bUseMVI, false, "use motion vector inheritance for depth map coding") 324 #endif 287 325 288 326 /* Multiview tools */ 327 #if DEPTH_MAP_GENERATION 289 328 ("PredDepthMapGen", m_uiPredDepthMapGeneration, (UInt)0, "generation of prediction depth maps for motion data prediction" ) 329 #endif 330 #if HHI_INTER_VIEW_MOTION_PRED 290 331 ("MultiviewMvPred", m_uiMultiviewMvPredMode, (UInt)0, "usage of predicted depth maps" ) 291 332 ("MultiviewMvRegMode", m_uiMultiviewMvRegMode, (UInt)0, "regularization mode for multiview motion vectors" ) 292 333 ("MultiviewMvRegLambdaScale", m_dMultiviewMvRegLambdaScale, (Double)0, "lambda scale for multiview motion vector regularization" ) 334 #endif 335 #if HHI_INTER_VIEW_RESIDUAL_PRED 293 336 ("MultiviewResPred", m_uiMultiviewResPredMode, (UInt)0, "usage of inter-view residual prediction" ) 294 295 ("OmitUnusedBlocks", m_bOmitUnusedBlocks, false, "omit blocks not used for rendering") 337 #endif 296 338 297 339 ("QpChangeFrame", m_iQpChangeFrame, PicOrderCnt(0), "start frame for QP change") 298 340 ("QpChangeOffsetVideo", m_iQpChangeOffsetVideo, 0, "QP change offset for video") 299 341 ("QpChangeOffsetDepth", m_iQpChangeOffsetDepth, 0, "QP change offset for depth") 300 #if SB_INTERVIEW_SKIP342 #if HHI_INTERVIEW_SKIP 301 343 ("InterViewSkip", m_uiInterViewSkip, (UInt)0, "usage of interview skip" ) 302 #if SB_INTERVIEW_SKIP_LAMBDA_SCALE344 #if HHI_INTERVIEW_SKIP_LAMBDA_SCALE 303 345 ("InterViewSkipLambdaScale", m_dInterViewSkipLambdaScale, (Double)8, "lambda scale for interview skip" ) 304 346 #endif … … 387 429 //GT QP Depth end 388 430 389 //GTVSO431 #if HHI_VSO 390 432 m_bUseVSO = m_bUseVSO && m_bUsingDepthMaps && (m_uiVSOMode != 0); 391 //GT VSO end 433 #endif 392 434 393 435 xCleanUpVectors(); 394 436 437 #if HHI_VSO 395 438 if ( m_abUseALF .size() < 2) 396 439 m_abUseALF .push_back( m_bUseVSO ? false : m_abUseALF[0] ); 397 440 398 441 if ( m_abUseRDOQ.size() < 2) 399 m_abUseRDOQ.push_back( m_bUseVSO ? false : m_abUseRDOQ[0] );442 m_abUseRDOQ.push_back( m_bUseVSO ? true : m_abUseRDOQ[0] ); 400 443 401 444 if ( m_abLoopFilterDisable.size() < 2) … … 404 447 if (m_abUseSAO.size() < 2) 405 448 m_abUseSAO.push_back ( m_bUseVSO ? false : m_abUseSAO[0] ); 406 407 //GT VSO 449 #else 450 if ( m_abUseALF .size() < 2) 451 m_abUseALF .push_back( m_abUseALF[0] ); 452 453 if ( m_abUseRDOQ.size() < 2) 454 m_abUseRDOQ.push_back( m_abUseRDOQ[0] ); 455 456 if ( m_abLoopFilterDisable.size() < 2) 457 m_abLoopFilterDisable.push_back( m_abLoopFilterDisable[0] ); 458 459 if (m_abUseSAO.size() < 2) 460 m_abUseSAO.push_back ( m_abUseSAO[0] ); 461 #endif 462 463 #if HHI_VSO 408 464 if ( m_bUseVSO ) 409 465 { … … 423 479 } 424 480 } 425 //GT VSO end 481 #endif 426 482 427 483 // set global variables … … 429 485 430 486 // read and check camera parameters 487 #if HHI_VSO 431 488 if ( m_bUseVSO && m_uiVSOMode == 4) 432 489 { … … 468 525 NULL, 469 526 LOG2_DISP_PREC_LUT ); 470 471 } 527 } 528 #else 529 m_cCameraData .init ( (UInt)m_iNumberOfViews, 530 m_uiInputBitDepth, 531 (UInt)m_iCodedCamParPrecision, 532 m_FrameSkip, 533 (UInt)m_iFrameToBeEncoded, 534 m_pchCameraParameterFile, 535 m_pchBaseViewCameraNumbers, 536 NULL, 537 NULL, 538 LOG2_DISP_PREC_LUT ); 539 #endif 540 541 472 542 // check validity of input parameters 473 543 xCheckParameter(); … … 558 628 559 629 xConfirmPara ( m_iCodedCamParPrecision < 0 || m_iCodedCamParPrecision > 5, "CodedCamParsPrecision must be in range of 0..5" ); 630 #if DEPTH_MAP_GENERATION 560 631 xConfirmPara ( m_uiPredDepthMapGeneration > 3, "PredDepthMapGen must be less than or equal to 3" ); 561 632 xConfirmPara ( m_uiPredDepthMapGeneration >= 2 && !m_bUsingDepthMaps, "PredDepthMapGen >= 2 requires CodeDepthMaps = 1" ); 633 #endif 634 #if HHI_INTER_VIEW_MOTION_PRED 562 635 xConfirmPara ( m_uiMultiviewMvPredMode > 7, "MultiviewMvPred must be less than or equal to 7" ); 563 636 xConfirmPara ( m_uiMultiviewMvPredMode > 0 && m_uiPredDepthMapGeneration == 0 , "MultiviewMvPred > 0 requires PredDepthMapGen > 0" ); … … 568 641 xConfirmPara ( Int( m_pchDepthInputFileList.size() ) < m_iNumberOfViews, "MultiviewMvRegMode > 0 requires the presence of input depth maps" ); 569 642 } 643 #endif 644 #if HHI_INTER_VIEW_RESIDUAL_PRED 570 645 xConfirmPara ( m_uiMultiviewResPredMode > 1, "MultiviewResPred must be less than or equal to 1" ); 571 646 xConfirmPara ( m_uiMultiviewResPredMode > 0 && m_uiPredDepthMapGeneration == 0 , "MultiviewResPred > 0 requires PredDepthMapGen > 0" ); 572 573 #if SB_INTERVIEW_SKIP 647 #endif 648 649 #if HHI_INTERVIEW_SKIP 574 650 xConfirmPara ( m_uiInterViewSkip > 1, "RenderingSkipMode > 1 not supported" ); 575 651 xConfirmPara ( m_uiInterViewSkip > 0 && !m_bUsingDepthMaps, "RenderingSkipMode > 0 requires CodeDepthMaps = 1" ); 576 xConfirmPara ( m_uiInterViewSkip > 0 && !m_bOmitUnusedBlocks, "RenderingSkipMode > 0 requires OmitUnusedBlocks = 1" );577 652 #endif 578 653 if( m_bUsingDepthMaps ) … … 581 656 xConfirmPara ( Int( m_pchDepthReconFileList.size() ) < m_iNumberOfViews, "Number of DepthReconFiles must be greater than or equal to NumberOfViews" ); 582 657 583 //GTVSO658 #if HHI_VSO 584 659 if( m_bUseVSO ) 585 660 { … … 592 667 xConfirmPara( Int( m_pchERRefFileList .size() ) < m_iNumberOfExternalRefs, "Number of ERRefFileFiles must be greater than or equal to NumberOfExternalRefs" ); 593 668 } 594 //GT VSO end 669 #endif 595 670 } 596 671 597 672 #if DCM_COMB_LIST 598 #if ! SB_NO_LowDelayCoding673 #if !HHI_NO_LowDelayCoding 599 674 xConfirmPara( m_bUseLComb==false && m_bUseLDC==false, "LComb can only be 0 if LowDelayCoding is 1" ); 600 675 #else … … 659 734 xCleanUpVector( m_pchDepthReconFileList, (char*)0 ); 660 735 661 //GTVSO736 #if HHI_VSO 662 737 if ( m_bUseVSO) 663 738 { 664 739 xCleanUpVector( m_pchERRefFileList, (char*)0 ); 665 740 } 666 //GT VSO end 741 #endif 667 742 } 668 743 … … 784 859 printf("Coded Camera Param. Precision: %d\n", m_iCodedCamParPrecision); 785 860 786 //GTVSO861 #if HHI_VSO 787 862 printf("Force use of Lambda Scale : %d\n", m_bForceLambdaScaleVSO ); 788 863 … … 792 867 printf("VSO Mode : %d\n", m_uiVSOMode ); 793 868 printf("VSO Config : %s\n", m_pchVSOConfig ); 794 #if RDO_DIST_INT869 #if HHI_VSO_DIST_INT 795 870 printf("VSO Negative Distortion : %d\n", m_bAllowNegDist ? 1 : 0); 796 871 #endif 797 872 } 798 //GT VSO end 799 800 printf("Omit unused blocks : %d\n", (m_bOmitUnusedBlocks )?(1):(0)); 873 #endif 874 801 875 802 876 printf("\n"); … … 849 923 printf("SAO:%d ", (m_abUseSAO [1] ? 1 : 0)); 850 924 printf("RDQ:%d ", (m_abUseRDOQ[1] ? 1 : 0)); 925 #if HHI_VSO 851 926 printf("VSO:%d ", m_bUseVSO ); 852 #if HHI_DMM_INTRA 853 printf("DMM:%d ", m_bUseDepthModelModes ); 854 #endif 927 #endif 928 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 929 printf("DMM:%d ", m_bUseDMM ); 930 #endif 931 #if HHI_MPI 855 932 printf("MVI:%d ", m_bUseMVI ? 1 : 0 ); 933 #endif 856 934 printf("\n"); 857 935 -
trunk/source/App/TAppEncoder/TAppEncCfg.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 35 68 36 69 std::vector<char*> m_pchERRefFileList; ///< virtual external reference view files names 37 70 38 71 // source specification 39 72 Int m_iFrameRate; ///< source frame-rates (Hz) … … 44 77 Bool m_bUsePAD; ///< flag for using source padding 45 78 Int m_aiPad[2]; ///< number of padded pixels for width and height 46 79 47 80 Int m_iNumberOfViews; ///< number Views to Encode 48 81 Bool m_bUsingDepthMaps ; … … 56 89 Int m_iGOPSize; ///< GOP size of hierarchical structure 57 90 Int m_iRateGOPSize; ///< GOP size for QP variance 58 #if ! SB_NO_LowDelayCoding91 #if !HHI_NO_LowDelayCoding 59 92 Bool m_bUseLDC; ///< flag for using low-delay coding mode 60 93 #endif … … 63 96 Bool m_bLCMod; ///< flag for specifying whether the combined reference list for uni-prediction in B-slices is uploaded explicitly 64 97 #endif 65 // SB66 98 std::string m_cInputFormatString ; // GOP string 67 99 // coding quality 68 //GT QP Depth 100 69 101 std::vector<Double> m_adQP; ///< QP value of key-picture (floating point) [0] video, [1] depth 70 102 std::vector<Int> m_aiQP; ///< QP value of key-picture (integer) 71 //GT QP Depth end 103 72 104 Int m_aiTLayerQPOffset[MAX_TLAYER]; ///< QP offset corresponding to temporal layer depth 73 105 char* m_pchdQPFile; ///< QP offset for each slice (initialized from external file) … … 75 107 Int m_iMaxDeltaQP; ///< max. |delta QP| 76 108 UInt m_uiDeltaQpRD; ///< dQP range for multi-pass slice QP optimization 77 109 78 110 // coding unit (CU) definition 79 111 UInt m_uiMaxCUWidth; ///< max. CU width in pixel 80 112 UInt m_uiMaxCUHeight; ///< max. CU height in pixel 81 113 UInt m_uiMaxCUDepth; ///< max. CU depth 82 114 83 115 // transfom unit (TU) definition 84 116 UInt m_uiQuadtreeTULog2MaxSize; 85 117 UInt m_uiQuadtreeTULog2MinSize; 86 118 87 119 UInt m_uiQuadtreeTUMaxDepthInter; 88 120 UInt m_uiQuadtreeTUMaxDepthIntra; 89 121 90 122 // coding tools (bit-depth) 91 123 UInt m_uiInputBitDepth; ///< bit-depth of input file … … 95 127 #endif 96 128 UInt m_uiInternalBitDepth; ///< Internal bit-depth (BitDepth+BitIncrement) 97 129 98 130 #if MTK_SAO 99 vector<Bool> m_abUseSAO; 131 vector<Bool> m_abUseSAO; 100 132 #endif 101 133 … … 105 137 Int m_iALFEncodePassReduction; ///< ALF encoding pass, 0 = original 16-pass, 1 = 1-pass, 2 = 2-pass 106 138 #endif 107 139 108 140 vector<Bool> m_abLoopFilterDisable; ///< flag for using deblocking filter filter [0] - video, [1] - depth 109 141 Int m_iLoopFilterAlphaC0Offset; ///< alpha offset for deblocking filter 110 142 Int m_iLoopFilterBetaOffset; ///< beta offset for deblocking filter 111 143 112 144 // coding tools (entropy coder) 113 145 Int m_iSymbolMode; ///< entropy coder mode, 0 = VLC, 1 = CABAC 114 146 115 147 // coding tools (inter - merge motion partitions) 116 148 Bool m_bUseMRG; ///< SOPH: flag for using motion partition Merge Mode 117 118 #if LM_CHROMA 149 150 #if LM_CHROMA 119 151 Bool m_bUseLMChroma; ///< JL: Chroma intra prediction based on luma signal 120 152 #endif … … 123 155 Bool m_bUseRMP; 124 156 #endif 125 157 126 158 // coding tools (encoder-only parameters) 127 159 Bool m_bUseSBACRD; ///< flag for using RD optimization based on SBAC … … 134 166 Bool m_bUseFastEnc; ///< flag for using fast encoder setting 135 167 168 #if DEPTH_MAP_GENERATION 136 169 UInt m_uiPredDepthMapGeneration; ///< using of (virtual) depth maps for texture coding 170 #endif 171 #if HHI_INTER_VIEW_MOTION_PRED 137 172 UInt m_uiMultiviewMvPredMode; ///< usage of predictors for multi-view mv prediction 138 173 UInt m_uiMultiviewMvRegMode; ///< regularization for multiview motion vectors 139 174 Double m_dMultiviewMvRegLambdaScale; ///< lambda scale for multiview motion vectors regularization 175 #endif 176 #if HHI_INTER_VIEW_RESIDUAL_PRED 140 177 UInt m_uiMultiviewResPredMode; ///< using multiview residual prediction 141 142 #if SB_INTERVIEW_SKIP 178 #endif 179 180 #if HHI_INTERVIEW_SKIP 143 181 UInt m_uiInterViewSkip; ///< usage of interview skip mode ( do not transmit residual) 144 #if SB_INTERVIEW_SKIP_LAMBDA_SCALE182 #if HHI_INTERVIEW_SKIP_LAMBDA_SCALE 145 183 Double m_dInterViewSkipLambdaScale; ///< lambda scale for interview skip 146 184 #endif 147 185 #endif 148 //GT campara 186 149 187 // camera parameter 150 188 Char* m_pchCameraParameterFile; ///< camera parameter file 151 189 Char* m_pchBaseViewCameraNumbers; 152 TAppComCamPara m_cCameraData; 153 //GT campara end 190 TAppComCamPara m_cCameraData; 191 154 192 Int m_iCodedCamParPrecision; ///< precision for coding of camera parameters 155 193 194 #if HHI_INTERVIEW_SKIP 156 195 TRenTop m_cUsedPelsRenderer; ///< renderer for used pels map 157 158 //GT VSO 159 Char* m_pchVSOConfig; 160 Bool m_bUseVSO; ///< flag for using View Synthesis Optimization 161 162 //// Used for development by GT, might be removed later 196 #endif 197 198 #if HHI_VSO 199 Char* m_pchVSOConfig; 200 Bool m_bUseVSO; ///< flag for using View Synthesis Optimization 201 202 //// Used for development by GT, might be removed later 163 203 Double m_dLambdaScaleVSO; ///< Scaling factor for Lambda in VSO mode 164 204 Bool m_bForceLambdaScaleVSO; ///< Use Lambda Scale for depth even if VSO is turned off 165 #if RDO_DIST_INT166 Bool m_bAllowNegDist; ///< Allow negative distortion in VSO 167 #endif 168 UInt m_uiVSOMode; ///< Number of VSO Mode, 1 = , 2 = simple, org vs. ren, 3 = simple, ren vs. ren, 4 = full 205 #if HHI_VSO_DIST_INT 206 Bool m_bAllowNegDist; ///< Allow negative distortion in VSO 207 #endif 208 UInt m_uiVSOMode; ///< Number of VSO Mode, 1 = , 2 = simple, org vs. ren, 3 = simple, ren vs. ren, 4 = full 169 209 Int m_iNumberOfExternalRefs; ///< number Virtual External Reference Views 170 210 std::vector< std::vector<Int> > m_aaiBaseViewRefInd; ///< View numbers of Base View References 171 211 std::vector< std::vector<Int> > m_aaiERViewRefInd; ///< View numbers of External ViewReferences 172 212 std::vector< std::vector<Int> > m_aaiERViewRefLutInd; ///< Indices of LUTs used for External View References 173 174 //GT VSO end 175 213 #endif 214 176 215 Int m_iSliceMode; ///< 0: Disable all Recon slice limits, 1 : Maximum number of largest coding units per slice, 2: Maximum number of bytes in a slice 177 216 Int m_iSliceArgument; ///< If m_iSliceMode==1, m_iSliceArgument=max. # of largest coding units. If m_iSliceMode==2, m_iSliceArgument=max. # of bytes. … … 188 227 Bool m_bUseConstrainedIntraPred; ///< flag for using constrained intra prediction 189 228 #endif 190 #if HHI_DMM_INTRA 191 Bool m_bUseDepthModelModes; 192 #endif 229 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 230 Bool m_bUseDMM; 231 #endif 232 #if HHI_MPI 193 233 Bool m_bUseMVI; ///< flag for using Motion Vector Inheritance for depth map coding 194 Bool m_bOmitUnusedBlocks; ///< flag for not coding blocks not used for rendering 234 #endif 195 235 196 236 PicOrderCnt m_iQpChangeFrame; … … 211 251 Void xPrintParameter (); ///< print configuration values 212 252 Void xPrintUsage (); ///< print usage 213 253 214 254 Void xCleanUpVectors (); ///< clean up vector sizes 215 255 Void xInitCameraPars (); ///< init camera parameters … … 221 261 222 262 // util 223 Void xAppendToFileNameEnd( Char* pchInputFileName, const Char* pchStringToAppend, Char* & rpchOutputFileName); 263 Void xAppendToFileNameEnd( Char* pchInputFileName, const Char* pchStringToAppend, Char* & rpchOutputFileName); 224 264 Bool xConfirmParameter(Bool bflag, const char* message); 225 265 … … 227 267 template <class T> Void xCleanUpVector( std::vector<T>& rcVec, const T& rcInvalid ); 228 268 269 #if HHI_VSO 229 270 // Ren Model String 230 TRenModSetupStrParser m_cRenModStrParser; 271 TRenModSetupStrParser m_cRenModStrParser; 272 #endif 231 273 public: 232 274 233 275 TAppEncCfg(); 234 276 virtual ~TAppEncCfg(); 235 277 236 278 public: 237 279 Void create (); ///< create option handling class 238 280 Void destroy (); ///< destroy option handling class 239 281 Bool parseCfg ( Int argc, Char* argv[] ); ///< parse configuration file to fill member variables 240 282 241 283 };// END CLASS DEFINITION TAppEncCfg 242 284 -
trunk/source/App/TAppEncoder/TAppEncTop.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 18 51 TAppEncTop::TAppEncTop() 19 52 { 20 //GTVSO53 #if HHI_VSO 21 54 m_iLastFramePutInERViewBuffer = -1; 22 //GT VSO end 55 #endif 23 56 } 24 57 … … 55 88 m_acTEncTopList[iViewIdx]->setRateGOPSize ( m_iRateGOPSize ); 56 89 57 // // SB58 90 m_acTEncTopList[iViewIdx]->setSeqStructure ( m_cInputFormatString ); 59 91 … … 79 111 m_acTEncTopList[iViewIdx]->setMaxDeltaQP ( m_iMaxDeltaQP ); 80 112 113 #if HHI_VSO 81 114 //====== VSO ========= 82 //GT VSO83 115 m_acTEncTopList[iViewIdx]->setForceLambdaScaleVSO ( false ); 84 116 m_acTEncTopList[iViewIdx]->setLambdaScaleVSO ( 1 ); 85 117 m_acTEncTopList[iViewIdx]->setVSOMode ( 0 ); 86 //GT VSO end 118 #endif 87 119 88 120 //====== Tool list ======== … … 109 141 m_acTEncTopList[iViewIdx]->setUseFastEnc ( m_bUseFastEnc ); 110 142 111 //GTVSO143 #if HHI_VSO 112 144 m_acTEncTopList[iViewIdx]->setUseVSO ( false ); //GT: might be enabled later for VSO Mode 4 113 //GT VSO end 145 #endif 114 146 115 147 m_acTEncTopList[iViewIdx]->setViewId ( (UInt)iViewIdx ); … … 120 152 m_acTEncTopList[iViewIdx]->setCodedScale ( m_cCameraData.getCodedScale () ); 121 153 m_acTEncTopList[iViewIdx]->setCodedOffset ( m_cCameraData.getCodedOffset () ); 154 #if DEPTH_MAP_GENERATION 122 155 m_acTEncTopList[iViewIdx]->setPredDepthMapGeneration ( m_uiPredDepthMapGeneration ); 156 m_acTEncTopList[iViewIdx]->setPdmPrecision ( (UInt)m_cCameraData.getPdmPrecision () ); 157 m_acTEncTopList[iViewIdx]->setPdmScaleNomDelta ( m_cCameraData.getPdmScaleNomDelta () ); 158 m_acTEncTopList[iViewIdx]->setPdmOffset ( m_cCameraData.getPdmOffset () ); 159 #endif 160 #if HHI_INTER_VIEW_MOTION_PRED 123 161 m_acTEncTopList[iViewIdx]->setMultiviewMvPredMode ( m_uiMultiviewMvPredMode ); 124 162 m_acTEncTopList[iViewIdx]->setMultiviewMvRegMode ( iViewIdx ? m_uiMultiviewMvRegMode : 0 ); 125 163 m_acTEncTopList[iViewIdx]->setMultiviewMvRegLambdaScale ( iViewIdx ? m_dMultiviewMvRegLambdaScale : 0.0 ); 126 m_acTEncTopList[iViewIdx]->setPdmPrecision ( (UInt)m_cCameraData.getPdmPrecision () ); 127 m_acTEncTopList[iViewIdx]->setPdmScaleNomDelta ( m_cCameraData.getPdmScaleNomDelta () ); 128 m_acTEncTopList[iViewIdx]->setPdmOffset ( m_cCameraData.getPdmOffset () ); 164 #endif 165 #if HHI_INTER_VIEW_RESIDUAL_PRED 129 166 m_acTEncTopList[iViewIdx]->setMultiviewResPredMode ( m_uiMultiviewResPredMode ); 130 131 #if SB_INTERVIEW_SKIP 167 #endif 168 169 170 #if HHI_INTERVIEW_SKIP 132 171 m_acTEncTopList[iViewIdx]->setInterViewSkip ( iViewIdx ? m_uiInterViewSkip : 0 ); 133 #if SB_INTERVIEW_SKIP_LAMBDA_SCALE134 m_acTEncTopList[iViewIdx]->setInterViewSkipLambdaScale ( iViewIdx ? m_dInterViewSkipLambdaScale : 1 );172 #if HHI_INTERVIEW_SKIP_LAMBDA_SCALE 173 m_acTEncTopList[iViewIdx]->setInterViewSkipLambdaScale ( iViewIdx ? (Int)m_dInterViewSkipLambdaScale : 1 ); 135 174 #endif 136 175 #endif … … 147 186 m_acTEncTopList[iViewIdx]->setUseRoundingControlBipred(m_useRoundingControlBipred); 148 187 #endif 149 #if HHI_DMM_ INTRA150 m_acTEncTopList[iViewIdx]->setUseD epthModelModes( false );188 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 189 m_acTEncTopList[iViewIdx]->setUseDMM( false ); 151 190 #endif 152 191 #if CONSTRAINED_INTRA_PRED … … 175 214 m_acTEncTopList[iViewIdx]->setUseSAO ( m_abUseSAO[0] ); 176 215 #endif 216 #if HHI_MPI 177 217 m_acTEncTopList[iViewIdx]->setUseMVI( false ); 218 #endif 178 219 179 220 m_acTEncTopList[iViewIdx]->setPictureDigestEnabled(m_pictureDigestEnabled); 180 m_acTEncTopList[iViewIdx]->setOmitUnusedBlocks ( m_bOmitUnusedBlocks && (iViewIdx != 0) );181 182 221 m_acTEncTopList[iViewIdx]->setQpChangeFrame( m_iQpChangeFrame ); 183 222 m_acTEncTopList[iViewIdx]->setQpChangeOffsetVideo( m_iQpChangeOffsetVideo ); … … 187 226 { 188 227 189 //GTVSO228 #if HHI_VSO 190 229 for (Int iViewIdx=0; iViewIdx<m_iNumberOfExternalRefs; iViewIdx++) 191 230 { 192 231 m_acTVideoIOYuvERFileList.push_back(new TVideoIOYuv); 193 232 } 194 //GT VSO end 233 #endif 195 234 196 235 for(Int iViewIdx=0; iViewIdx<m_iNumberOfViews; iViewIdx++) … … 219 258 m_acTEncDepthTopList[iViewIdx]->setRateGOPSize ( m_iRateGOPSize ); 220 259 221 // // SB222 260 m_acTEncDepthTopList[iViewIdx]->setSeqStructure ( m_cInputFormatString ); 223 261 … … 266 304 m_acTEncDepthTopList[iViewIdx]->setUseFastEnc ( m_bUseFastEnc ); 267 305 268 //GTVSO306 #if HHI_VSO 269 307 m_acTEncDepthTopList[iViewIdx]->setUseVSO ( m_bUseVSO ); //GT: might be enabled/disabled later for VSO Mode 4 270 308 m_acTEncDepthTopList[iViewIdx]->setForceLambdaScaleVSO ( m_bForceLambdaScaleVSO ); 271 309 m_acTEncDepthTopList[iViewIdx]->setLambdaScaleVSO ( m_dLambdaScaleVSO ); 272 #if RDO_DIST_INT310 #if HHI_VSO_DIST_INT 273 311 m_acTEncDepthTopList[iViewIdx]->setAllowNegDist ( m_bAllowNegDist ); 274 312 #endif 275 313 m_acTEncDepthTopList[iViewIdx]->setVSOMode ( m_uiVSOMode ); 276 //GT VSO end 314 #endif 277 315 278 316 m_acTEncDepthTopList[iViewIdx]->setViewId ( (UInt)iViewIdx ); … … 283 321 m_acTEncDepthTopList[iViewIdx]->setCodedScale ( 0 ); 284 322 m_acTEncDepthTopList[iViewIdx]->setCodedOffset ( 0 ); 323 #if DEPTH_MAP_GENERATION 285 324 m_acTEncDepthTopList[iViewIdx]->setPredDepthMapGeneration ( 0 ); 325 #endif 326 #if HHI_INTER_VIEW_MOTION_PRED 286 327 m_acTEncDepthTopList[iViewIdx]->setMultiviewMvPredMode ( 0 ); 287 328 m_acTEncDepthTopList[iViewIdx]->setMultiviewMvRegMode ( 0 ); 288 329 m_acTEncDepthTopList[iViewIdx]->setMultiviewMvRegLambdaScale ( 0.0 ); 330 #endif 331 #if HHI_INTER_VIEW_RESIDUAL_PRED 289 332 m_acTEncDepthTopList[iViewIdx]->setMultiviewResPredMode ( 0 ); 290 291 #if SB_INTERVIEW_SKIP 333 #endif 334 335 #if HHI_INTERVIEW_SKIP 292 336 m_acTEncDepthTopList[iViewIdx]->setInterViewSkip ( 0 ); 293 #if SB_INTERVIEW_SKIP_LAMBDA_SCALE337 #if HHI_INTERVIEW_SKIP_LAMBDA_SCALE 294 338 m_acTEncDepthTopList[iViewIdx]->setInterViewSkipLambdaScale ( 1 ); 295 339 #endif … … 307 351 m_acTEncDepthTopList[iViewIdx]->setUseRoundingControlBipred(m_useRoundingControlBipred); 308 352 #endif 309 #if HHI_DMM_ INTRA310 m_acTEncDepthTopList[iViewIdx]->setUseD epthModelModes( m_bUseDepthModelModes);353 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 354 m_acTEncDepthTopList[iViewIdx]->setUseDMM( m_bUseDMM ); 311 355 #endif 312 356 #if CONSTRAINED_INTRA_PRED … … 335 379 m_acTEncDepthTopList[iViewIdx]->setUseSAO ( m_abUseSAO[1] ); 336 380 #endif 381 #if HHI_MPI 337 382 m_acTEncDepthTopList[iViewIdx]->setUseMVI( m_bUseMVI ); 383 #endif 338 384 339 385 m_acTEncDepthTopList[iViewIdx]->setPictureDigestEnabled(m_pictureDigestEnabled); 340 m_acTEncDepthTopList[iViewIdx]->setOmitUnusedBlocks ( m_bOmitUnusedBlocks && (iViewIdx != 0) );341 386 342 387 m_acTEncDepthTopList[iViewIdx]->setQpChangeFrame( m_iQpChangeFrame ); … … 345 390 } 346 391 } 392 #if HHI_INTER_VIEW_MOTION_PRED 347 393 else if( m_uiMultiviewMvRegMode ) 348 394 { … … 352 398 } 353 399 } 354 355 //GT VSO 400 #endif 401 402 #if HHI_VSO 356 403 if ( m_bUseVSO ) 357 404 { 358 405 if ( m_uiVSOMode == 4 ) 359 { 360 #if GERHARD_RM_DEBUG_MM 361 m_cMMCheckModel .create( m_cRenModStrParser.getNumOfBaseViews(), m_cRenModStrParser.getNumOfModels(), m_iSourceWidth, m_iSourceHeight, LOG2_DISP_PREC_LUT, 0 ); 362 #endif 406 { 363 407 m_cRendererModel.create( m_cRenModStrParser.getNumOfBaseViews(), m_cRenModStrParser.getNumOfModels(), m_iSourceWidth, m_iSourceHeight, LOG2_DISP_PREC_LUT, 0 ); 364 408 … … 367 411 for (Int iContent = 0; iContent < 2; iContent++ ) 368 412 { 369 Int iNumOfModels = m_cRenModStrParser.getNumOfModelsForView(iViewNum, iContent); 370 Bool bUseVSO = (iNumOfModels != 0); 371 372 TEncTop* pcEncTop = ( iContent == 0 ) ? m_acTEncTopList[iViewNum] : m_acTEncDepthTopList[iViewNum]; 373 pcEncTop->setUseVSO( bUseVSO ); 374 pcEncTop->getRdCost()->setRenModel( bUseVSO ? &m_cRendererModel : NULL ); 375 413 Int iNumOfModels = m_cRenModStrParser.getNumOfModelsForView(iViewNum, iContent); 414 Bool bUseVSO = (iNumOfModels != 0); 415 416 TEncTop* pcEncTop = ( iContent == 0 ) ? m_acTEncTopList[iViewNum] : m_acTEncDepthTopList[iViewNum]; 417 pcEncTop->setUseVSO( bUseVSO ); 418 pcEncTop->getRdCost()->setRenModel( bUseVSO ? &m_cRendererModel : NULL ); 419 376 420 for (Int iCurModel = 0; iCurModel < iNumOfModels; iCurModel++ ) 377 421 { 378 Int iModelNum; Int iLeftViewNum; Int iRightViewNum; Int iDump; Int iOrgRefNum; Int iBlendMode; 379 380 m_cRenModStrParser.getSingleModelData ( iViewNum, iContent, iCurModel, iModelNum, iBlendMode, iLeftViewNum, iRightViewNum, iOrgRefNum, iDump ) ; 381 m_cRendererModel .createSingleModel ( iViewNum, iContent, iModelNum, iLeftViewNum, iRightViewNum, (iOrgRefNum != -1), iBlendMode ); 382 #if GERHARD_RM_DEBUG_MM 383 m_cMMCheckModel .createSingleModel ( iViewNum, iContent, iModelNum, iLeftViewNum, iRightViewNum, (iOrgRefNum != -1), iBlendMode ); 384 #endif 422 Int iModelNum; Int iLeftViewNum; Int iRightViewNum; Int iDump; Int iOrgRefNum; Int iBlendMode; 423 424 m_cRenModStrParser.getSingleModelData ( iViewNum, iContent, iCurModel, iModelNum, iBlendMode, iLeftViewNum, iRightViewNum, iOrgRefNum, iDump ) ; 425 m_cRendererModel .createSingleModel ( iViewNum, iContent, iModelNum, iLeftViewNum, iRightViewNum, (iOrgRefNum != -1), iBlendMode ); 385 426 } 386 427 } … … 391 432 m_cRendererTop.init(m_iSourceWidth, m_iSourceHeight,true,0,0,true, 0,0,0,0,0,0,0,1,0,0 ); //GT: simplest configuration 392 433 } 393 394 } 395 //GT VSO end 396 m_cUsedPelsRenderer.init(m_iSourceWidth, m_iSourceHeight, true, 0, LOG2_DISP_PREC_LUT, true, 0, 0, 0, 0, 0, 6, 4, 1, 0, 6 ); 434 } 435 #endif 436 437 #if HHI_INTERVIEW_SKIP 438 m_cUsedPelsRenderer.init(m_iSourceWidth, m_iSourceHeight, true, 0, LOG2_DISP_PREC_LUT, true, 0, 0, 0, 0, 0, 6, 4, 1, 0, 6 ); 439 #endif 397 440 } 398 441 … … 421 464 m_acTEncDepthTopList[iViewIdx]->create(); 422 465 } 466 #if HHI_INTER_VIEW_MOTION_PRED 423 467 else if( m_uiMultiviewMvRegMode ) 424 468 { … … 426 470 m_acTVideoIOYuvDepthInputFileList[iViewIdx]->skipFrames(m_FrameSkip, m_iSourceWidth, m_iSourceHeight); 427 471 } 428 } 429 430 //GT VSO 472 #endif 473 } 474 475 #if HHI_VSO 431 476 for(Int iViewIdx=0; iViewIdx < m_iNumberOfExternalRefs; iViewIdx++) 432 477 { 433 478 m_acTVideoIOYuvERFileList[iViewIdx]->open( m_pchERRefFileList[iViewIdx], false, m_uiInputBitDepth, m_uiInternalBitDepth ); // read mode 434 479 } 435 //GT VSO end 480 #endif 436 481 } 437 482 … … 441 486 m_cTVideoIOBitsFile.closeBits(); 442 487 443 //GTVSO488 #if HHI_VSO 444 489 for ( Int iViewIdx = 0; iViewIdx < m_iNumberOfExternalRefs; iViewIdx++ ) 445 490 { … … 448 493 m_acTVideoIOYuvERFileList[iViewIdx] = 0; 449 494 }; 450 //GT VSO end 495 #endif 451 496 452 497 for(Int iViewIdx=0; iViewIdx<m_iNumberOfViews; iViewIdx++) … … 563 608 pcDepthPicYuvOrg->create( m_iSourceWidth, m_iSourceHeight, m_uiMaxCUWidth, m_uiMaxCUHeight, m_uiMaxCUDepth ); 564 609 } 610 #if HHI_INTER_VIEW_MOTION_PRED 565 611 if( m_uiMultiviewMvRegMode ) 566 612 { 567 613 pcPdmDepthOrg->create( m_iSourceWidth, m_iSourceHeight, m_uiMaxCUWidth, m_uiMaxCUHeight, m_uiMaxCUDepth ); 568 614 } 615 #endif 569 616 570 617 TComBitstream* pcBitstream = new TComBitstream; … … 589 636 bAllEos = bAllEos|bEos[iViewIdx] ; 590 637 638 #if HHI_INTER_VIEW_MOTION_PRED 591 639 if( m_uiMultiviewMvRegMode && iViewIdx ) 592 640 { 593 641 m_acTVideoIOYuvDepthInputFileList[iViewIdx]->read( pcPdmDepthOrg, m_aiPad, m_bUsingDepthMaps ); 594 642 } 643 #endif 595 644 596 645 // increase number of received frames … … 598 647 } 599 648 649 #if HHI_INTER_VIEW_MOTION_PRED 600 650 m_acTEncTopList[iViewIdx]->receivePic( bEos[iViewIdx], pcPicYuvOrg, m_cListPicYuvRecList[iViewIdx]->back(), ( m_uiMultiviewMvRegMode && iViewIdx ? pcPdmDepthOrg : 0 ) ); 651 #else 652 m_acTEncTopList[iViewIdx]->receivePic( bEos[iViewIdx], pcPicYuvOrg, m_cListPicYuvRecList[iViewIdx]->back(), 0 ); 653 #endif 601 654 602 655 if( m_bUsingDepthMaps ) … … 628 681 } 629 682 630 //GT VSO 683 #if HHI_VSO 631 684 if ( m_bUseVSO && ( m_uiVSOMode != 4) ) 632 685 { … … 634 687 xStoreVSORefPicsInBuffer(); //GT; 635 688 } 636 //GT VSO end 689 #endif 637 690 638 691 //GT: Encode … … 688 741 689 742 #if AMVP_BUFFERCOMPRESS 690 // compress motion for entire access 743 // compress motion for entire access 691 744 if( bCurrPocCoded ) 692 745 { … … 729 782 pcDepthPicYuvOrg = NULL ; 730 783 731 // SB valgrid732 784 pcBitstream->destroy(); 733 785 delete pcBitstream; … … 751 803 if ( pcPdmDepthOrg ) 752 804 { 753 pcPdmDepthOrg->destroy(); 754 delete pcPdmDepthOrg; 755 pcPdmDepthOrg = NULL; 805 pcPdmDepthOrg->destroy(); 806 delete pcPdmDepthOrg; 807 pcPdmDepthOrg = NULL; 756 808 } 757 809 … … 847 899 // Delete ERFiles 848 900 849 //GTVSO901 #if HHI_VSO 850 902 std::map< Int,vector<TComPicYuv*> >::iterator iterMapPicExtRefView = m_cMapPicExtRefView.begin(); 851 903 while ( iterMapPicExtRefView != m_cMapPicExtRefView.end() ) … … 861 913 iterMapPicExtRefView++; 862 914 } 863 //GT VSO end 915 #endif 864 916 } 865 917 … … 920 972 TComPicYuv* TAppEncTop::xGetPicYuvFromView( Int iViewIdx, Int iPoc, Bool bDepth, Bool bRecon ) 921 973 { 922 TComPic* pcPic = xGetPicFromView( iViewIdx, iPoc, bDepth); 923 TComPicYuv* pcPicYuv = NULL; 974 TComPic* pcPic = xGetPicFromView( iViewIdx, iPoc, bDepth); 975 TComPicYuv* pcPicYuv = NULL; 924 976 925 977 if (pcPic != NULL) … … 929 981 if ( pcPic->getReconMark() ) 930 982 { 931 pcPicYuv = pcPic->getPicYuvRec(); 983 pcPicYuv = pcPic->getPicYuvRec(); 932 984 } 933 985 } 934 986 else 935 987 { 936 pcPicYuv = pcPic->getPicYuvOrg(); 937 } 988 pcPicYuv = pcPic->getPicYuvOrg(); 989 } 938 990 }; 939 991 940 return pcPicYuv; 941 }; 942 992 return pcPicYuv; 993 }; 994 995 #if HHI_VSO 943 996 Void TAppEncTop::xSetBasePicYuv( Int iViewIdx, Int iPoc, TComMVDRefData* pcRefInfo, InterViewReference eView, bool bDepth ) 944 997 { … … 975 1028 } 976 1029 977 //GT campara 1030 978 1031 xSetBaseLUT (iViewIdx, iViewIdx-1 , pcMVDRefData, PREVVIEW ); 979 1032 xSetBaseLUT (iViewIdx, iViewIdx+1 , pcMVDRefData, NEXTVIEW ); 980 //GT campara end 981 982 //GT VSO 1033 1034 983 1035 if ( m_bUseVSO && m_uiVSOMode != 4) 984 1036 { … … 987 1039 pcMVDRefData->setRefViewInd (m_aaiBaseViewRefInd[iViewIdx], m_aaiERViewRefInd[iViewIdx], m_aaiERViewRefLutInd[iViewIdx]); 988 1040 } 989 //GT VSO end990 991 1041 }; 992 1042 993 //GT campara 1043 994 1044 Void TAppEncTop::xSetBaseLUT( Int iViewIdxSource, Int iViewIdxTarget, TComMVDRefData* pcRefInfo, InterViewReference eView ) 995 1045 { … … 999 1049 pcRefInfo->setShiftLUTsBaseView(eView, m_cCameraData.getBaseViewShiftLUTD()[iViewIdxSource][iViewIdxTarget],m_cCameraData.getBaseViewShiftLUTI()[iViewIdxSource][iViewIdxTarget] ); 1000 1050 }; 1001 //GT campara end 1002 1003 1004 //GT VSO 1051 1005 1052 Void TAppEncTop::xSetERPicYuvs( Int iViewIdx, Int iPoc, TComMVDRefData* pcReferenceInfo ) 1006 1053 { … … 1014 1061 pcReferenceInfo->setPicYuvERViews( cMapIt->second ); 1015 1062 } 1016 1017 1018 1063 1019 1064 Void TAppEncTop::xStoreVSORefPicsInBuffer() … … 1130 1175 } 1131 1176 } 1132 // GT VSO end 1133 1177 #endif 1178 1179 #if HHI_INTERVIEW_SKIP 1134 1180 Void TAppEncTop::getUsedPelsMap( Int iViewIdx, Int iPoc, TComPicYuv* pcPicYuvUsedSplsMap ) 1135 1181 { 1136 AOT( iViewIdx <= 0); 1137 AOT( iViewIdx >= m_iNumberOfViews ); 1138 AOF( m_ bOmitUnusedBlocks);1139 AOF( m_cCameraData.getCurFrameId() == iPoc ); 1140 1141 Int iViewSIdx = m_cCameraData.getBaseId2SortedId()[iViewIdx]; 1142 Int iFirstViewSIdx = m_cCameraData.getBaseId2SortedId()[0]; 1182 AOT( iViewIdx <= 0); 1183 AOT( iViewIdx >= m_iNumberOfViews ); 1184 AOF( m_uiInterViewSkip != 0 ); 1185 AOF( m_cCameraData.getCurFrameId() == iPoc ); 1186 1187 Int iViewSIdx = m_cCameraData.getBaseId2SortedId()[iViewIdx]; 1188 Int iFirstViewSIdx = m_cCameraData.getBaseId2SortedId()[0]; 1143 1189 1144 1190 AOT( iViewSIdx == iFirstViewSIdx ); 1145 1191 1146 Bool bFirstIsLeft = (iFirstViewSIdx < iViewSIdx); 1192 Bool bFirstIsLeft = (iFirstViewSIdx < iViewSIdx); 1147 1193 1148 1194 m_cUsedPelsRenderer.setShiftLUTs( … … 1154 1200 m_cCameraData.getBaseViewShiftLUTI()[0][iViewIdx], 1155 1201 -1 1156 ); 1157 1202 ); 1203 1158 1204 1159 1205 TComPicYuv* pcPicYuvDepth = xGetPicYuvFromView(0, iPoc, true, true ); 1160 AOF( pcPicYuvDepth); 1161 1162 m_cUsedPelsRenderer.getUsedSamplesMap( pcPicYuvDepth, pcPicYuvUsedSplsMap, bFirstIsLeft ); 1163 1164 } 1165 1206 AOF( pcPicYuvDepth); 1207 1208 m_cUsedPelsRenderer.getUsedSamplesMap( pcPicYuvDepth, pcPicYuvUsedSplsMap, bFirstIsLeft ); 1209 1210 } 1211 #endif 1212 1213 #if HHI_VSO 1166 1214 Void TAppEncTop::setupRenModel( Int iPoc, Int iEncViewIdx, Int iEncContent ) 1167 1215 { 1168 Int iEncViewSIdx = m_cCameraData.getBaseId2SortedId()[ iEncViewIdx ]; 1216 Int iEncViewSIdx = m_cCameraData.getBaseId2SortedId()[ iEncViewIdx ]; 1169 1217 1170 1218 // setup base views 1171 Int iNumOfBV = m_cRenModStrParser.getNumOfBaseViewsForView( iEncViewSIdx, iEncContent ); 1219 Int iNumOfBV = m_cRenModStrParser.getNumOfBaseViewsForView( iEncViewSIdx, iEncContent ); 1172 1220 1173 1221 for (Int iCurView = 0; iCurView < iNumOfBV; iCurView++ ) 1174 { 1175 Int iBaseViewSIdx; 1176 Int iVideoDistMode; 1177 Int iDepthDistMode; 1178 1179 m_cRenModStrParser.getBaseViewData( iEncViewSIdx, iEncContent, iCurView, iBaseViewSIdx, iVideoDistMode, iDepthDistMode ); 1180 1181 AOT( iVideoDistMode < 0 || iVideoDistMode > 2 ); 1182 1183 Int iBaseViewIdx = m_cCameraData.getBaseSortedId2Id()[ iBaseViewSIdx ]; 1184 1185 TComPicYuv* pcPicYuvVideoRec = xGetPicYuvFromView( iBaseViewIdx, iPoc, false, true ); 1186 TComPicYuv* pcPicYuvDepthRec = xGetPicYuvFromView( iBaseViewIdx, iPoc, true , true ); 1187 TComPicYuv* pcPicYuvVideoOrg = xGetPicYuvFromView( iBaseViewIdx, iPoc, false, false ); 1188 TComPicYuv* pcPicYuvDepthOrg = xGetPicYuvFromView( iBaseViewIdx, iPoc, true , false ); 1189 1190 TComPicYuv* pcPicYuvVideoRef = ( iVideoDistMode == 2 ) ? pcPicYuvVideoOrg : NULL; 1191 TComPicYuv* pcPicYuvDepthRef = ( iDepthDistMode == 2 ) ? pcPicYuvDepthOrg : NULL; 1192 1193 TComPicYuv* pcPicYuvVideoTest = ( iVideoDistMode == 0 ) ? pcPicYuvVideoOrg : pcPicYuvVideoRec; 1194 TComPicYuv* pcPicYuvDepthTest = ( iDepthDistMode == 0 ) ? pcPicYuvDepthOrg : pcPicYuvDepthRec; 1195 1196 AOT( (iVideoDistMode == 2) != (pcPicYuvVideoRef != NULL) ); 1197 AOT( (iDepthDistMode == 2) != (pcPicYuvDepthRef != NULL) ); 1198 AOT( pcPicYuvDepthTest == NULL ); 1199 AOT( pcPicYuvVideoTest == NULL ); 1200 1201 m_cRendererModel.setBaseView( iBaseViewSIdx, pcPicYuvVideoTest, pcPicYuvDepthTest, pcPicYuvVideoRef, pcPicYuvDepthRef ); 1202 #if GERHARD_RM_DEBUG_MM 1203 m_cMMCheckModel .setBaseView( iBaseViewSIdx, pcPicYuvVideoTest, pcPicYuvDepthTest, pcPicYuvVideoRef, pcPicYuvDepthRef ); 1204 #endif 1205 } 1206 1207 m_cRendererModel.setErrorMode( iEncViewSIdx, iEncContent, 0 ); 1208 #if GERHARD_RM_DEBUG_MM 1209 m_cMMCheckModel .setErrorMode( iEncViewSIdx, iEncContent, 0 ); 1210 #endif 1211 1222 { 1223 Int iBaseViewSIdx; 1224 Int iVideoDistMode; 1225 Int iDepthDistMode; 1226 1227 m_cRenModStrParser.getBaseViewData( iEncViewSIdx, iEncContent, iCurView, iBaseViewSIdx, iVideoDistMode, iDepthDistMode ); 1228 1229 AOT( iVideoDistMode < 0 || iVideoDistMode > 2 ); 1230 1231 Int iBaseViewIdx = m_cCameraData.getBaseSortedId2Id()[ iBaseViewSIdx ]; 1232 1233 TComPicYuv* pcPicYuvVideoRec = xGetPicYuvFromView( iBaseViewIdx, iPoc, false, true ); 1234 TComPicYuv* pcPicYuvDepthRec = xGetPicYuvFromView( iBaseViewIdx, iPoc, true , true ); 1235 TComPicYuv* pcPicYuvVideoOrg = xGetPicYuvFromView( iBaseViewIdx, iPoc, false, false ); 1236 TComPicYuv* pcPicYuvDepthOrg = xGetPicYuvFromView( iBaseViewIdx, iPoc, true , false ); 1237 1238 TComPicYuv* pcPicYuvVideoRef = ( iVideoDistMode == 2 ) ? pcPicYuvVideoOrg : NULL; 1239 TComPicYuv* pcPicYuvDepthRef = ( iDepthDistMode == 2 ) ? pcPicYuvDepthOrg : NULL; 1240 1241 TComPicYuv* pcPicYuvVideoTest = ( iVideoDistMode == 0 ) ? pcPicYuvVideoOrg : pcPicYuvVideoRec; 1242 TComPicYuv* pcPicYuvDepthTest = ( iDepthDistMode == 0 ) ? pcPicYuvDepthOrg : pcPicYuvDepthRec; 1243 1244 AOT( (iVideoDistMode == 2) != (pcPicYuvVideoRef != NULL) ); 1245 AOT( (iDepthDistMode == 2) != (pcPicYuvDepthRef != NULL) ); 1246 AOT( pcPicYuvDepthTest == NULL ); 1247 AOT( pcPicYuvVideoTest == NULL ); 1248 1249 m_cRendererModel.setBaseView( iBaseViewSIdx, pcPicYuvVideoTest, pcPicYuvDepthTest, pcPicYuvVideoRef, pcPicYuvDepthRef ); 1250 } 1251 1252 m_cRendererModel.setErrorMode( iEncViewSIdx, iEncContent, 0 ); 1212 1253 // setup virtual views 1213 Int iNumOfSV = m_cRenModStrParser.getNumOfModelsForView( iEncViewSIdx, iEncContent ); 1254 Int iNumOfSV = m_cRenModStrParser.getNumOfModelsForView( iEncViewSIdx, iEncContent ); 1214 1255 for (Int iCurView = 0; iCurView < iNumOfSV; iCurView++ ) 1215 { 1216 Int iOrgRefBaseViewSIdx; 1217 Int iLeftBaseViewSIdx; 1218 Int iRightBaseViewSIdx; 1219 Int iSynthViewRelNum; 1220 Int iModelNum; 1221 Int iBlendMode; 1222 m_cRenModStrParser.getSingleModelData(iEncViewSIdx, iEncContent, iCurView, iModelNum, iBlendMode,iLeftBaseViewSIdx, iRightBaseViewSIdx, iOrgRefBaseViewSIdx, iSynthViewRelNum ); 1223 1224 Int iLeftBaseViewIdx = -1; 1225 Int iRightBaseViewIdx = -1; 1226 1227 TComPicYuv* pcPicYuvOrgRef = NULL; 1228 Int** ppiShiftLUTLeft = NULL; 1229 Int** ppiShiftLUTRight = NULL; 1230 Int** ppiBaseShiftLUTLeft = NULL; 1231 Int** ppiBaseShiftLUTRight = NULL; 1232 1233 1234 Int iDistToLeft = -1; 1235 1236 Int iSynthViewIdx = m_cCameraData.synthRelNum2Idx( iSynthViewRelNum ); 1256 { 1257 Int iOrgRefBaseViewSIdx; 1258 Int iLeftBaseViewSIdx; 1259 Int iRightBaseViewSIdx; 1260 Int iSynthViewRelNum; 1261 Int iModelNum; 1262 Int iBlendMode; 1263 m_cRenModStrParser.getSingleModelData(iEncViewSIdx, iEncContent, iCurView, iModelNum, iBlendMode,iLeftBaseViewSIdx, iRightBaseViewSIdx, iOrgRefBaseViewSIdx, iSynthViewRelNum ); 1264 1265 Int iLeftBaseViewIdx = -1; 1266 Int iRightBaseViewIdx = -1; 1267 1268 TComPicYuv* pcPicYuvOrgRef = NULL; 1269 Int** ppiShiftLUTLeft = NULL; 1270 Int** ppiShiftLUTRight = NULL; 1271 Int** ppiBaseShiftLUTLeft = NULL; 1272 Int** ppiBaseShiftLUTRight = NULL; 1273 1274 1275 Int iDistToLeft = -1; 1276 1277 Int iSynthViewIdx = m_cCameraData.synthRelNum2Idx( iSynthViewRelNum ); 1237 1278 1238 1279 if ( iLeftBaseViewSIdx != -1 ) 1239 1280 { 1240 iLeftBaseViewIdx = m_cCameraData.getBaseSortedId2Id() [ iLeftBaseViewSIdx ]; 1281 iLeftBaseViewIdx = m_cCameraData.getBaseSortedId2Id() [ iLeftBaseViewSIdx ]; 1241 1282 ppiShiftLUTLeft = m_cCameraData.getSynthViewShiftLUTI()[ iLeftBaseViewIdx ][ iSynthViewIdx ]; 1242 1283 } … … 1244 1285 if ( iRightBaseViewSIdx != -1 ) 1245 1286 { 1246 iRightBaseViewIdx = m_cCameraData.getBaseSortedId2Id() [iRightBaseViewSIdx ]; 1287 iRightBaseViewIdx = m_cCameraData.getBaseSortedId2Id() [iRightBaseViewSIdx ]; 1247 1288 ppiShiftLUTRight = m_cCameraData.getSynthViewShiftLUTI()[ iRightBaseViewIdx ][ iSynthViewIdx ]; 1248 1289 } 1249 1290 1250 1291 if ( iRightBaseViewSIdx != -1 && iLeftBaseViewSIdx != -1 ) 1251 { 1252 iDistToLeft = m_cCameraData.getRelDistLeft( iSynthViewIdx , iLeftBaseViewIdx, iRightBaseViewIdx); 1292 { 1293 iDistToLeft = m_cCameraData.getRelDistLeft( iSynthViewIdx , iLeftBaseViewIdx, iRightBaseViewIdx); 1253 1294 ppiBaseShiftLUTLeft = m_cCameraData.getBaseViewShiftLUTI() [ iLeftBaseViewIdx ][ iRightBaseViewIdx ]; 1254 1295 ppiBaseShiftLUTRight = m_cCameraData.getBaseViewShiftLUTI() [ iRightBaseViewIdx ][ iLeftBaseViewIdx ]; … … 1258 1299 if ( iOrgRefBaseViewSIdx != -1 ) 1259 1300 { 1260 pcPicYuvOrgRef = xGetPicYuvFromView( m_cCameraData.getBaseSortedId2Id()[ iOrgRefBaseViewSIdx ] , iPoc, false, false ); 1261 AOF ( pcPicYuvOrgRef ); 1262 } 1263 1264 m_cRendererModel.setSingleModel( iModelNum, ppiShiftLUTLeft, ppiBaseShiftLUTLeft, ppiShiftLUTRight, ppiBaseShiftLUTRight, iDistToLeft, pcPicYuvOrgRef ); 1265 #if GERHARD_RM_DEBUG_MM 1266 m_cMMCheckModel .setSingleModel( iModelNum, ppiShiftLUTLeft, ppiBaseShiftLUTLeft, ppiShiftLUTRight, ppiBaseShiftLUTRight, iDistToLeft, pcPicYuvOrgRef ); 1267 #endif 1268 } 1269 } 1270 1271 // GT VSO end 1301 pcPicYuvOrgRef = xGetPicYuvFromView( m_cCameraData.getBaseSortedId2Id()[ iOrgRefBaseViewSIdx ] , iPoc, false, false ); 1302 AOF ( pcPicYuvOrgRef ); 1303 } 1304 1305 m_cRendererModel.setSingleModel( iModelNum, ppiShiftLUTLeft, ppiBaseShiftLUTLeft, ppiShiftLUTRight, ppiBaseShiftLUTRight, iDistToLeft, pcPicYuvOrgRef ); 1306 } 1307 } 1308 #endif 1309 -
trunk/source/App/TAppEncoder/TAppEncTop.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 49 82 std::vector<Int> m_iDepthFrameRcvdVector; ///< number of received frames 50 83 84 #if DEPTH_MAP_GENERATION 51 85 TComSPSAccess m_cSPSAccess; 52 86 TComAUPicAccess m_cAUPicAccess; 87 #endif 53 88 89 #if HHI_VSO 54 90 TRenTop m_cRendererTop; 55 #if GERHARD_RM_DEBUG_MM 56 TRenModel m_cMMCheckModel; 91 TRenModel m_cRendererModel; 57 92 #endif 58 TRenModel m_cRendererModel;59 93 60 94 protected: … … 84 118 85 119 // Ref Data 120 #if HHI_VSO 86 121 Void xSetBaseLUT ( Int iViewIdxSource, Int iViewIdxTarget, TComMVDRefData* pcRefInfo, InterViewReference eView ); 87 122 Void xSetBasePicYuv( Int iViewIdx, Int iPoc, TComMVDRefData* pcRefInfo, InterViewReference eView, bool bDepth ); ///< store pics from buffers in pcRefInfo 88 123 #endif 89 124 90 125 public: … … 93 128 94 129 Void encode (); ///< main encoding function 130 #if HHI_VSO 95 131 Void setupRenModel ( Int iPoc, Int iEncViewIdx, Int iEncContent ); 96 132 Void setMVDPic ( Int iViewIdx, Int iPoc, TComMVDRefData* pcReferenceInfo ); // set MultiView References 133 #endif 97 134 Void getUsedPelsMap ( Int iViewIdx, Int iPoc, TComPicYuv* pcPicYuvUsedPelsMap ); 98 135 std::vector<TComPic*> getSpatialRefPics( Int iViewIdx, Int iPoc, Bool bIsDepthCoder ); // only for mvc functionality yet 99 136 TComPic* getPicFromView ( Int iViewIdx, Int iPoc, Bool bDepth ) { return xGetPicFromView( iViewIdx, iPoc, bDepth ); } 100 137 101 #if GERHARD_RM_DEBUG_MM102 TRenModel* get MMCheckModel() { return &m_cMMCheckModel ; };138 #if HHI_VSO 139 TRenModel* getRenModel () { return &m_cRendererModel ; }; 103 140 #endif 104 TRenModel* getRenModel () { return &m_cRendererModel ; };105 141 142 #if DEPTH_MAP_GENERATION 106 143 TComSPSAccess* getSPSAccess () { return &m_cSPSAccess; } 107 144 TComAUPicAccess* getAUPicAccess() { return &m_cAUPicAccess; } 145 #endif 108 146 109 //GTVSO147 #if HHI_VSO 110 148 private: 111 149 std::vector<TVideoIOYuv*> m_acTVideoIOYuvERFileList; … … 115 153 Void xSetERPicYuvs( Int iViewIdx, Int iPoc, TComMVDRefData* pcReferenceInfo ); ///< store pic from buffer in pcReferenceInfo 116 154 Void xStoreVSORefPicsInBuffer(); ///< read in External Ref pic from file and store in buffer 117 //GT VSO end 118 155 #endif 119 156 120 157 };// END CLASS DEFINITION TAppEncTop -
trunk/source/App/TAppEncoder/encmain.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppRenderer/RendererMain.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppRenderer/TAppRendererCfg.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 51 84 free (m_pchSynthOutputFileList[i]); 52 85 } 53 54 86 55 87 if ( m_pchVideoInputFileBaseName ) free( m_pchVideoInputFileBaseName ); … … 60 92 if ( m_pchSynthViewCameraNumbers ) free( m_pchSynthViewCameraNumbers ); 61 93 if ( m_pchViewConfig ) free( m_pchViewConfig ); 62 63 64 94 } 65 95 … … 117 147 ("PreProcMode" , m_iPreProcMode , 0, "Depth preprocessing: 0 = None, 1 = Binomial filtering" ) 118 148 ("PreFilterSize" , m_iPreFilterSize , 0, "For PreProcMode 1: Half Size of filter kernel" ) 119 ("SimEnhance" , m_bSimEnhance , false, "Similarity enhancement of video" )149 ("SimEnhance" , m_bSimEnhance , true, "Similarity enhancement of video" ) 120 150 ("BlendMode" , m_iBlendMode , 0, "Blending of left and right image: 0: average, 1: only holes from right, 2: only holes from left, 3: first view in BaseViewOrder as main view" ) 121 ("BlendZThresPerc" , m_iBlendZThresPerc , 3, "Z-difference threshold for blending in percent of total Z-range" )151 ("BlendZThresPerc" , m_iBlendZThresPerc , 30, "Z-difference threshold for blending in percent of total Z-range" ) 122 152 ("BlendUseDistWeight", m_bBlendUseDistWeight , true, "0: blend using average; 1: blend factor depends on view distance" ) 123 ("BlendHoleMargin" , m_iBlendHoleMargin , 0, "Margin around holes to fill with other view" )124 ("InterpolationMode" , m_iInterpolationMode , 0, "0: NN, 1:linear (int), 2:linear (double) , 3:cubic Hermite spline (double), 4: 8-tap (int)" )153 ("BlendHoleMargin" , m_iBlendHoleMargin , 6, "Margin around holes to fill with other view" ) 154 ("InterpolationMode" , m_iInterpolationMode , 4, "0: NN, 1:linear (int), 2:linear (double) , 3:cubic Hermite spline (double), 4: 8-tap (int)" ) 125 155 ("HoleFillingMode" , m_iHoleFillingMode , 1, "0: None, 1: line wise background extension" ) 126 156 ("PostProcMode" , m_iPostProcMode , 0, "0: None, 1: horizontal 3-tap median" ) 127 157 ("RenderMode" , m_iRenderMode , 0, "0: Use renderer, 1: use model renderer, 10: create used pels map") 128 ("ShiftPrecision" , m_iShiftPrecision , 0, "Shift Precision for Interpolation Mode 4" )158 ("ShiftPrecision" , m_iShiftPrecision , 2, "Shift Precision for Interpolation Mode 4" ) 129 159 ("TemporalDepthFilter", m_bTempDepthFilter , false, "Temporal depth filtering" ) 130 160 ("RenderDirection" , m_iRenderDirection , 0, "0: Interpolate, 1: Extrapolate from left, 2: Extrapolate from right") -
trunk/source/App/TAppRenderer/TAppRendererCfg.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppRenderer/TAppRendererTop.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/App/TAppRenderer/TAppRendererTop.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/CommonDef.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 15 48 #include "TComRom.h" 16 49 17 // SB18 50 #include <string> 19 51 #include <assert.h> … … 26 58 27 59 #define HM_VERSION "3.0rc2" ///< Current software version 28 #define NV_VERSION "0.3 1r4" ///< Current software version60 #define NV_VERSION "0.37" ///< Current software version 29 61 30 62 // ==================================================================================================================== … … 70 102 71 103 72 #define SEBASTIAN 173 #if SEBASTIAN74 #define SB_INTERVIEW_SKIP 175 #define SB_INTERVIEW_SKIP_LAMBDA_SCALE 176 #define SB_MEM_FIX 177 #define SB_NO_LowDelayCoding 0 // noch offen in motionestimation78 #endif79 80 #define GERHARD 181 #if GERHARD82 #define GERHARD_VQM_XCHECK 083 #define GERHARD_RM_DEBUG_MM 084 #define GERHARD_RM_HOLE_EXT 085 #define GERHARD_RM_COLOR_PLANES 186 #define GERHARD_RM_SPLAT 187 #endif88 89 90 104 // ==================================================================================================================== 91 105 // Common constants … … 116 130 #define STD_CAM_PARAMETERS_PRECISION 5 ///< quarter luma sample accuarcy for derived disparities (as default) 117 131 118 // SB119 132 #define MAX_INPUT_VIEW_NUM 10 ///< max. number of input view for multiview coding 120 133 121 // GT 134 #if HHI_VSO 122 135 #define MAX_ERREF_VIEW_NUM 15 ///< max. number of virtual external reference views 136 #endif 123 137 #define LOG2_DISP_PREC_LUT 2 ///< log2 of disparity precision used in integer disparity LUTs 124 138 139 140 #if ( HHI_INTER_VIEW_MOTION_PRED || HHI_INTER_VIEW_RESIDUAL_PRED ) 141 #define DEPTH_MAP_GENERATION 1 142 #else 143 #define DEPTH_MAP_GENERATION 0 144 #endif 125 145 126 146 //>>>>> generation and usage of virtual prediction depth maps >>>>> … … 151 171 #define OUTPUT_RESIDUAL_PICTURES 0 // output residual pictures (for debugging) 152 172 153 #define MVI_MERGE_POS 0 // position of mvi in merge list (0..5)173 #define HHI_MPI_MERGE_POS 0 // position of mvi in merge list (0..5) 154 174 155 175 … … 298 318 #endif 299 319 300 // SB from ViCo for formatted string parsing301 320 302 321 class VideoCodecException -
trunk/source/Lib/TLibCommon/ContextModel.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/ContextModel.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/ContextModel3DBuffer.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/ContextModel3DBuffer.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/ContextTables.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 14 47 15 48 #define NUM_SPLIT_FLAG_CTX 3 ///< number of context models for split flag 16 #if MW_MVI_SIGNALLING_MODE == 017 #define NUM_MVI_FLAG_CTX 3 ///< number of context models for motion inheritance flag18 #endif19 49 #define NUM_SKIP_FLAG_CTX 3 ///< number of context models for skip flag 20 50 … … 72 102 #define NUM_VIEW_IDX_CTX 6 73 103 74 #if HHI_DMM_ INTRA104 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 75 105 #define NUM_DMM_CTX 2 76 106 #define NUM_WEDGE_CTX 4 … … 120 150 } 121 151 }; 122 123 #if MW_MVI_SIGNALLING_MODE == 0124 // initial probability for skip flag125 static const Short126 INIT_MVI_FLAG[3][NUM_MVI_FLAG_CTX][2] =127 {128 {129 { 0, 64 }, { 0, 64 }, { 0, 64 }130 },131 {132 { 0, 64 }, { 0, 64 }, { 0, 64 }133 },134 {135 { 0, 64 }, { 0, 64 }, { 0, 64 }136 }137 };138 #endif139 152 140 153 // initial probability for skip flag … … 1324 1337 }; 1325 1338 1326 #if HHI_DMM_ INTRA1339 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 1327 1340 static const Short 1328 1341 INIT_INTRA_DMM[3][NUM_DMM_CTX][2] = -
trunk/source/Lib/TLibCommon/SEI.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComAdaptiveLoopFilter.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 278 311 m_bUseNonCrossALF = false; 279 312 #endif 280 #if SB_MEM_FIX281 313 m_bIsCreated = false; 282 #endif283 314 } 284 315 … … 471 502 Void TComAdaptiveLoopFilter::create( Int iPicWidth, Int iPicHeight, UInt uiMaxCUWidth, UInt uiMaxCUHeight, UInt uiMaxCUDepth ) 472 503 { 473 #if SB_MEM_FIX474 504 m_bIsCreated = true; 475 #endif476 505 if ( !m_pcTempPicYuv ) 477 506 { … … 514 543 Void TComAdaptiveLoopFilter::destroy() 515 544 { 516 #if SB_MEM_FIX517 545 m_bIsCreated = false ; 518 #endif519 546 if ( m_pcTempPicYuv ) 520 547 { -
trunk/source/Lib/TLibCommon/TComAdaptiveLoopFilter.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 336 369 Bool m_bIsFirstDecodedSlice; 337 370 338 #if SB_MEM_FIX339 371 Bool m_bIsCreated; 340 #endif341 372 Void xFilterOneSlice (CAlfSlice* pSlice, imgpel* pDec, imgpel* pRest, Int iStride, ALFParam* pcAlfParam); 342 373 Void calcVarforOneSlice (CAlfSlice* pSlice, imgpel **imgY_var, imgpel *imgY_pad, Int pad_size, Int fl, Int img_stride); … … 408 439 Void destroy (); 409 440 410 #if SB_MEM_FIX411 441 Bool isCreated() { return m_bIsCreated;} 412 #endif413 442 // alloc & free & set functions 414 443 Void allocALFParam ( ALFParam* pAlfParam ); -
trunk/source/Lib/TLibCommon/TComBitCounter.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComBitStream.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComBitStream.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComCABACTables.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComCABACTables.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComDataCU.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 20 53 m_pcSlice = NULL; 21 54 m_puhDepth = NULL; 55 #if HHI_MPI 22 56 m_piTextureModeDepth = NULL; 57 #endif 23 58 24 59 m_pePartSize = NULL; … … 31 66 m_pbMergeFlag = NULL; 32 67 m_puhMergeIndex = NULL; 68 #if HHI_INTER_VIEW_RESIDUAL_PRED 33 69 m_pbResPredAvailable = NULL; 34 70 m_pbResPredFlag = NULL; 71 #endif 35 72 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 36 73 { … … 71 108 #endif//SNY_DQP 72 109 73 #if HHI_DMM_ INTRA110 #if HHI_DMM_WEDGE_INTRA 74 111 m_puiWedgeFullTabIdx = NULL; 75 112 m_piWedgeFullDeltaDC1 = NULL; … … 80 117 m_piWedgePredDirDeltaDC2 = NULL; 81 118 m_piWedgePredDirDeltaEnd = NULL; 82 119 #endif 120 #if HHI_DMM_PRED_TEX 83 121 m_puiWedgePredTexTabIdx = NULL; 84 122 m_piWedgePredTexDeltaDC1 = NULL; … … 87 125 m_piContourPredTexDeltaDC1 = NULL; 88 126 m_piContourPredTexDeltaDC2 = NULL; 89 90 m_pbTextureModesAllowed = NULL;91 127 #endif 92 128 } … … 108 144 m_phQP = (UChar* )xMalloc(UChar, uiNumPartition); 109 145 m_puhDepth = (UChar* )xMalloc(UChar, uiNumPartition); 146 #if HHI_MPI 110 147 m_piTextureModeDepth = (Int* )xMalloc(Int, uiNumPartition); 148 #endif 111 149 m_puhWidth = (UChar* )xMalloc(UChar, uiNumPartition); 112 150 m_puhHeight = (UChar* )xMalloc(UChar, uiNumPartition); … … 118 156 m_pbMergeFlag = (Bool* )xMalloc(Bool, uiNumPartition); 119 157 m_puhMergeIndex = (UChar* )xMalloc(UChar, uiNumPartition); 158 #if HHI_INTER_VIEW_RESIDUAL_PRED 120 159 m_pbResPredAvailable = (Bool* )xMalloc(Bool, uiNumPartition); 121 160 m_pbResPredFlag = (Bool* )xMalloc(Bool, uiNumPartition); 161 #endif 122 162 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 123 163 { … … 147 187 m_acCUMvField[1].create( uiNumPartition ); 148 188 149 #if HHI_DMM_ INTRA150 m_puiWedgeFullTabIdx = (UInt* )xMalloc(UInt,uiNumPartition);189 #if HHI_DMM_WEDGE_INTRA 190 m_puiWedgeFullTabIdx = (UInt*)xMalloc(UInt, uiNumPartition); 151 191 m_piWedgeFullDeltaDC1 = (Int* )xMalloc(Int, uiNumPartition); 152 192 m_piWedgeFullDeltaDC2 = (Int* )xMalloc(Int, uiNumPartition); … … 156 196 m_piWedgePredDirDeltaDC2 = (Int* )xMalloc(Int, uiNumPartition); 157 197 m_piWedgePredDirDeltaEnd = (Int* )xMalloc(Int, uiNumPartition); 158 198 #endif 199 #if HHI_DMM_PRED_TEX 159 200 m_puiWedgePredTexTabIdx = (UInt*)xMalloc(UInt, uiNumPartition); 160 201 m_piWedgePredTexDeltaDC1 = (Int* )xMalloc(Int, uiNumPartition); … … 163 204 m_piContourPredTexDeltaDC1 = (Int* )xMalloc(Int, uiNumPartition); 164 205 m_piContourPredTexDeltaDC2 = (Int* )xMalloc(Int, uiNumPartition); 165 166 m_pbTextureModesAllowed = (Bool*)xMalloc(Bool, uiNumPartition);167 206 #endif 168 207 } … … 203 242 if ( m_phQP ) { xFree(m_phQP); m_phQP = NULL; } 204 243 if ( m_puhDepth ) { xFree(m_puhDepth); m_puhDepth = NULL; } 244 #if HHI_MPI 205 245 if ( m_piTextureModeDepth ) { xFree(m_piTextureModeDepth); m_piTextureModeDepth= NULL; } 246 #endif 206 247 if ( m_puhWidth ) { xFree(m_puhWidth); m_puhWidth = NULL; } 207 248 if ( m_puhHeight ) { xFree(m_puhHeight); m_puhHeight = NULL; } … … 215 256 if ( m_pbMergeFlag ) { xFree(m_pbMergeFlag); m_pbMergeFlag = NULL; } 216 257 if ( m_puhMergeIndex ) { xFree(m_puhMergeIndex); m_puhMergeIndex = NULL; } 258 #if HHI_INTER_VIEW_RESIDUAL_PRED 217 259 if ( m_pbResPredAvailable ) { xFree(m_pbResPredAvailable); m_pbResPredAvailable= NULL; } 218 260 if ( m_pbResPredFlag ) { xFree(m_pbResPredFlag); m_pbResPredFlag = NULL; } 261 #endif 219 262 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 220 263 { … … 235 278 m_acCUMvField[1].destroy(); 236 279 237 #if HHI_DMM_ INTRA280 #if HHI_DMM_WEDGE_INTRA 238 281 if ( m_puiWedgeFullTabIdx ) { xFree(m_puiWedgeFullTabIdx); m_puiWedgeFullTabIdx = NULL; } 239 282 if ( m_piWedgeFullDeltaDC1 ) { xFree(m_piWedgeFullDeltaDC1); m_piWedgeFullDeltaDC1 = NULL; } … … 244 287 if ( m_piWedgePredDirDeltaDC1 ) { xFree(m_piWedgePredDirDeltaDC1); m_piWedgePredDirDeltaDC1 = NULL; } 245 288 if ( m_piWedgePredDirDeltaDC2 ) { xFree(m_piWedgePredDirDeltaDC2); m_piWedgePredDirDeltaDC2 = NULL; } 246 289 #endif 290 #if HHI_DMM_PRED_TEX 247 291 if ( m_puiWedgePredTexTabIdx ) { xFree(m_puiWedgePredTexTabIdx); m_puiWedgePredTexTabIdx = NULL; } 248 292 if ( m_piWedgePredTexDeltaDC1 ) { xFree(m_piWedgePredTexDeltaDC1); m_piWedgePredTexDeltaDC1 = NULL; } … … 251 295 if ( m_piContourPredTexDeltaDC1 ) { xFree(m_piContourPredTexDeltaDC1); m_piContourPredTexDeltaDC1 = NULL; } 252 296 if ( m_piContourPredTexDeltaDC2 ) { xFree(m_piContourPredTexDeltaDC2); m_piContourPredTexDeltaDC2 = NULL; } 253 254 if ( m_pbTextureModesAllowed ) { xFree(m_pbTextureModesAllowed ); m_pbTextureModesAllowed = NULL; }255 297 #endif 256 298 } … … 308 350 memset( m_pbMergeFlag, 0, iSizeInBool ); 309 351 memset( m_puhMergeIndex, 0, iSizeInUchar ); 352 #if HHI_INTER_VIEW_RESIDUAL_PRED 310 353 memset( m_pbResPredAvailable, 0, iSizeInBool ); 311 354 memset( m_pbResPredFlag, 0, iSizeInBool ); 355 #endif 312 356 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 313 357 { … … 322 366 memset( m_puhCbf[2], 0, iSizeInUchar ); 323 367 memset( m_puhDepth, 0, iSizeInUchar ); 368 #if HHI_MPI 324 369 memset( m_piTextureModeDepth,-1, iSizeInInt ); 370 #endif 325 371 326 372 UChar uhWidth = g_uiMaxCUWidth; … … 390 436 } 391 437 392 #if HHI_DMM_ INTRA438 #if HHI_DMM_WEDGE_INTRA 393 439 memset( m_puiWedgeFullTabIdx, 0, iSizeInUInt ); 394 440 memset( m_piWedgeFullDeltaDC1, 0, iSizeInInt ); … … 399 445 memset( m_piWedgePredDirDeltaDC2, 0, iSizeInInt ); 400 446 memset( m_piWedgePredDirDeltaEnd, 0, iSizeInInt ); 401 447 #endif 448 #if HHI_DMM_PRED_TEX 402 449 memset( m_puiWedgePredTexTabIdx, 0, iSizeInUInt ); 403 450 memset( m_piWedgePredTexDeltaDC1, 0, iSizeInInt ); … … 406 453 memset( m_piContourPredTexDeltaDC1, 0, iSizeInInt ); 407 454 memset( m_piContourPredTexDeltaDC2, 0, iSizeInInt ); 408 409 memset( m_pbTextureModesAllowed, false, iSizeInBool );410 455 #endif 411 456 } … … 426 471 memset( m_pbMergeFlag, 0, iSizeInBool ); 427 472 memset( m_puhMergeIndex, 0, iSizeInUchar ); 473 #if HHI_INTER_VIEW_RESIDUAL_PRED 428 474 memset( m_pbResPredAvailable, 0, iSizeInBool ); 429 475 memset( m_pbResPredFlag, 0, iSizeInBool ); 476 #endif 430 477 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 431 478 { … … 461 508 m_acCUMvField[1].clearMvField(); 462 509 463 #if HHI_DMM_ INTRA510 #if HHI_DMM_WEDGE_INTRA 464 511 memset( m_puiWedgeFullTabIdx, 0, iSizeInUInt ); 465 512 memset( m_piWedgeFullDeltaDC1, 0, iSizeInInt ); … … 470 517 memset( m_piWedgePredDirDeltaDC2, 0, iSizeInInt ); 471 518 memset( m_piWedgePredDirDeltaEnd, 0, iSizeInInt ); 472 519 #endif 520 #if HHI_DMM_PRED_TEX 473 521 memset( m_puiWedgePredTexTabIdx, 0, iSizeInUInt ); 474 522 memset( m_piWedgePredTexDeltaDC1, 0, iSizeInInt ); … … 477 525 memset( m_piContourPredTexDeltaDC1, 0, iSizeInInt ); 478 526 memset( m_piContourPredTexDeltaDC2, 0, iSizeInInt ); 479 480 memset( m_pbTextureModesAllowed, false, iSizeInBool );481 527 #endif 482 528 529 #if HHI_MPI 483 530 memset( m_piTextureModeDepth, -1, iSizeInInt ); 531 #endif 484 532 } 485 533 … … 513 561 memset( m_pbMergeFlag, 0, iSizeInBool ); 514 562 memset( m_puhMergeIndex, 0, iSizeInUchar ); 563 #if HHI_INTER_VIEW_RESIDUAL_PRED 515 564 memset( m_pbResPredAvailable, 0, iSizeInBool ); 516 565 memset( m_pbResPredFlag, 0, iSizeInBool ); 566 #endif 517 567 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 518 568 { … … 527 577 memset( m_puhCbf[2], 0, iSizeInUchar ); 528 578 memset( m_puhDepth, uiDepth, iSizeInUchar ); 579 #if HHI_MPI 529 580 memset( m_piTextureModeDepth, -1, iSizeInInt ); 581 #endif 530 582 531 583 UChar uhWidth = g_uiMaxCUWidth >> uiDepth; … … 565 617 m_uiEntropySliceStartCU = pcCU->getEntropySliceStartCU(); 566 618 567 #if HHI_DMM_ INTRA619 #if HHI_DMM_WEDGE_INTRA 568 620 memset( m_puiWedgeFullTabIdx, 0, iSizeInUInt ); 569 621 memset( m_piWedgeFullDeltaDC1, 0, iSizeInInt ); … … 574 626 memset( m_piWedgePredDirDeltaDC2, 0, iSizeInInt ); 575 627 memset( m_piWedgePredDirDeltaEnd, 0, iSizeInInt ); 576 628 #endif 629 #if HHI_DMM_PRED_TEX 577 630 memset( m_puiWedgePredTexTabIdx, 0, iSizeInUInt ); 578 631 memset( m_piWedgePredTexDeltaDC1, 0, iSizeInInt ); … … 581 634 memset( m_piContourPredTexDeltaDC1, 0, iSizeInInt ); 582 635 memset( m_piContourPredTexDeltaDC2, 0, iSizeInInt ); 583 584 memset( m_pbTextureModesAllowed, false, iSizeInBool );585 636 #endif 586 637 } … … 611 662 m_pbMergeFlag = pcCU->getMergeFlag() + uiPart; 612 663 m_puhMergeIndex = pcCU->getMergeIndex() + uiPart; 664 #if HHI_INTER_VIEW_RESIDUAL_PRED 613 665 m_pbResPredAvailable = pcCU->getResPredAvail() + uiPart; 614 666 m_pbResPredFlag = pcCU->getResPredFlag () + uiPart; 667 #endif 615 668 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 616 669 { … … 630 683 m_puhWidth=pcCU->getWidth() + uiPart; 631 684 m_puhHeight=pcCU->getHeight() + uiPart; 685 #if HHI_MPI 632 686 m_piTextureModeDepth=pcCU->getTextureModeDepth()+ uiPart; 687 #endif 633 688 634 689 m_apiMVPIdx[0]=pcCU->getMVPIdx(REF_PIC_LIST_0) + uiPart; … … 667 722 m_uiEntropySliceStartCU = pcCU->getEntropySliceStartCU(); 668 723 669 #if HHI_DMM_ INTRA724 #if HHI_DMM_WEDGE_INTRA 670 725 m_puiWedgeFullTabIdx = pcCU->getWedgeFullTabIdx() + uiPart; 671 726 m_piWedgeFullDeltaDC1 = pcCU->getWedgeFullDeltaDC1() + uiPart; … … 676 731 m_piWedgePredDirDeltaDC2 = pcCU->getWedgePredDirDeltaDC2() + uiPart; 677 732 m_piWedgePredDirDeltaEnd = pcCU->getWedgePredDirDeltaEnd() + uiPart; 678 733 #endif 734 #if HHI_DMM_PRED_TEX 679 735 m_puiWedgePredTexTabIdx = pcCU->getWedgePredTexTabIdx() + uiPart; 680 736 m_piWedgePredTexDeltaDC1 = pcCU->getWedgePredTexDeltaDC1() + uiPart; … … 683 739 m_piContourPredTexDeltaDC1 = pcCU->getContourPredTexDeltaDC1() + uiPart; 684 740 m_piContourPredTexDeltaDC2 = pcCU->getContourPredTexDeltaDC2() + uiPart; 685 686 m_pbTextureModesAllowed = pcCU->getTextureModeAllowance() + uiPart;687 741 #endif 688 742 } … … 718 772 m_pbMergeFlag = pcCU->getMergeFlag() + uiAbsPartIdx; 719 773 m_puhMergeIndex = pcCU->getMergeIndex() + uiAbsPartIdx; 774 #if HHI_INTER_VIEW_RESIDUAL_PRED 720 775 m_pbResPredAvailable = pcCU->getResPredAvail() + uiAbsPartIdx; 721 776 m_pbResPredFlag = pcCU->getResPredFlag () + uiAbsPartIdx; 777 #endif 722 778 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui ++ ) 723 779 { … … 731 787 m_acCUMvField[eRefPicList].setMvdPtr(pcCU->getCUMvField(eRefPicList)->getMvd() + uiAbsPartIdx); 732 788 m_acCUMvField[eRefPicList].setRefIdxPtr(pcCU->getCUMvField(eRefPicList)->getRefIdx() + uiAbsPartIdx); 789 #if HHI_MPI 733 790 m_piTextureModeDepth = pcCU->getTextureModeDepth() + uiAbsPartIdx; 791 #endif 734 792 735 793 m_uiSliceStartCU = pcCU->getSliceStartCU(); … … 762 820 memcpy( m_pbMergeFlag + uiOffset, pcCU->getMergeFlag(), iSizeInBool ); 763 821 memcpy( m_puhMergeIndex + uiOffset, pcCU->getMergeIndex(), iSizeInUchar ); 822 #if HHI_INTER_VIEW_RESIDUAL_PRED 764 823 memcpy( m_pbResPredAvailable + uiOffset, pcCU->getResPredAvail(), iSizeInBool ); 765 824 memcpy( m_pbResPredFlag + uiOffset, pcCU->getResPredFlag(), iSizeInBool ); 825 #endif 766 826 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 767 827 { … … 807 867 m_uiEntropySliceStartCU = pcCU->getEntropySliceStartCU(); 808 868 809 #if HHI_DMM_ INTRA869 #if HHI_DMM_WEDGE_INTRA 810 870 memcpy( m_puiWedgeFullTabIdx + uiOffset, pcCU->getWedgeFullTabIdx(), iSizeInUInt ); 811 871 memcpy( m_piWedgeFullDeltaDC1 + uiOffset, pcCU->getWedgeFullDeltaDC1(), iSizeInInt ); … … 816 876 memcpy( m_piWedgePredDirDeltaDC2 + uiOffset, pcCU->getWedgePredDirDeltaDC2(), iSizeInInt ); 817 877 memcpy( m_piWedgePredDirDeltaEnd + uiOffset, pcCU->getWedgePredDirDeltaEnd(), iSizeInInt ); 818 878 #endif 879 #if HHI_DMM_PRED_TEX 819 880 memcpy( m_puiWedgePredTexTabIdx + uiOffset, pcCU->getWedgePredTexTabIdx(), iSizeInUInt ); 820 881 memcpy( m_piWedgePredTexDeltaDC1 + uiOffset, pcCU->getWedgePredTexDeltaDC1(), iSizeInInt ); … … 823 884 memcpy( m_piContourPredTexDeltaDC1 + uiOffset, pcCU->getContourPredTexDeltaDC1(), iSizeInInt ); 824 885 memcpy( m_piContourPredTexDeltaDC2 + uiOffset, pcCU->getContourPredTexDeltaDC2(), iSizeInInt ); 825 826 memcpy( m_pbTextureModesAllowed + uiOffset, pcCU->getTextureModeAllowance(), iSizeInBool ); 827 #endif 828 886 #endif 887 888 #if HHI_MPI 829 889 memcpy( m_piTextureModeDepth + uiOffset, pcCU->getTextureModeDepth(), iSizeInInt ); 890 #endif 830 891 } 831 892 … … 854 915 memcpy( rpcCU->getMergeFlag() + m_uiAbsIdxInLCU, m_pbMergeFlag, iSizeInBool ); 855 916 memcpy( rpcCU->getMergeIndex() + m_uiAbsIdxInLCU, m_puhMergeIndex, iSizeInUchar ); 917 #if HHI_INTER_VIEW_RESIDUAL_PRED 856 918 memcpy( rpcCU->getResPredAvail() + m_uiAbsIdxInLCU, m_pbResPredAvailable, iSizeInBool ); 857 919 memcpy( rpcCU->getResPredFlag() + m_uiAbsIdxInLCU, m_pbResPredFlag, iSizeInBool ); 920 #endif 858 921 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 859 922 { … … 891 954 rpcCU->setEntropySliceStartCU( m_uiEntropySliceStartCU ); 892 955 893 #if HHI_DMM_ INTRA956 #if HHI_DMM_WEDGE_INTRA 894 957 memcpy( rpcCU->getWedgeFullTabIdx() + m_uiAbsIdxInLCU, m_puiWedgeFullTabIdx, iSizeInUInt ); 895 958 memcpy( rpcCU->getWedgeFullDeltaDC1() + m_uiAbsIdxInLCU, m_piWedgeFullDeltaDC1, iSizeInInt ); … … 900 963 memcpy( rpcCU->getWedgePredDirDeltaDC2() + m_uiAbsIdxInLCU, m_piWedgePredDirDeltaDC2, iSizeInInt ); 901 964 memcpy( rpcCU->getWedgePredDirDeltaEnd() + m_uiAbsIdxInLCU, m_piWedgePredDirDeltaEnd, iSizeInInt ); 902 965 #endif 966 #if HHI_DMM_PRED_TEX 903 967 memcpy( rpcCU->getWedgePredTexTabIdx() + m_uiAbsIdxInLCU, m_puiWedgePredTexTabIdx, iSizeInUInt ); 904 968 memcpy( rpcCU->getWedgePredTexDeltaDC1() + m_uiAbsIdxInLCU, m_piWedgePredTexDeltaDC1, iSizeInInt ); … … 907 971 memcpy( rpcCU->getContourPredTexDeltaDC1() + m_uiAbsIdxInLCU, m_piContourPredTexDeltaDC1, iSizeInInt ); 908 972 memcpy( rpcCU->getContourPredTexDeltaDC2() + m_uiAbsIdxInLCU, m_piContourPredTexDeltaDC2, iSizeInInt ); 909 910 memcpy( rpcCU->getTextureModeAllowance() + m_uiAbsIdxInLCU, m_pbTextureModesAllowed, iSizeInBool ); 911 #endif 912 973 #endif 974 975 #if HHI_MPI 913 976 memcpy( rpcCU->getTextureModeDepth() + m_uiAbsIdxInLCU, m_piTextureModeDepth, iSizeInInt ); 977 #endif 914 978 } 915 979 … … 939 1003 memcpy( rpcCU->getMergeFlag() + uiPartOffset, m_pbMergeFlag, iSizeInBool ); 940 1004 memcpy( rpcCU->getMergeIndex() + uiPartOffset, m_puhMergeIndex, iSizeInUchar ); 1005 #if HHI_INTER_VIEW_RESIDUAL_PRED 941 1006 memcpy( rpcCU->getResPredAvail() + uiPartOffset, m_pbResPredAvailable, iSizeInBool ); 942 1007 memcpy( rpcCU->getResPredFlag() + uiPartOffset, m_pbResPredFlag, iSizeInBool ); 1008 #endif 943 1009 for( UInt ui = 0; ui < MRG_MAX_NUM_CANDS; ui++ ) 944 1010 { … … 975 1041 rpcCU->setEntropySliceStartCU( m_uiEntropySliceStartCU ); 976 1042 977 #if HHI_DMM_ INTRA1043 #if HHI_DMM_WEDGE_INTRA 978 1044 memcpy( rpcCU->getWedgeFullTabIdx() + uiPartOffset, m_puiWedgeFullTabIdx, iSizeInUInt ); 979 1045 memcpy( rpcCU->getWedgeFullDeltaDC1() + uiPartOffset, m_piWedgeFullDeltaDC1, iSizeInInt ); … … 984 1050 memcpy( rpcCU->getWedgePredDirDeltaDC2() + uiPartOffset, m_piWedgePredDirDeltaDC2, iSizeInInt ); 985 1051 memcpy( rpcCU->getWedgePredDirDeltaEnd() + uiPartOffset, m_piWedgePredDirDeltaEnd, iSizeInInt ); 986 1052 #endif 1053 #if HHI_DMM_PRED_TEX 987 1054 memcpy( rpcCU->getWedgePredTexTabIdx() + uiPartOffset, m_puiWedgePredTexTabIdx, iSizeInUInt ); 988 1055 memcpy( rpcCU->getWedgePredTexDeltaDC1() + uiPartOffset, m_piWedgePredTexDeltaDC1, iSizeInInt ); … … 991 1058 memcpy( rpcCU->getContourPredTexDeltaDC1() + uiPartOffset, m_piContourPredTexDeltaDC1, iSizeInInt ); 992 1059 memcpy( rpcCU->getContourPredTexDeltaDC2() + uiPartOffset, m_piContourPredTexDeltaDC2, iSizeInInt ); 993 994 memcpy( rpcCU->getTextureModeAllowance() + uiPartOffset, m_pbTextureModesAllowed, iSizeInBool ); 995 #endif 996 1060 #endif 1061 1062 #if HHI_MPI 997 1063 memcpy( rpcCU->getTextureModeDepth() + uiPartOffset, m_piTextureModeDepth, iSizeInInt ); 1064 #endif 998 1065 } 999 1066 … … 1356 1423 } 1357 1424 1358 1359 #if HHI_DMM_INTRA 1425 #if HHI_DMM_WEDGE_INTRA 1360 1426 Void TComDataCU::setWedgeFullTabIdxSubParts( UInt uiTIdx, UInt uiAbsPartIdx, UInt uiDepth ) 1361 1427 { … … 1427 1493 } 1428 1494 } 1429 1495 #endif 1496 #if HHI_DMM_PRED_TEX 1430 1497 Void TComDataCU::setWedgePredTexTabIdxSubParts( UInt uiTIdx, UInt uiAbsPartIdx, UInt uiDepth ) 1431 1498 { … … 1477 1544 } 1478 1545 } 1479 1480 Void TComDataCU::setTextureModeAllowanceSubParts ( Bool bTMAllowed, UInt uiAbsPartIdx, UInt uiDepth ) 1481 { 1482 UInt uiCurrPartNumb = m_pcPic->getNumPartInCU() >> (uiDepth << 1); 1483 1484 memset( m_pbTextureModesAllowed + uiAbsPartIdx, bTMAllowed, sizeof(Bool)*uiCurrPartNumb ); 1485 } 1486 #endif 1487 1546 #endif 1547 1548 #if HHI_INTER_VIEW_MOTION_PRED 1488 1549 Int 1489 1550 TComDataCU::getPdmMergeCandidate( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv ) … … 1511 1572 return pcDepthMapGenerator->getIViewOrgDepthMvPred( this, uiPartIdx, eRefPicList, iRefIdx, rcMv ); 1512 1573 } 1513 1574 #endif 1575 1576 1577 #if HHI_INTER_VIEW_RESIDUAL_PRED 1514 1578 Bool 1515 1579 TComDataCU::getResidualSamples( UInt uiPartIdx, TComYuv* pcYuv ) … … 1519 1583 return pcResidualGenerator->getResidualSamples( this, uiPartIdx, pcYuv ); 1520 1584 } 1585 #endif 1521 1586 1522 1587 … … 1533 1598 mapPlanartoDC( iLeftIntraDir ); 1534 1599 #endif 1535 #if HHI_DMM_ INTRA1600 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 1536 1601 mapDMMtoDC( iLeftIntraDir ); 1537 1602 #endif … … 1543 1608 mapPlanartoDC( iAboveIntraDir ); 1544 1609 #endif 1545 #if HHI_DMM_ INTRA1610 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 1546 1611 mapDMMtoDC( iAboveIntraDir ); 1547 1612 #endif … … 1578 1643 mapPlanartoDC( iLeftIntraDir ); 1579 1644 #endif 1580 #if HHI_DMM_ INTRA1645 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 1581 1646 mapDMMtoDC( iLeftIntraDir ); 1582 1647 #endif … … 1588 1653 mapPlanartoDC( iAboveIntraDir ); 1589 1654 #endif 1590 #if HHI_DMM_ INTRA1655 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 1591 1656 mapDMMtoDC( iAboveIntraDir ); 1592 1657 #endif … … 1693 1758 } 1694 1759 1695 #if MW_MVI_SIGNALLING_MODE == 01696 UInt TComDataCU::getCtxMvInheritanceFlag( UInt uiAbsPartIdx, UInt uiDepth )1697 {1698 // return 0; // MW1699 TComDataCU* pcTempCU;1700 UInt uiTempPartIdx;1701 UInt uiCtx;1702 // Get left split flag1703 pcTempCU = getPULeft( uiTempPartIdx, m_uiAbsIdxInLCU + uiAbsPartIdx );1704 uiCtx = ( pcTempCU ) ? ( ( pcTempCU->getTextureModeDepth( uiTempPartIdx ) == uiDepth ) ? 1 : 0 ) : 0;1705 1706 // Get above split flag1707 pcTempCU = getPUAbove( uiTempPartIdx, m_uiAbsIdxInLCU + uiAbsPartIdx );1708 uiCtx += ( pcTempCU ) ? ( ( pcTempCU->getTextureModeDepth( uiTempPartIdx ) == uiDepth ) ? 1 : 0 ) : 0;1709 1710 return uiCtx;1711 }1712 #endif1713 1714 1760 UInt TComDataCU::getCtxIntraDirChroma( UInt uiAbsPartIdx ) 1715 1761 { … … 2148 2194 } 2149 2195 2196 #if HHI_INTER_VIEW_RESIDUAL_PRED 2150 2197 Void TComDataCU::setResPredAvailSubParts( Bool bResPredAvailable, UInt uiAbsPartIdx, UInt uiPartIdx, UInt uiDepth ) 2151 2198 { … … 2157 2204 setSubPartBool( bResPredFlag, m_pbResPredFlag, uiAbsPartIdx, uiDepth, uiPartIdx ); 2158 2205 } 2206 #endif 2159 2207 2160 2208 Void TComDataCU::setChromIntraDirSubParts( UInt uiDir, UInt uiAbsPartIdx, UInt uiDepth ) … … 2632 2680 { 2633 2681 UInt uiAbsPartAddr = m_uiAbsIdxInLCU + uiAbsPartIdx; 2682 #if HHI_INTER_VIEW_MOTION_PRED 2634 2683 Bool bNoPdmMerge = ( m_pcSlice->getSPS()->getViewId() == 0 || ( m_pcSlice->getSPS()->getMultiviewMvPredMode() & PDM_USE_FOR_MERGE ) != PDM_USE_FOR_MERGE ); 2635 2684 UInt uiPdmMergePos = ( bNoPdmMerge ? 5 : PDM_MERGE_POS ); … … 2640 2689 UInt uiCorBLAddr = ( uiPdmMergePos < 5 ? 5 : 4 ); 2641 2690 UInt uiPdmAddr = uiPdmMergePos; 2691 #else 2692 UInt uiLeftAddr = 0; 2693 UInt uiAboveAddr = 1; 2694 UInt uiColocAddr = 2; 2695 UInt uiCorRTAddr = 3; 2696 UInt uiCorBLAddr = 4; 2697 #endif 2642 2698 2643 2699 bool abCandIsInter[ MRG_MAX_NUM_CANDS ]; … … 3099 3155 3100 3156 3157 #if HHI_INTER_VIEW_MOTION_PRED 3101 3158 //===== add merge with predicted depth maps ===== 3102 3159 TComMv acPdmMv [2]; … … 3124 3181 } 3125 3182 } 3183 #endif 3126 3184 3127 3185 … … 3320 3378 Int iLeftIdx = -1; 3321 3379 3380 #if HHI_INTER_VIEW_MOTION_PRED 3322 3381 #if ( PDM_AMVP_POS == 0 ) 3323 3382 // get inter-view mv predictor (at position 0) … … 3328 3387 pInfo->m_acMvCand[ pInfo->iN++ ] = cPdmMvPred; 3329 3388 } 3389 #endif 3330 3390 #endif 3331 3391 … … 3388 3448 3389 3449 3450 #if HHI_INTER_VIEW_MOTION_PRED 3390 3451 #if ( PDM_AMVP_POS == 1 ) 3391 3452 // get inter-view mv predictor (at position 1) … … 3397 3458 } 3398 3459 #endif 3399 3460 #endif 3400 3461 3401 3462 … … 3595 3656 3596 3657 3658 #if HHI_INTER_VIEW_MOTION_PRED 3597 3659 #if ( PDM_AMVP_POS == 2 ) 3598 3660 // get inter-view mv predictor (at position 2) … … 3604 3666 } 3605 3667 #endif 3606 3668 #endif 3607 3669 3608 3670 // Get Temporal Motion Predictor … … 3754 3816 3755 3817 3818 #if HHI_INTER_VIEW_MOTION_PRED 3756 3819 #if ( PDM_AMVP_POS == 3 ) 3757 3820 // get inter-view mv predictor (at position 3) … … 3763 3826 } 3764 3827 #endif 3765 3828 #endif 3766 3829 3767 3830 // Check No MV Candidate … … 3854 3917 { 3855 3918 Int iMvShift = 2; 3856 #if MW_DEPTH_MAP_INTERP_FILTER == 2 && MW_FULL_PEL_DEPTH_MAP_MV_SIGNALLING3919 #if HHI_FULL_PEL_DEPTH_MAP_MV_ACC 3857 3920 if( getSlice()->getSPS()->isDepth() ) 3858 3921 iMvShift = 0; … … 4676 4739 #endif 4677 4740 4741 #if HHI_MPI 4678 4742 Void TComDataCU::setTextureModeDepthSubParts( Int iTextureModeDepth, UInt uiAbsPartIdx, UInt uiDepth ) 4679 4743 { … … 4692 4756 Int iSizeInUchar = sizeof( UChar ) * uiNumPartition; 4693 4757 Int iSizeInInt = sizeof( Int ) * uiNumPartition; 4694 //#if HHI_MRG 4695 // Int iSizeInBool = sizeof( Bool ) * uiNumPartition; 4696 //#endif 4697 4698 // memcpy( m_pePartSize + uiAbsPartIdxDst, pcCU->getPartitionSize() + uiAbsPartIdxSrc, sizeof( PartSize ) * uiNumPartition ); 4758 4699 4759 memcpy( m_pePredMode + uiAbsPartIdxDst, pcCU->getPredictionMode() + uiAbsPartIdxSrc, sizeof( PredMode ) * uiNumPartition ); 4700 4760 memcpy( m_puhInterDir + uiAbsPartIdxDst, pcCU->getInterDir() + uiAbsPartIdxSrc, iSizeInUchar ); 4701 4702 //#if HHI_MRG4703 // m_pbMergeFlag = pcCU->getMergeFlag() + uiAbsPartIdx;4704 // m_puhMergeIndex = pcCU->getMergeIndex() + uiAbsPartIdx;4705 // for( UInt ui = 0; ui < HHI_NUM_MRG_CAND; ui ++ )4706 // {4707 // m_apuhNeighbourCandIdx[ui] = pcCU->getNeighbourCandIdx( ui ) + uiAbsPartIdx;4708 // }4709 //#endif4710 4761 4711 4762 memcpy( m_apiMVPIdx[0] + uiAbsPartIdxDst, pcCU->getMVPIdx(REF_PIC_LIST_0) + uiAbsPartIdxSrc, iSizeInInt ); … … 4714 4765 memcpy( m_apiMVPNum[1] + uiAbsPartIdxDst, pcCU->getMVPNum(REF_PIC_LIST_1) + uiAbsPartIdxSrc, iSizeInInt ); 4715 4766 4716 // m_acCUMvField[0].copyFrom( pcCU->getCUMvField( REF_PIC_LIST_0 ), pcCU->getTotalNumPart(), 0 );4717 // m_acCUMvField[1].copyFrom( pcCU->getCUMvField( REF_PIC_LIST_1 ), pcCU->getTotalNumPart(), 0 );4718 4719 4767 pcCU->getCUMvField( REF_PIC_LIST_0 )->copyTo( &m_acCUMvField[0], -Int(uiAbsPartIdxSrc) + uiAbsPartIdxDst, uiAbsPartIdxSrc, uiNumPartition ); 4720 4768 pcCU->getCUMvField( REF_PIC_LIST_1 )->copyTo( &m_acCUMvField[1], -Int(uiAbsPartIdxSrc) + uiAbsPartIdxDst, uiAbsPartIdxSrc, uiNumPartition ); 4721 #if MW_DEPTH_MAP_INTERP_FILTER == 2 && MW_FULL_PEL_DEPTH_MAP_MV_SIGNALLING4769 #if HHI_FULL_PEL_DEPTH_MAP_MV_ACC 4722 4770 for( UInt ui = 0; ui < uiNumPartition; ui++ ) 4723 4771 { … … 4736 4784 #endif 4737 4785 } 4786 #endif 4738 4787 4739 4788 Void TComDataCU::getPosInPic( UInt uiAbsPartIndex, Int& riPosX, Int& riPosY ) -
trunk/source/Lib/TLibCommon/TComDataCU.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 51 84 UChar* m_puhHeight; ///< array of heights 52 85 UChar* m_puhDepth; ///< array of depths 86 #if HHI_MPI 53 87 Int* m_piTextureModeDepth; ///< at which depth is prediction data inherited from texture picture ( -1 : none ) 88 #endif 54 89 55 90 // ------------------------------------------------------------------------------------------------------------------- … … 90 125 Bool* m_pbMergeFlag; ///< array of merge flags 91 126 UChar* m_puhMergeIndex; ///< array of merge candidate indices 127 #if HHI_INTER_VIEW_RESIDUAL_PRED 92 128 Bool* m_pbResPredAvailable; ///< array of residual prediction available flags 93 129 Bool* m_pbResPredFlag; ///< array of residual prediction flags 130 #endif 94 131 UChar* m_apuhNeighbourCandIdx[ MRG_MAX_NUM_CANDS ];///< array of motion vector predictor candidates indices 95 132 UChar* m_puhLumaIntraDir; ///< array of intra directions (luma) … … 100 137 UInt* m_puiAlfCtrlFlag; ///< array of ALF flags 101 138 UInt* m_puiTmpAlfCtrlFlag; ///< temporal array of ALF flags 102 #if HHI_DMM_ INTRA139 #if HHI_DMM_WEDGE_INTRA 103 140 UInt* m_puiWedgeFullTabIdx; 104 141 Int* m_piWedgeFullDeltaDC1; … … 109 146 Int* m_piWedgePredDirDeltaDC2; 110 147 Int* m_piWedgePredDirDeltaEnd; 111 148 #endif 149 #if HHI_DMM_PRED_TEX 112 150 UInt* m_puiWedgePredTexTabIdx; 113 151 Int* m_piWedgePredTexDeltaDC1; … … 116 154 Int* m_piContourPredTexDeltaDC1; 117 155 Int* m_piContourPredTexDeltaDC2; 118 119 Bool* m_pbTextureModesAllowed;120 156 #endif 121 157 … … 201 237 Void setDepth ( UInt uiIdx, UChar uh ) { m_puhDepth[uiIdx] = uh; } 202 238 239 #if HHI_MPI 203 240 Int* getTextureModeDepth () { return m_piTextureModeDepth; } 204 241 Int getTextureModeDepth ( UInt uiIdx ) { return m_piTextureModeDepth[uiIdx]; } … … 206 243 Void setTextureModeDepthSubParts( Int iTextureModeDepth, UInt uiAbsPartIdx, UInt uiDepth ); 207 244 Void copyTextureMotionDataFrom( TComDataCU* pcCU, UInt uiDepth, UInt uiAbsPartIdxSrc, UInt uiAbsPartIdxDst = 0 ); 245 #endif 208 246 209 247 Void setDepthSubParts ( UInt uiDepth, UInt uiAbsPartIdx ); … … 291 329 Void setNeighbourCandIdxSubParts ( UInt uiCandIdx, UChar uhNumCands, UInt uiAbsPartIdx, UInt uiPartIdx, UInt uiDepth ); 292 330 331 #if HHI_INTER_VIEW_RESIDUAL_PRED 293 332 Bool* getResPredAvail () { return m_pbResPredAvailable; } 294 333 Bool getResPredAvail ( UInt uiIdx ) { return m_pbResPredAvailable[uiIdx]; } … … 302 341 303 342 Void setResPredIndicator ( Bool bAv, Bool bRP ) { m_pbResPredAvailable[0] = bAv; m_pbResPredFlag[0] = bRP; } 343 #endif 304 344 305 345 Void setSubPartBool ( Bool bParameter, Bool* pbBaseLCU, UInt uiCUAddr, UInt uiCUDepth, UInt uiPUIdx ); … … 331 371 Void copyAlfCtrlFlagFromTmp(); 332 372 333 #if HHI_DMM_ INTRA373 #if HHI_DMM_WEDGE_INTRA 334 374 UInt* getWedgeFullTabIdx () { return m_puiWedgeFullTabIdx; } 335 375 UInt getWedgeFullTabIdx ( UInt uiIdx ) { return m_puiWedgeFullTabIdx[uiIdx]; } … … 366 406 Void setWedgePredDirDeltaEnd ( UInt uiIdx, Int iD ) { m_piWedgePredDirDeltaEnd[uiIdx] = iD; } 367 407 Void setWedgePredDirDeltaEndSubParts( Int iDelta, UInt uiAbsPartIdx, UInt uiDepth ); 368 408 #endif 409 #if HHI_DMM_PRED_TEX 369 410 UInt* getWedgePredTexTabIdx () { return m_puiWedgePredTexTabIdx; } 370 411 UInt getWedgePredTexTabIdx ( UInt uiIdx ) { return m_puiWedgePredTexTabIdx[uiIdx]; } … … 391 432 Void setContourPredTexDeltaDC2 ( UInt uiIdx, Int i ) { m_piContourPredTexDeltaDC2[uiIdx] = i; } 392 433 Void setContourPredTexDeltaDC2SubParts( Int iDC2, UInt uiAbsPartIdx, UInt uiDepth ); 393 394 Bool* getTextureModeAllowance () { return m_pbTextureModesAllowed; } 395 Bool getTextureModeAllowance ( UInt uiIdx ) { return m_pbTextureModesAllowed[uiIdx]; } 396 Void setTextureModeAllowance ( UInt uiIdx, Bool b ) { m_pbTextureModesAllowed[uiIdx] = b; } 397 Void setTextureModeAllowanceSubParts ( Bool bTMAllowed, UInt uiAbsPartIdx, UInt uiDepth ); 398 #endif 399 434 #endif 435 436 #if HHI_INTER_VIEW_MOTION_PRED 400 437 Int getPdmMergeCandidate( UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv ); 401 438 Bool getPdmMvPred( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, Bool bMerge = false ); 402 439 Bool getIViewOrgDepthMvPred( UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv ); 440 #endif 441 #if HHI_INTER_VIEW_RESIDUAL_PRED 403 442 Bool getResidualSamples( UInt uiPartIdx, TComYuv* pcYuv = 0 ); 443 #endif 404 444 405 445 // ------------------------------------------------------------------------------------------------------------------- … … 517 557 518 558 UInt getCtxSplitFlag ( UInt uiAbsPartIdx, UInt uiDepth ); 519 #if MW_MVI_SIGNALLING_MODE == 0520 UInt getCtxMvInheritanceFlag ( UInt uiAbsPartIdx, UInt uiDepth );521 #endif522 559 UInt getCtxCbf ( UInt uiAbsPartIdx, TextType eType, UInt uiTrDepth ); 523 560 UInt getCtxQtCbf ( UInt uiAbsPartIdx, TextType eType, UInt uiTrDepth ); -
trunk/source/Lib/TLibCommon/TComDepthMapGenerator.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 10 43 #include "TComDepthMapGenerator.h" 11 44 45 46 #if DEPTH_MAP_GENERATION 12 47 13 48 … … 462 497 463 498 499 #if HHI_INTER_VIEW_MOTION_PRED 464 500 Void 465 501 TComDepthMapGenerator::covertOrgDepthMap( TComPic* pcPic ) … … 483 519 } 484 520 } 485 521 #endif 486 522 487 523 Int … … 501 537 502 538 539 #if HHI_INTER_VIEW_MOTION_PRED 503 540 Int 504 541 TComDepthMapGenerator::getPdmMergeCandidate( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv ) … … 674 711 return true; 675 712 } 676 713 #endif 677 714 678 715 … … 1409 1446 } 1410 1447 1448 #endif // DEPTH_MAP_GENERATION 1449 -
trunk/source/Lib/TLibCommon/TComDepthMapGenerator.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 15 48 #include "TComSlice.h" 16 49 50 51 #if DEPTH_MAP_GENERATION 17 52 18 53 … … 29 64 30 65 UInt getPdm () { if( m_aacActiveSPS[0][1] ) { return m_aacActiveSPS[0][1]->getPredDepthMapGeneration(); } return 0; } 66 #if HHI_INTER_VIEW_RESIDUAL_PRED 31 67 UInt getResPrd () { if( m_aacActiveSPS[0][1] ) { return m_aacActiveSPS[0][1]->getMultiviewResPredMode (); } return 0; } 68 #endif 32 69 33 70 private: … … 84 121 Void dumpDepthMap ( TComPic* pcPic, char* pFilenameBase ); 85 122 123 #if HHI_INTER_VIEW_MOTION_PRED 86 124 Void covertOrgDepthMap ( TComPic* pcPic ); 125 #endif 87 126 88 127 UInt getBaseViewId ( UInt uiIdx ) { AOF( uiIdx < m_auiBaseIdList.size() ); return m_auiBaseIdList[uiIdx]; } 89 128 Int getDisparity ( TComPic* pcPic, Int iPosX, Int iPosY, UInt uiRefViewId ); 129 #if HHI_INTER_VIEW_MOTION_PRED 90 130 Int getPdmMergeCandidate ( TComDataCU* pcCU, UInt uiPartIdx, Int* paiPdmRefIdx, TComMv* pacPdmMv ); 91 131 Bool getPdmMvPred ( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv, Bool bMerge ); 92 132 Bool getIViewOrgDepthMvPred( TComDataCU* pcCU, UInt uiPartIdx, RefPicList eRefPicList, Int iRefIdx, TComMv& rcMv ); 133 #endif 93 134 94 135 TComPrediction* getPrediction () { return m_pcPrediction; } … … 177 218 }; 178 219 220 221 #endif // DEPTH_MAP_GENERATION 222 179 223 #endif // __TCOM_DEPTH_MAP_GENERATOR__ 180 224 -
trunk/source/Lib/TLibCommon/TComList.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComLoopFilter.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComLoopFilter.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComMVDRefData.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 9 42 #include <fstream> 10 43 44 #if HHI_VSO 11 45 Void TComMVDRefData::setPicYuvBaseView( InterViewReference eView, Bool bDepth, TComPicYuv* pcOrgView, TComPicYuv* pcRecView ) 12 46 { … … 31 65 TComMVDRefData::TComMVDRefData() 32 66 { 33 //GT VSO34 67 m_adERViewShiftLUT = 0; 35 68 m_aiERViewShiftLUT = 0; 36 69 m_apcExternalReferenceViews.resize(0); 37 //GT VSO end38 70 39 71 for (UInt uiView = 0; uiView < 3; uiView++) … … 44 76 m_apcDepthRec[uiView] = NULL; 45 77 46 //GT VSO47 78 m_adBaseViewShiftLUT [uiView] = NULL; 48 79 m_aiBaseViewShiftLUT [uiView] = NULL; 49 //GT VSO end 80 50 81 }; 51 82 } 52 83 53 //GT VSO54 84 Void TComMVDRefData::getRefPicYuvAndLUT( TComPicYuv**& rpacDistRefPicList, Int***& rppaiShiftLut ) 55 85 { 56 //GT57 58 86 UInt uiNextEntry = 0; 59 87 for ( UInt uiViewIdx = 0; uiViewIdx < m_aiExtViewRefInd.size(); uiViewIdx++ ) … … 78 106 rppaiShiftLut[2] = m_aiBaseViewShiftLUT[ NEXTVIEW ]; 79 107 80 //GT: Only orginals of this view needed for Mode 1;81 108 rpacDistRefPicList[0] = NULL; 82 109 rpacDistRefPicList[1] = NULL; 83 110 rpacDistRefPicList[2] = NULL; 84 111 } 85 //GT VSO end 86 87 88 89 90 //Void TComMVDRefData::render( TComPicYuv* pOut ) 91 ////Void TComMVDRefData::render( TComPicYuv* pIn, TComPicYuv* pOut, TComPicYuv* pDepth, Long** aalLUT ) 92 //{ 93 // 94 // std::cout << "InRender" << std::endl; 95 // 96 // TComPicYuv* pIn = getPicYuvOrgVideo(CURRVIEW); 97 // // TComPicYuv* pOut = getRecVideo(CURRVIEW); 98 // TComPicYuv* pDepth = getPicYuvOrgDepth(CURRVIEW); 99 // 100 // Int** aaiLUT = getShiftLUTIERView(0); 101 // 102 // Int iHeight = (Int) pIn->getHeight(); 103 // Int iWidth = (Int) pIn->getWidth(); 104 // 105 // Pel* piSourceLumaData = pIn ->getLumaAddr(); 106 // Pel* piTargetLumaData = pOut ->getLumaAddr(); 107 // Pel* piDepthData = pDepth->getLumaAddr(); 108 // 109 // Int iSourceLumaStride = pIn ->getStride(); 110 // Int iTargetLumaStride = pOut ->getStride(); 111 // Int iDepthStride = pDepth->getStride(); 112 // 113 // 114 // for (Int iY = 0; iY < iHeight; iY++) 115 // { 116 // for (Int iX = 0; iX < iWidth; iX++) 117 // { 118 // piTargetLumaData[iX] = 0; 119 // } 120 // piTargetLumaData += iTargetLumaStride; 121 // } 122 // 123 // piTargetLumaData = pOut ->getLumaAddr(); 124 // 125 // Int iNewPos; 126 // for (Int iY = 0; iY < iHeight; iY++) 127 // { 128 // for (Int iX = 0; iX < iWidth; iX++) 129 // { 130 // iNewPos = iX - aaiLUT[0][(piDepthData[iX] >> g_uiBitIncrement)]; 131 // iNewPos = (iNewPos < 0 ) ? 0 : iNewPos; 132 // iNewPos = (iNewPos >= iWidth) ? iWidth - 1 : iNewPos; 133 // 134 // piTargetLumaData[iNewPos] = piSourceLumaData[iX]; 135 // } 136 // piSourceLumaData += iSourceLumaStride; 137 // piTargetLumaData += iTargetLumaStride; 138 // piDepthData += iDepthStride; 139 // } 140 //} 141 // 142 // 143 // 144 // 145 //TComRendererModel::TComRendererModel() 146 //{ 147 // m_pcInputSamples = NULL; 148 // m_pcOutputSamples = NULL; 149 // m_ppiShiftLUT = NULL; 150 //} 151 // 152 //TComRendererModel::~TComRendererModel() 153 //{ 154 // if ( m_pcOutputSamples ) 155 // delete[] m_pcOutputSamples; 156 // 157 // if ( m_pcInputSamples ) 158 // delete[] m_pcInputSamples; 159 // 160 //} 161 // 162 //Void TComRendererModel::createModel( TComPicYuv* pcYuvDepth, TComPicYuv* pcYuvVideo, TComPicYuv* pcYuvRef, Int** ppiShiftLUT ) 163 //{ 164 // createModel(pcYuvDepth->getLumaAddr(), pcYuvDepth->getStride(), pcYuvVideo->getLumaAddr(), pcYuvVideo->getStride(), pcYuvVideo->getCbAddr(), pcYuvVideo->getCrAddr(), pcYuvVideo->getCStride(), pcYuvVideo->getWidth(), pcYuvVideo->getHeight(), ppiShiftLUT ); 165 //} 166 // 167 //Void TComRendererModel::createModel( TComPicYuv* pcYuvDepth, TComPicYuv* pcYuvVideo, Int** ppiShiftLUT ) 168 //{ 169 // 170 //} 171 // 172 //Void TComRendererModel::createModel( Pel* pcPelDisp, Int iStrideDisp, Pel* pcPelY, Int iStrideY, Pel* pcPelU, Pel* pcPelV, Int iStrideC, Int iWidth, Int iHeight, Int** ppiShiftLUT ) 173 //{ 174 // 175 //} 176 // 177 //Void TComRendererModel::xCreateRenderedView( Pel* pcPelDisp, Int iDispStride, Pel* pcPelY, Int iLStride, Pel* pcPelU, Pel* pcPelV, Int iCStride, Int iWidth, Int iHeight, Int** ppiShiftLUT,Bool bSAD ) 178 //{ 179 // m_ppiShiftLUT = ppiShiftLUT; 180 // m_iWidth = iWidth; 181 // m_iHeight = iHeight; 182 // m_iStride = iWidth; 183 // 184 // m_pcOutputSamples = new RendererOutputSample[ iWidth * iHeight]; 185 // m_pcInputSamples = new RendererInputSample [ iWidth * iHeight]; 186 // 187 // RendererInputSample* pcInputSamples = m_pcInputSamples ; 188 // RendererOutputSample* pcOutputSamples = m_pcOutputSamples ; 189 // 190 // for ( Int iRow = 0; iRow < iHeight; iRow++ ) 191 // { 192 // for ( Int iCol = 0; iCol < iWidth; iCol++ ) 193 // { 194 // pcInputSamples[iCol].m_uiPosX = iCol; 195 // pcInputSamples[iCol].m_uiY = pcPelY[ iCol ]; 196 // pcInputSamples[iCol].m_uiU = pcPelU[ iCol >> 1 ]; 197 // pcInputSamples[iCol].m_uiV = pcPelV[ iCol >> 1 ]; 198 // pcOutputSamples[iCol].m_iErr = 0; 199 // 200 // pcInputSamples[iCol].m_iPosShifted = iCol + m_ppiShiftLUT[0][ pcPelDisp[ iCol ] ]; 201 // pcInputSamples[iCol].m_uiDisp = pcPelDisp[ iCol ]; 202 // 203 // } 204 // 205 // pcInputSamples += m_iStride; 206 // pcOutputSamples += m_iStride; 207 // pcPelY += iLStride; 208 // pcPelDisp += iDispStride; 209 // 210 // if ( iRow & 1 ) 211 // { 212 // pcPelU += iCStride; 213 // pcPelV += iCStride; 214 // } 215 // 216 // } 217 // 218 // m_lErr = 0; 219 // Long lDump; 220 // changeModel(0,0,m_iWidth, m_iHeight, pcPelDisp, iDispStride, lDump, bSAD); 221 //} 222 // 223 //Void TComRendererModel::changeModel( Int iPosX, Int iPosY, Int iWidth, Int iHeight, Pel* pcPelDisp, Int iDispStride, Long& rlErr, Bool bSAD ) 224 //{ 225 // RendererInputSample* pcInputSamples = m_pcInputSamples ; 226 // RendererOutputSample* pcOutputSamples = m_pcOutputSamples ; 227 // 228 // Int iMinChangedPosition = 0; 229 // Int iMaxChangedPosition = m_iWidth - 1; 230 // 231 // rlErr = 0; 232 // 233 // for ( Int iRow = iPosX; iRow < iHeight; iRow++ ) 234 // { 235 // // Add and Remove samples (Update Model) 236 // for ( Int iCol = iPosY; iCol < iWidth; iCol++ ) 237 // { 238 // // Remove from old position 239 // Int iOldPosShifted = pcInputSamples[iCol].m_iPosShifted; 240 // 241 // iMinChangedPosition = Min( iOldPosShifted, iMinChangedPosition ); 242 // iMaxChangedPosition = Max( iOldPosShifted, iMaxChangedPosition ); 243 // 244 // pcOutputSamples[ iOldPosShifted ].removeInputSample( &(pcInputSamples[iCol]) ); 245 // 246 // // Add to new position 247 // Int iShift = m_ppiShiftLUT[0][ pcPelDisp[ iCol ] ]; 248 // 249 // Int iPosShifted = iPosX + iShift; 250 // 251 // iPosShifted = Min(Max(iPosShifted, 0), m_iWidth - 1); 252 // iMinChangedPosition = Min(iPosShifted, iMinChangedPosition); 253 // iMaxChangedPosition = Max(iPosShifted, iMaxChangedPosition); 254 // 255 // pcInputSamples[iCol].m_uiDisp = pcPelDisp[ iCol ]; 256 // pcInputSamples[iCol].m_iPosShifted = iPosShifted; 257 // 258 // pcOutputSamples[ iPosShifted ].addInputSample( &(pcInputSamples[iCol]) ); 259 // } 260 // 261 // // ReRender 262 // 263 // // Get Top Plane 264 // Int iMaxInd = -1; 265 // 266 // if ( pcOutputSamples[iMinChangedPosition].m_pcTopSample ) 267 // { 268 // iMaxInd = pcOutputSamples[iMinChangedPosition].m_pcTopSample->m_uiPosX; 269 // } 270 // 271 // if ( iMinChangedPosition > 0 && pcOutputSamples[iMinChangedPosition].m_pcTopSample ) 272 // { 273 // iMaxInd = Max( iMaxInd, pcOutputSamples[iMinChangedPosition-1].m_pcTopSample->m_uiPosX ); 274 // } 275 // 276 // for ( Int iCol = iMinChangedPosition; iCol <= iMaxChangedPosition; iCol++ ) 277 // { 278 // if ( pcOutputSamples[iCol].m_pcTopSample == NULL ) 279 // { 280 // if ( pcOutputSamples[iCol+1].m_pcTopSample == NULL ) 281 // { 282 // // Hole Filling 283 // Int iFillStartCol = iCol; 284 // iCol++; 285 // 286 // while( ( pcOutputSamples[iCol].m_pcTopSample == NULL ) && (iMinChangedPosition < iMaxChangedPosition) ) iCol++; 287 // 288 // for ( int iFillCol = iFillStartCol; iFillCol < iCol; iFillCol++ ) 289 // { 290 // pcOutputSamples[iFillCol].assignValues( pcOutputSamples[iCol], rlErr, bSAD ); 291 // } 292 // 293 // if ( iMaxInd == -1 ) 294 // { 295 // iMaxInd = pcOutputSamples[iCol].m_pcTopSample->m_uiPosX; 296 // } 297 // } 298 // else 299 // { 300 // // Fill Gap here 301 // pcOutputSamples[iCol].assignValues( pcOutputSamples[iCol-1], rlErr, bSAD ); 302 // 303 // }; 304 // } 305 // else 306 // { 307 // if ( pcOutputSamples[iCol].m_pcTopSample->m_uiPosX > iMaxInd) 308 // { 309 // iMaxInd = pcOutputSamples[iCol].m_pcTopSample->m_uiPosX; 310 // 311 // //assign this Sample 312 // pcOutputSamples[iCol].assignValues( pcOutputSamples[iCol], rlErr, bSAD ); 313 // } 314 // else 315 // { 316 // //assign last sample 317 // pcOutputSamples[iCol].assignValues( pcOutputSamples[iCol-1], rlErr, bSAD ); 318 // } 319 // } 320 // } 321 // 322 // pcInputSamples += m_iStride; 323 // pcPelDisp += iDispStride; 324 // 325 // } 326 //} 327 // 328 //Void RendererOutputSample::assignValues( RendererOutputSample& rpcOutputSample, Long& rlErr, Bool bSAD ) 329 //{ 330 // m_uiY = rpcOutputSample.m_uiYRef; 331 // m_uiU = rpcOutputSample.m_uiURef; 332 // m_uiV = rpcOutputSample.m_uiVRef; 333 // 334 // rlErr -= m_iErr; 335 // 336 // int iErr = m_uiY - m_uiYRef; 337 // 338 // if (bSAD) 339 // { 340 // rlErr += abs(iErr); 341 // } 342 // else 343 // { 344 // rlErr += iErr * iErr; 345 // } 346 //} 347 // 348 //Void RendererOutputSample::addInputSample( RendererInputSample* pcInputSample ) 349 //{ 350 // if ( m_acInputSamples.size() == 0 ) 351 // { 352 // m_acInputSamples.push_back( pcInputSample ); 353 // m_pcTopSample = pcInputSample; 354 // pcInputSample->cIter = m_acInputSamples.begin(); 355 // } 356 // else 357 // { 358 // std::vector <RendererInputSample*>::iterator cIter; 359 // 360 // for ( cIter = m_acInputSamples.begin( ) ; cIter != m_acInputSamples.end( ) ; cIter++ ) 361 // { 362 // if ( (*cIter)->m_uiPosX <= pcInputSample->m_uiPosX ) break; 363 // } 364 // 365 // m_acInputSamples.insert( cIter, 1, pcInputSample ); 366 // 367 // pcInputSample->cIter = cIter; 368 // 369 // if ( cIter == m_acInputSamples.begin() ) 370 // { 371 // m_pcTopSample = pcInputSample; 372 // } 373 // } 374 //} 375 // 376 //RendererOutputSample::RendererOutputSample() 377 //{ 378 // m_pcTopSample = 0; 379 //} 380 // 381 //Void RendererOutputSample::removeInputSample( RendererInputSample* pcInputSample ) 382 //{ 383 // m_acInputSamples.erase( pcInputSample->cIter ); 384 //} 385 // 112 #endif -
trunk/source/Lib/TLibCommon/TComMVDRefData.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 4 37 #define __TCOMMVDREFDATA__ 5 38 39 6 40 // Include files 41 7 42 #include "CommonDef.h" 8 43 #include "TComPicYuv.h" 9 44 #include <vector> 10 45 #if HHI_VSO 11 46 // ==================================================================================================================== 12 47 // Class definition … … 27 62 Int** m_aiBaseViewShiftLUT[3]; 28 63 29 30 //GT VSO31 64 //PicYuvs 32 65 std::vector<TComPicYuv*> m_apcExternalReferenceViews; … … 40 73 std::vector<Int> m_aiExtViewRefInd; 41 74 std::vector<Int> m_aiExtViewRefLUTInd; 42 43 //GT VSO end44 75 45 76 public: … … 64 95 // Void render( TComPicYuv* pOut ) /*Void render( TComPicYuv* pIn, TComPicYuv* pOut, TComPicYuv* pDepth, Long** aalLUT ) */; 65 96 66 //GT VSO 97 67 98 // PicYuvs 68 99 TComPicYuv* getPicYuvERView ( UInt uiReferenceNum ) { return m_apcExternalReferenceViews[uiReferenceNum]; }; … … 82 113 Void getRefPicYuvAndLUT ( TComPicYuv**& rpacDistRefPicList, Int***& rppalShiftLut); 83 114 Void getRefPicYuvAndLUTMode1( TComPicYuv**& rpacDistRefPicList, Int***& rppaiShiftLut ); 84 //GT VSO end85 115 86 116 }; // END CLASS DEFINITION TComMVDRefData 87 117 #endif // HHI_VSO 88 118 #endif // __TCOMMVDREFDATA__ 89 119 -
trunk/source/Lib/TLibCommon/TComMotionInfo.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComMotionInfo.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComMv.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 -
trunk/source/Lib/TLibCommon/TComPattern.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 91 124 Int iOffsetBottom, 92 125 UInt uiPartDepth, 93 UInt uiAbsPartIdx, 94 Bool bPrdDepthMap ) 126 UInt uiAbsPartIdx 127 #if DEPTH_MAP_GENERATION 128 ,Bool bPrdDepthMap 129 #endif 130 ) 95 131 { 96 132 m_iOffsetLeft = iOffsetLeft; … … 104 140 UInt uiAbsZorderIdx = pcCU->getZorderIdxInCU() + uiAbsPartIdx; 105 141 142 #if DEPTH_MAP_GENERATION 106 143 TComPicYuv* pcPic = ( bPrdDepthMap ? pcCU->getPic()->getPredDepthMap() : pcCU->getPic()->getPicYuvRec() ); 144 #else 145 TComPicYuv* pcPic = pcCU->getPic()->getPicYuvRec(); 146 #endif 107 147 if ( iComp == 0 ) 108 148 { … … 142 182 } 143 183 144 Void TComPattern::initPattern( TComDataCU* pcCU, UInt uiPartDepth, UInt uiAbsPartIdx, Bool bPrdDepthMap ) 184 Void TComPattern::initPattern( TComDataCU* pcCU, UInt uiPartDepth, UInt uiAbsPartIdx 185 #if DEPTH_MAP_GENERATION 186 , Bool bPrdDepthMap 187 #endif 188 ) 145 189 { 146 190 Int uiOffsetLeft = 0; … … 185 229 #endif 186 230 231 #if DEPTH_MAP_GENERATION 187 232 m_cPatternY .setPatternParamCU( pcCU, 0, uiWidth, uiHeight, uiOffsetLeft, uiOffsetRight, uiOffsetAbove, 0, uiPartDepth, uiAbsPartIdx, bPrdDepthMap ); 188 233 m_cPatternCb.setPatternParamCU( pcCU, 1, uiWidth >> 1, uiHeight >> 1, uiOffsetLeft, uiOffsetRight, uiOffsetAbove, 0, uiPartDepth, uiAbsPartIdx, bPrdDepthMap ); 189 234 m_cPatternCr.setPatternParamCU( pcCU, 2, uiWidth >> 1, uiHeight >> 1, uiOffsetLeft, uiOffsetRight, uiOffsetAbove, 0, uiPartDepth, uiAbsPartIdx, bPrdDepthMap ); 190 } 191 192 Void TComPattern::initAdiPattern( TComDataCU* pcCU, UInt uiZorderIdxInPart, UInt uiPartDepth, Int* piAdiBuf, Int iOrgBufStride, Int iOrgBufHeight, Bool& bAbove, Bool& bLeft, Bool bPrdDepthMap ) 235 #else 236 m_cPatternY .setPatternParamCU( pcCU, 0, uiWidth, uiHeight, uiOffsetLeft, uiOffsetRight, uiOffsetAbove, 0, uiPartDepth, uiAbsPartIdx ); 237 m_cPatternCb.setPatternParamCU( pcCU, 1, uiWidth >> 1, uiHeight >> 1, uiOffsetLeft, uiOffsetRight, uiOffsetAbove, 0, uiPartDepth, uiAbsPartIdx ); 238 m_cPatternCr.setPatternParamCU( pcCU, 2, uiWidth >> 1, uiHeight >> 1, uiOffsetLeft, uiOffsetRight, uiOffsetAbove, 0, uiPartDepth, uiAbsPartIdx ); 239 #endif 240 } 241 242 Void TComPattern::initAdiPattern( TComDataCU* pcCU, UInt uiZorderIdxInPart, UInt uiPartDepth, Int* piAdiBuf, Int iOrgBufStride, Int iOrgBufHeight, Bool& bAbove, Bool& bLeft 243 #if DEPTH_MAP_GENERATION 244 , Bool bPrdDepthMap 245 #endif 246 ) 193 247 { 194 248 Pel* piRoiOrigin; … … 330 384 piAdiTemp = piAdiBuf; 331 385 386 #if DEPTH_MAP_GENERATION 332 387 if( bPrdDepthMap ) 333 388 { … … 338 393 #endif 339 394 } 340 341 342 #if REFERENCE_SAMPLE_PADDING 395 #endif 396 397 398 #if REFERENCE_SAMPLE_PADDING 399 #if DEPTH_MAP_GENERATION 343 400 fillReferenceSamples ( pcCU, piRoiOrigin, piAdiTemp, bNeighborFlags, iNumIntraNeighbor, iUnitSize, iNumUnitsInCu, iTotalUnits, uiCuWidth, uiCuHeight, uiWidth, uiHeight, iPicStride, bPrdDepthMap ); 401 #else 402 fillReferenceSamples ( pcCU, piRoiOrigin, piAdiTemp, bNeighborFlags, iNumIntraNeighbor, iUnitSize, iNumUnitsInCu, iTotalUnits, uiCuWidth, uiCuHeight, uiWidth, uiHeight, iPicStride ); 403 #endif 344 404 delete [] bNeighborFlags; 345 405 bNeighborFlags = NULL; … … 586 646 587 647 #if REFERENCE_SAMPLE_PADDING 648 #if DEPTH_MAP_GENERATION 588 649 fillReferenceSamples ( pcCU, piRoiOrigin, piAdiTemp, bNeighborFlags, iNumIntraNeighbor, iUnitSize, iNumUnitsInCu, iTotalUnits, uiCuWidth, uiCuHeight, uiWidth, uiHeight, iPicStride, false ); 650 #else 651 fillReferenceSamples ( pcCU, piRoiOrigin, piAdiTemp, bNeighborFlags, iNumIntraNeighbor, iUnitSize, iNumUnitsInCu, iTotalUnits, uiCuWidth, uiCuHeight, uiWidth, uiHeight, iPicStride ); 652 #endif 589 653 #else // REFERENCE_SAMPLE_PADDING 590 654 for (i=0;i<uiWidth;i++) … … 648 712 649 713 #if REFERENCE_SAMPLE_PADDING 714 #if DEPTH_MAP_GENERATION 650 715 fillReferenceSamples ( pcCU, piRoiOrigin, piAdiTemp, bNeighborFlags, iNumIntraNeighbor, iUnitSize, iNumUnitsInCu, iTotalUnits, uiCuWidth, uiCuHeight, uiWidth, uiHeight, iPicStride, false ); 716 #else 717 fillReferenceSamples ( pcCU, piRoiOrigin, piAdiTemp, bNeighborFlags, iNumIntraNeighbor, iUnitSize, iNumUnitsInCu, iTotalUnits, uiCuWidth, uiCuHeight, uiWidth, uiHeight, iPicStride ); 718 #endif 651 719 delete [] bNeighborFlags; 652 720 bNeighborFlags = NULL; … … 709 777 710 778 #if REFERENCE_SAMPLE_PADDING 711 Void TComPattern::fillReferenceSamples( TComDataCU* pcCU, 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 bPrdDepthMap ) 779 Void TComPattern::fillReferenceSamples( TComDataCU* pcCU, Pel* piRoiOrigin, Int* piAdiTemp, Bool* bNeighborFlags, Int iNumIntraNeighbor, Int iUnitSize, Int iNumUnitsInCu, Int iTotalUnits, UInt uiCuWidth, UInt uiCuHeight, UInt uiWidth, UInt uiHeight, Int iPicStride 780 #if DEPTH_MAP_GENERATION 781 , Bool bPrdDepthMap 782 #endif 783 ) 712 784 { 713 785 Pel* piRoiTemp; 714 786 Int i, j; 787 #if DEPTH_MAP_GENERATION 715 788 Int iDCValue = ( bPrdDepthMap ? PDM_UNDEFINED_DEPTH : ( 1<<( g_uiBitDepth + g_uiBitIncrement - 1) ) ); 789 #else 790 Int iDCValue = ( 1<<( g_uiBitDepth + g_uiBitIncrement - 1) ); 791 #endif 716 792 717 793 if (iNumIntraNeighbor == 0) … … 885 961 886 962 #if QC_MDIS 887 #if HHI_DISABLE_INTRA_SMOOTHING_DEPTH888 Int* TComPattern::getPredictorPtr ( UInt uiDirMode, UInt uiWidthBits, Int iCuWidth, Int iCuHeight, Int* piAdiBuf, Bool bDepth )889 #else890 963 Int* TComPattern::getPredictorPtr ( UInt uiDirMode, UInt uiWidthBits, Int iCuWidth, Int iCuHeight, Int* piAdiBuf ) 891 #endif892 964 { 893 965 #if MN_MDIS_SIMPLIFICATION … … 919 991 mapPlanartoDC( uiDirMode ); 920 992 #endif 921 #if HHI_DISABLE_INTRA_SMOOTHING_DEPTH 922 UChar ucFiltIdx = 0; 923 if ( !bDepth ) 924 { 925 ucFiltIdx = g_aucIntraFilter[uiWidthBits][uiDirMode]; 926 } 927 #else 928 #if HHI_DMM_INTRA 993 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 929 994 UChar ucFiltIdx = 0; 930 995 if ( uiDirMode < 34 ) … … 934 999 #else 935 1000 UChar ucFiltIdx = g_aucIntraFilter[uiWidthBits][uiDirMode]; 936 #endif937 1001 #endif 938 1002 -
trunk/source/Lib/TLibCommon/TComPattern.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 62 95 Int iOffsetBottom, 63 96 UInt uiPartDepth, 64 UInt uiAbsZorderIdx, 65 Bool bPrdDepthMap = false ); 97 UInt uiAbsZorderIdx 98 #if DEPTH_MAP_GENERATION 99 ,Bool bPrdDepthMap = false 100 #endif 101 ); 66 102 }; 67 103 … … 101 137 102 138 #if QC_MDIS 103 #if HHI_DISABLE_INTRA_SMOOTHING_DEPTH104 Int* getPredictorPtr ( UInt uiDirMode, UInt uiWidthBits, Int iCuWidth, Int iCuHeight, Int* piAdiBuf, Bool bDepth = false );105 #else106 139 Int* getPredictorPtr ( UInt uiDirMode, UInt uiWidthBits, Int iCuWidth, Int iCuHeight, Int* piAdiBuf ); 107 #endif108 140 #endif //QC_MDIS 109 141 // ------------------------------------------------------------------------------------------------------------------- … … 126 158 Void initPattern ( TComDataCU* pcCU, 127 159 UInt uiPartDepth, 128 UInt uiAbsPartIdx, 129 Bool bPrdDepthMap = false ); 160 UInt uiAbsPartIdx 161 #if DEPTH_MAP_GENERATION 162 ,Bool bPrdDepthMap = false 163 #endif 164 ); 130 165 131 166 /// set luma parameters from CU data for accessing ADI data … … 137 172 Int iOrgBufHeight, 138 173 Bool& bAbove, 139 Bool& bLeft, 140 Bool bPrdDepthMap = false ); 174 Bool& bLeft 175 #if DEPTH_MAP_GENERATION 176 ,Bool bPrdDepthMap = false 177 #endif 178 ); 141 179 142 180 /// set chroma parameters from CU data for accessing ADI data … … 160 198 #if REFERENCE_SAMPLE_PADDING 161 199 /// padding of unavailable reference samples for intra prediction 162 Void fillReferenceSamples ( TComDataCU* pcCU, 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 bPrdDepthMap ); 200 Void fillReferenceSamples ( TComDataCU* pcCU, Pel* piRoiOrigin, Int* piAdiTemp, Bool* bNeighborFlags, Int iNumIntraNeighbor, Int iUnitSize, Int iNumUnitsInCu, Int iTotalUnits, UInt uiCuWidth, UInt uiCuHeight, UInt uiWidth, UInt uiHeight, Int iPicStride 201 #if DEPTH_MAP_GENERATION 202 , Bool bPrdDepthMap 203 #endif 204 ); 163 205 #endif 164 206 #if CONSTRAINED_INTRA_PRED -
trunk/source/Lib/TLibCommon/TComPic.cpp
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 17 50 m_apcPicYuv[0] = NULL; 18 51 m_apcPicYuv[1] = NULL; 52 #if DEPTH_MAP_GENERATION 19 53 m_pcPredDepthMap = NULL; 54 #endif 55 #if HHI_INTER_VIEW_MOTION_PRED 20 56 m_pcOrgDepthMap = NULL; 57 #endif 58 #if HHI_INTER_VIEW_RESIDUAL_PRED 21 59 m_pcResidual = NULL; 60 #endif 22 61 m_pcPicYuvPred = NULL; 23 62 m_pcPicYuvResi = NULL; 63 #if HHI_INTERVIEW_SKIP 24 64 m_pcUsedPelsMap = NULL; 65 #endif 25 66 26 67 #if PARALLEL_MERGED_DEBLK … … 76 117 } 77 118 119 #if DEPTH_MAP_GENERATION 78 120 if( m_pcPredDepthMap ) 79 121 { … … 82 124 m_pcPredDepthMap = NULL; 83 125 } 84 126 #endif 127 128 #if HHI_INTER_VIEW_MOTION_PRED 85 129 if( m_pcOrgDepthMap ) 86 130 { … … 89 133 m_pcOrgDepthMap = NULL; 90 134 } 91 135 #endif 136 137 #if HHI_INTER_VIEW_RESIDUAL_PRED 92 138 if( m_pcResidual ) 93 139 { … … 96 142 m_pcResidual = NULL; 97 143 } 98 144 #endif 145 146 #if HHI_INTERVIEW_SKIP 99 147 if( m_pcUsedPelsMap ) 100 148 { … … 103 151 m_pcUsedPelsMap = NULL; 104 152 } 153 #endif 105 154 106 155 #if PARALLEL_MERGED_DEBLK … … 160 209 #endif 161 210 211 #if DEPTH_MAP_GENERATION 162 212 Void 163 213 TComPic::addPrdDepthMapBuffer() … … 173 223 m_pcPredDepthMap ->create( iWidth, iHeight, uiMaxCuWidth, uiMaxCuHeight, uiMaxCuDepth ); 174 224 } 175 225 #endif 226 227 #if HHI_INTER_VIEW_MOTION_PRED 176 228 Void 177 229 TComPic::addOrgDepthMapBuffer() … … 187 239 m_pcOrgDepthMap ->create( iWidth, iHeight, uiMaxCuWidth, uiMaxCuHeight, uiMaxCuDepth ); 188 240 } 189 241 #endif 242 243 #if HHI_INTER_VIEW_RESIDUAL_PRED 190 244 Void 191 245 TComPic::addResidualBuffer() … … 201 255 m_pcResidual ->create( iWidth, iHeight, uiMaxCuWidth, uiMaxCuHeight, uiMaxCuDepth ); 202 256 } 203 257 #endif 258 259 #if HHI_INTERVIEW_SKIP 204 260 Void 205 261 TComPic::addUsedPelsMapBuffer() … … 215 271 m_pcUsedPelsMap ->create( iWidth, iHeight, uiMaxCuWidth, uiMaxCuHeight, uiMaxCuDepth ); 216 272 } 273 #endif 217 274 218 275 Void … … 240 297 #endif 241 298 299 #if DEPTH_MAP_GENERATION 242 300 Void 243 301 TComPic::removePrdDepthMapBuffer() … … 250 308 } 251 309 } 252 310 #endif 311 312 #if HHI_INTER_VIEW_MOTION_PRED 253 313 Void 254 314 TComPic::removeOrgDepthMapBuffer() … … 261 321 } 262 322 } 263 323 #endif 324 325 #if HHI_INTER_VIEW_RESIDUAL_PRED 264 326 Void 265 327 TComPic::removeResidualBuffer() … … 272 334 } 273 335 } 274 336 #endif 337 338 #if HHI_INTERVIEW_SKIP 275 339 Void 276 340 TComPic::removeUsedPelsMapBuffer() … … 283 347 } 284 348 } 285 349 #endif 350 -
trunk/source/Lib/TLibCommon/TComPic.h
r2 r5 1 /* The copyright in this software is being made available under the BSD 2 * License, included below. This software may be subject to other third party 3 * and contributor rights, including patent rights, and no such rights are 4 * granted under this license. 5 * 6 * Copyright (c) 2010-2011, ISO/IEC 7 * All rights reserved. 8 * 9 * Redistribution and use in source and binary forms, with or without 10 * modification, are permitted provided that the following conditions are met: 11 * 12 * * Redistributions of source code must retain the above copyright notice, 13 * this list of conditions and the following disclaimer. 14 * * Redistributions in binary form must reproduce the above copyright notice, 15 * this list of conditions and the following disclaimer in the documentation 16 * and/or other materials provided with the distribution. 17 * * Neither the name of the ISO/IEC nor the names of its contributors may 18 * be used to endorse or promote products derived from this software without 19 * specific prior written permission. 20 * 21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS 25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 31 * THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 1 34 2 35 … … 26 59 private: 27 60 TComPicSym* m_apcPicSym; // Symbol 28 61 29 62 TComPicYuv* m_apcPicYuv[2]; // Texture, 0:org / 1:rec 63 #if DEPTH_MAP_GENERATION 30 64 TComPicYuv* m_pcPredDepthMap; // estimated depth map 65 #endif 66 #if HHI_INTER_VIEW_MOTION_PRED 31 67 TComPicYuv* m_pcOrgDepthMap; // original depth map 68 #endif 69 #if HHI_INTER_VIEW_RESIDUAL_PRED 32 70 TComPicYuv* m_pcResidual; // residual buffer (coded or inter-view predicted residual) 33 71 #endif 72 34 73 TComPicYuv* m_pcPicYuvPred; // Prediction 35 74 TComPicYuv* m_pcPicYuvResi; // Residual … … 39 78 Bool m_bReconstructed; 40 79 UInt m_uiCurrSliceIdx; // Index of current slice 41 80 42 81 SEImessages* m_SEIs; ///< Any SEI messages that have been received. If !NULL we own the object. 43 82