Ignore:
Timestamp:
23 May 2013, 15:40:36 (12 years ago)
Author:
tech
Message:

Integrated 3D encoder control, camera parameters, renderer and MV fixes.

Location:
branches/HTM-DEV-0.2-dev/source/App/TAppEncoder
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-DEV-0.2-dev/source/App/TAppEncoder/TAppEncCfg.cpp

    r368 r438  
    7979  m_aidQP = NULL;
    8080#endif
    81 #if J0149_TONE_MAPPING_SEI
    82   m_startOfCodedInterval = NULL;
    83   m_codedPivotValue = NULL;
    84   m_targetPivotValue = NULL;
    85 #endif
    8681}
    8782
     
    107102    delete[] m_aidQP;
    108103  }
    109 #endif
    110 #if J0149_TONE_MAPPING_SEI
    111   if ( m_startOfCodedInterval )
    112   {
    113     delete[] m_startOfCodedInterval;
    114     m_startOfCodedInterval = NULL;
    115   }
    116    if ( m_codedPivotValue )
    117   {
    118     delete[] m_codedPivotValue;
    119     m_codedPivotValue = NULL;
    120   }
    121   if ( m_targetPivotValue )
    122   {
    123     delete[] m_targetPivotValue;
    124     m_targetPivotValue = NULL;
    125   }
    126 #endif
    127 #if !H_MV
    128104  free(m_pchInputFile);
    129105#endif
     106
    130107  free(m_pchBitstreamFile);
     108
    131109#if H_MV
    132110  for(Int i = 0; i< m_pchReconFileList.size(); i++ )
     
    138116  free(m_pchReconFile);
    139117#endif
     118
    140119  free(m_pchdQPFile);
    141120  free(m_pColumnWidth);
    142121  free(m_pRowHeight);
    143122  free(m_scalingListFile);
     123
    144124#if H_MV
    145125  for( Int i = 0; i < m_GOPListMvc.size(); i++ )
     
    320300  string cfg_InputFile;
    321301#endif
     302
    322303  string cfg_BitstreamFile;
     304
    323305#if !H_MV
    324306  string cfg_ReconFile;
    325307#endif
     308
    326309#if H_MV
    327310  vector<Int>   cfg_dimensionLength;
     
    333316#endif
    334317#endif
     318
    335319  string cfg_dQPFile;
    336320  string cfg_ColumnWidth;
    337321  string cfg_RowHeight;
    338322  string cfg_ScalingListFile;
    339 #if J0149_TONE_MAPPING_SEI
    340   string cfg_startOfCodedInterval;
    341   string cfg_codedPivotValue;
    342   string cfg_targetPivotValue;
    343 #endif
    344323#if SIGNAL_BITRATE_PICRATE_IN_VPS
    345324  string cfg_bitRateInfoPresentFlag;
     
    356335 
    357336  // File, I/O and source parameters
     337
    358338#if H_MV
    359339  ("InputFile_%d,i_%d",       m_pchInputFileList,       (char *) 0 , MAX_NUM_LAYER_IDS , "original Yuv input file name %d")
     
    361341  ("InputFile,i",           cfg_InputFile,     string(""), "Original YUV input file name")
    362342#endif
     343
    363344  ("BitstreamFile,b",       cfg_BitstreamFile, string(""), "Bitstream output file name")
     345
    364346#if H_MV
    365347  ("ReconFile_%d,o_%d",       m_pchReconFileList,       (char *) 0 , MAX_NUM_LAYER_IDS , "reconstructed Yuv output file name %d")
     
    367349  ("ReconFile,o",           cfg_ReconFile,     string(""), "Reconstructed YUV output file name")
    368350#endif
     351
    369352#if H_MV
    370353  ("NumberOfLayers",        m_numberOfLayers     , 1,                     "Number of layers")
     
    382365  ("SplittingFlag",         m_splittingFlag      , false                , "Splitting Flag")   
    383366#endif
     367
    384368  ("SourceWidth,-wdt",      m_iSourceWidth,        0, "Source picture width")
    385369  ("SourceHeight,-hgt",     m_iSourceHeight,       0, "Source picture height")
     
    403387
    404388  // Profile and level
     389
    405390  ("Profile", m_profile,   Profile::NONE, "Profile to be used when encoding (Incomplete)")
    406391  ("Level",   m_level,     Level::NONE,   "Level limit to be used, eg 5.1 (Incomplete)")
     
    432417  ("DecodingRefreshType,-dr", m_iDecodingRefreshType,       0, "Intra refresh type (0:none 1:CRA 2:IDR)")
    433418  ("GOPSize,g",               m_iGOPSize,                   1, "GOP size of temporal structure")
    434 #if !L0034_COMBINED_LIST_CLEANUP
    435419  ("ListCombination,-lc",     m_bUseLComb,               true, "Combined reference list for uni-prediction estimation in B-slices")
    436 #endif
    437420  // motion options
    438421  ("FastSearch",              m_iFastSearch,                1, "0:Full search  1:Diamond  2:PMVFAST")
     
    490473  ("LoopFilterTcOffset_div2",        m_loopFilterTcOffsetDiv2,             0 )
    491474  ("DeblockingFilterControlPresent", m_DeblockingFilterControlPresent, false )
    492 #if L0386_DB_METRIC
    493   ("DeblockingFilterMetric",         m_DeblockingFilterMetric,         false )
    494 #endif
    495475
    496476  // Coding tools
     
    611591  ("SEIBufferingPeriod",             m_bufferingPeriodSEIEnabled,              0, "Control generation of buffering period SEI messages")
    612592  ("SEIPictureTiming",               m_pictureTimingSEIEnabled,                0, "Control generation of picture timing SEI messages")
    613 #if J0149_TONE_MAPPING_SEI
    614   ("SEIToneMappingInfo",                       m_toneMappingInfoSEIEnabled,    false, "Control generation of Tone Mapping SEI messages")
    615   ("SEIToneMapId",                             m_toneMapId,                        0, "Specifies Id of Tone Mapping SEI message for a given session")
    616   ("SEIToneMapCancelFlag",                     m_toneMapCancelFlag,            false, "Indicates that Tone Mapping SEI message cancels the persistance or follows")
    617   ("SEIToneMapPersistenceFlag",                m_toneMapPersistenceFlag,        true, "Specifies the persistence of the Tone Mapping SEI message")
    618   ("SEIToneMapCodedDataBitDepth",              m_toneMapCodedDataBitDepth,         8, "Specifies Coded Data BitDepth of Tone Mapping SEI messages")
    619   ("SEIToneMapTargetBitDepth",                 m_toneMapTargetBitDepth,            8, "Specifies Output BitDepth of Tome mapping function")
    620   ("SEIToneMapModelId",                        m_toneMapModelId,                   0, "Specifies Model utilized for mapping coded data into target_bit_depth range\n"
    621                                                                                       "\t0:  linear mapping with clipping\n"
    622                                                                                       "\t1:  sigmoidal mapping\n"
    623                                                                                       "\t2:  user-defined table mapping\n"
    624                                                                                       "\t3:  piece-wise linear mapping\n"
    625                                                                                       "\t4:  luminance dynamic range information ")
    626   ("SEIToneMapMinValue",                              m_toneMapMinValue,                          0, "Specifies the minimum value in mode 0")
    627   ("SEIToneMapMaxValue",                              m_toneMapMaxValue,                       1023, "Specifies the maxmum value in mode 0")
    628   ("SEIToneMapSigmoidMidpoint",                       m_sigmoidMidpoint,                        512, "Specifies the centre point in mode 1")
    629   ("SEIToneMapSigmoidWidth",                          m_sigmoidWidth,                           960, "Specifies the distance between 5% and 95% values of the target_bit_depth in mode 1")
    630   ("SEIToneMapStartOfCodedInterval",                  cfg_startOfCodedInterval,          string(""), "Array of user-defined mapping table")
    631   ("SEIToneMapNumPivots",                             m_numPivots,                                0, "Specifies the number of pivot points in mode 3")
    632   ("SEIToneMapCodedPivotValue",                       cfg_codedPivotValue,               string(""), "Array of pivot point")
    633   ("SEIToneMapTargetPivotValue",                      cfg_targetPivotValue,              string(""), "Array of pivot point")
    634   ("SEIToneMapCameraIsoSpeedIdc",                     m_cameraIsoSpeedIdc,                        0, "Indicates the camera ISO speed for daylight illumination")
    635   ("SEIToneMapCameraIsoSpeedValue",                   m_cameraIsoSpeedValue,                    400, "Specifies the camera ISO speed for daylight illumination of Extended_ISO")
    636   ("SEIToneMapExposureCompensationValueSignFlag",     m_exposureCompensationValueSignFlag,        0, "Specifies the sign of ExposureCompensationValue")
    637   ("SEIToneMapExposureCompensationValueNumerator",    m_exposureCompensationValueNumerator,       0, "Specifies the numerator of ExposureCompensationValue")
    638   ("SEIToneMapExposureCompensationValueDenomIdc",     m_exposureCompensationValueDenomIdc,        2, "Specifies the denominator of ExposureCompensationValue")
    639   ("SEIToneMapRefScreenLuminanceWhite",               m_refScreenLuminanceWhite,                350, "Specifies reference screen brightness setting in units of candela per square metre")
    640   ("SEIToneMapExtendedRangeWhiteLevel",               m_extendedRangeWhiteLevel,                800, "Indicates the luminance dynamic range")
    641   ("SEIToneMapNominalBlackLevelLumaCodeValue",        m_nominalBlackLevelLumaCodeValue,          16, "Specifies luma sample value of the nominal black level assigned decoded pictures")
    642   ("SEIToneMapNominalWhiteLevelLumaCodeValue",        m_nominalWhiteLevelLumaCodeValue,         235, "Specifies luma sample value of the nominal white level assigned decoded pictures")
    643   ("SEIToneMapExtendedWhiteLevelLumaCodeValue",       m_extendedWhiteLevelLumaCodeValue,        300, "Specifies luma sample value of the extended dynamic range assigned decoded pictures")
    644 #endif
    645593  ("SEIFramePacking",                m_framePackingSEIEnabled,                 0, "Control generation of frame packing SEI messages")
    646594  ("SEIFramePackingType",            m_framePackingSEIType,                    0, "Define frame packing arrangement\n"
     
    663611  ("SEIGradualDecodingRefreshInfo",  m_gradualDecodingRefreshInfoEnabled,      0, "Control generation of gradual decoding refresh information SEI message")
    664612  ("SEIDecodingUnitInfo",             m_decodingUnitInfoSEIEnabled,                       0, "Control generation of decoding unit information SEI message.")
    665 #if L0208_SOP_DESCRIPTION_SEI
    666   ("SEISOPDescription",              m_SOPDescriptionSEIEnabled,              0, "Control generation of SOP description SEI messages")
    667 #endif
    668 #if K0180_SCALABLE_NESTING_SEI
    669   ("SEIScalableNesting",             m_scalableNestingSEIEnabled,              0, "Control generation of scalable nesting SEI messages")
    670 #endif
    671613#if SIGNAL_BITRATE_PICRATE_IN_VPS
    672614  ("BitRatePicRateMaxTLayers",   m_bitRatePicRateMaxTLayers,           0, "Maximum number of sub-layers signalled; can be inferred otherwise; here for easy parsing of config. file")
     
    719661  }
    720662#endif
     663
    721664  po::setDefaults(opts);
    722665  const list<const Char*>& argv_unhandled = po::scanArgv(opts, argc, (const Char**) argv);
     
    738681   */
    739682  /* convert std::string to c string for compatability */
     683
    740684#if !H_MV
    741685  m_pchInputFile = cfg_InputFile.empty() ? NULL : strdup(cfg_InputFile.c_str());
    742686#endif
     687
    743688  m_pchBitstreamFile = cfg_BitstreamFile.empty() ? NULL : strdup(cfg_BitstreamFile.c_str());
     689
    744690#if !H_MV
    745691  m_pchReconFile = cfg_ReconFile.empty() ? NULL : strdup(cfg_ReconFile.c_str());
    746692#endif
     693
    747694  m_pchdQPFile = cfg_dQPFile.empty() ? NULL : strdup(cfg_dQPFile.c_str());
    748695 
     
    808755  free ( pRowHeight   );
    809756#endif
     757
    810758#if SIGNAL_BITRATE_PICRATE_IN_VPS
    811759  readBoolString(cfg_bitRateInfoPresentFlag, m_bitRatePicRateMaxTLayers, m_bitRateInfoPresentFlag, "bit rate info. present flag" );
     
    966914  m_iWaveFrontSubstreams = m_iWaveFrontSynchro ? (m_iSourceHeight + m_uiMaxCUHeight - 1) / m_uiMaxCUHeight : 1;
    967915
    968 #if J0149_TONE_MAPPING_SEI
    969   if( m_toneMappingInfoSEIEnabled && !m_toneMapCancelFlag )
    970   {
    971     Char* pcStartOfCodedInterval = cfg_startOfCodedInterval.empty() ? NULL: strdup(cfg_startOfCodedInterval.c_str());
    972     Char* pcCodedPivotValue = cfg_codedPivotValue.empty() ? NULL: strdup(cfg_codedPivotValue.c_str());
    973     Char* pcTargetPivotValue = cfg_targetPivotValue.empty() ? NULL: strdup(cfg_targetPivotValue.c_str());
    974     if( m_toneMapModelId == 2 && pcStartOfCodedInterval )
    975     {
    976       char *startOfCodedInterval;
    977       UInt num = 1u<< m_toneMapTargetBitDepth;
    978       m_startOfCodedInterval = new Int[num];
    979       ::memset( m_startOfCodedInterval, 0, sizeof(Int)*num );
    980       startOfCodedInterval = strtok(pcStartOfCodedInterval, " .");
    981       int i = 0;
    982       while( startOfCodedInterval && ( i < num ) )
    983       {
    984         m_startOfCodedInterval[i] = atoi( startOfCodedInterval );
    985         startOfCodedInterval = strtok(NULL, " .");
    986         i++;
    987       }
    988     }
    989     else
    990     {
    991       m_startOfCodedInterval = NULL;
    992     }
    993     if( ( m_toneMapModelId == 3 ) && ( m_numPivots > 0 ) )
    994     {
    995       if( pcCodedPivotValue && pcTargetPivotValue )
    996       {
    997         char *codedPivotValue;
    998         char *targetPivotValue;
    999         m_codedPivotValue = new Int[m_numPivots];
    1000         m_targetPivotValue = new Int[m_numPivots];
    1001         ::memset( m_codedPivotValue, 0, sizeof(Int)*( m_numPivots ) );
    1002         ::memset( m_targetPivotValue, 0, sizeof(Int)*( m_numPivots ) );
    1003         codedPivotValue = strtok(pcCodedPivotValue, " .");
    1004         int i=0;
    1005         while(codedPivotValue&&i<m_numPivots)
    1006         {
    1007           m_codedPivotValue[i] = atoi( codedPivotValue );
    1008           codedPivotValue = strtok(NULL, " .");
    1009           i++;
    1010         }
    1011         i=0;
    1012         targetPivotValue = strtok(pcTargetPivotValue, " .");
    1013         while(targetPivotValue&&i<m_numPivots)
    1014         {
    1015           m_targetPivotValue[i]= atoi( targetPivotValue );
    1016           targetPivotValue = strtok(NULL, " .");
    1017           i++;
    1018         }
    1019       }
    1020     }
    1021     else
    1022     {
    1023       m_codedPivotValue = NULL;
    1024       m_targetPivotValue = NULL;
    1025     }
    1026   }
    1027 #endif
    1028916  // check validity of input parameters
    1029917  xCheckParameter();
     
    11251013  xConfirmPara( m_iFrameRate <= 0,                                                          "Frame rate must be more than 1" );
    11261014  xConfirmPara( m_framesToBeEncoded <= 0,                                                   "Total Number Of Frames encoded must be more than 0" );
     1015
    11271016#if H_MV
    11281017  xConfirmPara( m_numberOfLayers > MAX_NUM_LAYER_IDS ,                                      "NumberOfLayers must be less than or equal to MAX_NUM_LAYER_IDS");
     
    11371026  xConfirmPara( m_scalabilityMask != 1 , "Scalability Mask must be equal to 1. ");
    11381027#endif
    1139  
     1028  
    11401029  m_dimIds.push_back( m_viewId );
    11411030#if H_3D
     
    11941083
    11951084#endif
     1085
     1086
    11961087  xConfirmPara( m_iGOPSize < 1 ,                                                            "GOP Size must be greater or equal to 1" );
    11971088  xConfirmPara( m_iGOPSize > 1 &&  m_iGOPSize % 2,                                          "GOP Size must be a multiple of 2, if GOP Size is greater than 1" );
     
    14571348      Int*      m_numReorderPics     = m_numReorderPicsMvc    [layer]; // It is not a member, but this name helps avoiding code duplication !!!
    14581349#endif
     1350
    14591351  /* if this is an intra-only sequence, ie IntraPeriod=1, don't verify the GOP structure
    14601352   * This permits the ability to omit a GOP structure specification */
     
    17171609  {
    17181610    m_numReorderPics[i] = 0;
    1719 #if L0323_DPB
    1720     m_maxDecPicBuffering[i] = 1;
    1721 #else
    17221611    m_maxDecPicBuffering[i] = 0;
    1723 #endif
    17241612  }
    17251613  for(Int i=0; i<m_iGOPSize; i++)
    17261614  {
    1727 #if L0323_DPB
    1728     if(m_GOPList[i].m_numRefPics+1 > m_maxDecPicBuffering[m_GOPList[i].m_temporalId])
    1729 #else
    17301615    if(m_GOPList[i].m_numRefPics > m_maxDecPicBuffering[m_GOPList[i].m_temporalId])
    1731 #endif
    1732     {
    1733 #if L0323_DPB
    1734       m_maxDecPicBuffering[m_GOPList[i].m_temporalId] = m_GOPList[i].m_numRefPics + 1;
    1735 #else
     1616    {
    17361617      m_maxDecPicBuffering[m_GOPList[i].m_temporalId] = m_GOPList[i].m_numRefPics;
    1737 #endif
    17381618    }
    17391619    Int highestDecodingNumberWithLowerPOC = 0;
     
    17661646      m_numReorderPics[i+1] = m_numReorderPics[i];
    17671647    }
    1768 #if L0323_DPB
    1769     // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ] - 1, inclusive
    1770     if(m_numReorderPics[i] > m_maxDecPicBuffering[i] - 1)
    1771     {
    1772       m_maxDecPicBuffering[i] = m_numReorderPics[i] + 1;
    1773     }
    1774 #else
    17751648    // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ], inclusive
    17761649    if(m_numReorderPics[i] > m_maxDecPicBuffering[i])
     
    17781651      m_maxDecPicBuffering[i] = m_numReorderPics[i];
    17791652    }
    1780 #endif
    17811653    // a lower layer can not have higher value of m_uiMaxDecPicBuffering than a higher layer
    17821654    if(m_maxDecPicBuffering[i+1] < m_maxDecPicBuffering[i])
     
    17851657    }
    17861658  }
    1787 
    1788 
    1789 #if L0323_DPB
    1790   // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ] -  1, inclusive
    1791   if(m_numReorderPics[MAX_TLAYER-1] > m_maxDecPicBuffering[MAX_TLAYER-1] - 1)
    1792   {
    1793     m_maxDecPicBuffering[MAX_TLAYER-1] = m_numReorderPics[MAX_TLAYER-1] + 1;
    1794   }
    1795 #else
    17961659  // the value of num_reorder_pics[ i ] shall be in the range of 0 to max_dec_pic_buffering[ i ], inclusive
    17971660  if(m_numReorderPics[MAX_TLAYER-1] > m_maxDecPicBuffering[MAX_TLAYER-1])
     
    17991662    m_maxDecPicBuffering[MAX_TLAYER-1] = m_numReorderPics[MAX_TLAYER-1];
    18001663  }
    1801 #endif
    18021664
    18031665  if(m_vuiParametersPresentFlag && m_bitstreamRestrictionFlag)
     
    18741736    }
    18751737  }
    1876 #if !L0034_COMBINED_LIST_CLEANUP
    18771738  xConfirmPara( m_bUseLComb==false && m_numReorderPics[MAX_TLAYER-1]!=0, "ListCombination can only be 0 in low delay coding (more precisely when L0 and L1 are identical)" );  // Note however this is not the full necessary condition as ref_pic_list_combination_flag can only be 0 if L0 == L1.
    1878 #endif
    18791739  xConfirmPara( m_iWaveFrontSynchro < 0, "WaveFrontSynchro cannot be negative" );
    18801740  xConfirmPara( m_iWaveFrontSubstreams <= 0, "WaveFrontSubstreams must be positive" );
     
    18831743  xConfirmPara( m_decodedPictureHashSEIEnabled<0 || m_decodedPictureHashSEIEnabled>3, "this hash type is not correct!\n");
    18841744
    1885 #if J0149_TONE_MAPPING_SEI
    1886   if (m_toneMappingInfoSEIEnabled)
    1887   {
    1888     xConfirmPara( m_toneMapCodedDataBitDepth < 8 || m_toneMapCodedDataBitDepth > 14 , "SEIToneMapCodedDataBitDepth must be in rage 8 to 14");
    1889     xConfirmPara( m_toneMapTargetBitDepth < 1 || (m_toneMapTargetBitDepth > 16 && m_toneMapTargetBitDepth < 255) , "SEIToneMapTargetBitDepth must be in rage 1 to 16 or equal to 255");
    1890     xConfirmPara( m_toneMapModelId < 0 || m_toneMapModelId > 4 , "SEIToneMapModelId must be in rage 0 to 4");
    1891     xConfirmPara( m_cameraIsoSpeedValue == 0, "SEIToneMapCameraIsoSpeedValue shall not be equal to 0");
    1892     xConfirmPara( m_extendedRangeWhiteLevel < 100, "SEIToneMapExtendedRangeWhiteLevel should be greater than or equal to 100");
    1893     xConfirmPara( m_nominalBlackLevelLumaCodeValue >= m_nominalWhiteLevelLumaCodeValue, "SEIToneMapNominalWhiteLevelLumaCodeValue shall be greater than SEIToneMapNominalBlackLevelLumaCodeValue");
    1894     xConfirmPara( m_extendedWhiteLevelLumaCodeValue < m_nominalWhiteLevelLumaCodeValue, "SEIToneMapExtendedWhiteLevelLumaCodeValue shall be greater than or equal to SEIToneMapNominalWhiteLevelLumaCodeValue");
    1895   }
    1896 #endif
    1897 
    18981745#if RATE_CONTROL_LAMBDA_DOMAIN
    18991746  if ( m_RCEnableRateControl )
     
    19321779  }
    19331780#endif
     1781
    19341782#if H_MV
    19351783  }
     
    19791827  printf("Input          File          : %s\n", m_pchInputFile          );
    19801828#endif
     1829
    19811830  printf("Bitstream      File          : %s\n", m_pchBitstreamFile      );
     1831
    19821832#if H_MV
    19831833  for( Int layer = 0; layer < m_numberOfLayers; layer++)
     
    19881838  printf("Reconstruction File          : %s\n", m_pchReconFile          );
    19891839#endif
     1840
    19901841#if H_MV
    19911842 xPrintParaVector( "ViewId", m_viewId );
    19921843#endif
     1844
    19931845#if H_3D
    19941846 xPrintParaVector( "DepthFlag", m_depthFlag );
    19951847#endif
     1848
    19961849#if H_MV 
    19971850  xPrintParaVector( "QP"               , m_fQP                );
     
    20551908  printf("SQP:%d ", m_uiDeltaQpRD         );
    20561909  printf("ASR:%d ", m_bUseASR             );
    2057 #if !L0034_COMBINED_LIST_CLEANUP
    20581910  printf("LComb:%d ", m_bUseLComb         );
    2059 #endif
    20601911  printf("FEN:%d ", m_bUseFastEnc         );
    20611912  printf("ECU:%d ", m_bUseEarlyCU         );
  • branches/HTM-DEV-0.2-dev/source/App/TAppEncoder/TAppEncCfg.h

    r368 r438  
    6060  Char*     m_pchInputFile;                                   ///< source file name
    6161#endif
     62
    6263  Char*     m_pchBitstreamFile;                               ///< output bitstream file
     64
    6365#if H_MV
    6466  std::vector<char*>     m_pchReconFileList;                  ///< output reconstruction file names
     
    6769  Char*     m_pchReconFile;                                   ///< output reconstruction file
    6870#endif
     71
     72
    6973  // VPS specification
    7074#if H_MV
     
    7983  std::vector<Int>       m_dimensionIdLen;                   ///< Length of scalability dimension s
    8084#endif
     85
     86
    8187  Double    m_adLambdaModifier[ MAX_TLAYER ];                 ///< Lambda modifier array for each temporal layer
    8288  // source specification
     
    97103  Level::Tier   m_levelTier;
    98104  Level::Name   m_level;
     105
    99106#if L0046_CONSTRAINT_FLAGS
    100107  Bool m_progressiveSourceFlag;
     
    117124  GOPEntry  m_GOPList[MAX_GOP];                               ///< the coding structure entries from the config file
    118125  Int       m_numReorderPics[MAX_TLAYER];                     ///< total number of reorder pictures
    119 #if L0323_DPB
    120   Int       m_maxDecPicBuffering[MAX_TLAYER];                 ///< total number of pictures in the decoded picture buffer
    121 #else
    122126  Int       m_maxDecPicBuffering[MAX_TLAYER];                 ///< total number of reference pictures needed for decoding
    123127#endif
    124 #endif
    125 #if !L0034_COMBINED_LIST_CLEANUP
    126128  Bool      m_bUseLComb;                                      ///< flag for using combined reference list for uni-prediction in B-slices (JCTVC-D421)
    127 #endif
    128129  Bool      m_useTransformSkip;                               ///< flag for enabling intra transform skipping
    129130  Bool      m_useTransformSkipFast;                           ///< flag for enabling fast intra transform skipping
     
    206207  Int       m_loopFilterTcOffsetDiv2;                       ///< tc offset for deblocking filter
    207208  Bool      m_DeblockingFilterControlPresent;                 ///< deblocking filter control present flag in PPS
    208 #if L0386_DB_METRIC
    209   Bool      m_DeblockingFilterMetric;                         ///< blockiness metric in encoder
    210 #endif
    211209 
    212210  // coding tools (PCM)
     
    258256  Int       m_bufferingPeriodSEIEnabled;
    259257  Int       m_pictureTimingSEIEnabled;
    260 #if J0149_TONE_MAPPING_SEI
    261   Bool      m_toneMappingInfoSEIEnabled;
    262   Int       m_toneMapId;
    263   Bool      m_toneMapCancelFlag;
    264   Bool      m_toneMapPersistenceFlag;
    265   Int       m_toneMapCodedDataBitDepth;
    266   Int       m_toneMapTargetBitDepth;
    267   Int       m_toneMapModelId;
    268   Int       m_toneMapMinValue;
    269   Int       m_toneMapMaxValue;
    270   Int       m_sigmoidMidpoint;
    271   Int       m_sigmoidWidth;
    272   Int       m_numPivots;
    273   Int       m_cameraIsoSpeedIdc;
    274   Int       m_cameraIsoSpeedValue;
    275   Int       m_exposureCompensationValueSignFlag;
    276   Int       m_exposureCompensationValueNumerator;
    277   Int       m_exposureCompensationValueDenomIdc;
    278   Int       m_refScreenLuminanceWhite;
    279   Int       m_extendedRangeWhiteLevel;
    280   Int       m_nominalBlackLevelLumaCodeValue;
    281   Int       m_nominalWhiteLevelLumaCodeValue;
    282   Int       m_extendedWhiteLevelLumaCodeValue;
    283   Int*      m_startOfCodedInterval;
    284   Int*      m_codedPivotValue;
    285   Int*      m_targetPivotValue;
    286 #endif
    287258  Int       m_framePackingSEIEnabled;
    288259  Int       m_framePackingSEIType;
     
    294265  Int       m_gradualDecodingRefreshInfoEnabled;
    295266  Int       m_decodingUnitInfoSEIEnabled;
    296 #if L0208_SOP_DESCRIPTION_SEI
    297   Int       m_SOPDescriptionSEIEnabled;
    298 #endif
    299 #if K0180_SCALABLE_NESTING_SEI
    300   Int       m_scalableNestingSEIEnabled;
    301 #endif
    302267  // weighted prediction
    303268  Bool      m_useWeightedPred;                    ///< Use of weighted prediction in P slices
     
    372337  Void  xPrintParameter ();                                   ///< print configuration values
    373338  Void  xPrintUsage     ();                                   ///< print usage
     339
    374340#if H_MV
    375341  template <typename T>
     
    422388  Int*      m_constantPicRateIdc;                                ///< Indicates constant picture rate idc for various sub-layers
    423389#endif
     390 
    424391#if H_MV
    425392  Int   getGOPSize() { return m_iGOPSize; }
    426393#endif
     394
    427395public:
    428396  TAppEncCfg();
  • branches/HTM-DEV-0.2-dev/source/App/TAppEncoder/TAppEncTop.cpp

    r370 r438  
    111111  }
    112112#endif
     113
    113114#if H_MV
    114115  xSetLayerIds             ( vps );   
     
    135136    m_cTEncTop.setIvPicLists  ( &m_ivPicLists );
    136137#endif
     138
    137139  m_cTEncTop.setVPS(&vps);
    138140
    139141  m_cTEncTop.setProfile(m_profile);
    140142  m_cTEncTop.setLevel(m_levelTier, m_level);
     143
    141144#if L0046_CONSTRAINT_FLAGS
    142145  m_cTEncTop.setProgressiveSourceFlag(m_progressiveSourceFlag);
     
    183186  m_cTEncTop.setQP                           ( m_iQP );
    184187#endif
    185 
    186188  m_cTEncTop.setPad                          ( m_aiPad );
    187 
     189   
    188190#if H_MV
    189191  m_cTEncTop.setMaxTempLayer                 ( m_maxTempLayerMvc[layer] );
     
    205207  m_cTEncTop.setLoopFilterTcOffset           ( m_loopFilterTcOffsetDiv2    );
    206208  m_cTEncTop.setDeblockingFilterControlPresent( m_DeblockingFilterControlPresent);
    207 #if L0386_DB_METRIC
    208   m_cTEncTop.setDeblockingFilterMetric       ( m_DeblockingFilterMetric );
    209 #endif
    210209
    211210  //====== Motion search ========
     
    227226  Int lowestQP;
    228227  lowestQP =  - 6*(g_bitDepthY - 8); // XXX: check
    229 
    230228#if H_MV
    231229  if ((m_iMaxDeltaQP == 0 ) && (m_iQP[layer] == lowestQP) && (m_useLossless == true))
     
    245243  m_cTEncTop.setUseHADME                     ( m_bUseHADME    );
    246244  m_cTEncTop.setUseLossless                  ( m_useLossless );
    247 #if !L0034_COMBINED_LIST_CLEANUP
    248245  m_cTEncTop.setUseLComb                     ( m_bUseLComb    );
    249 #endif
    250246#if H_MV
    251247  m_cTEncTop.setdQPs                         ( m_aidQP[layer]   );
     
    325321  m_cTEncTop.setBufferingPeriodSEIEnabled( m_bufferingPeriodSEIEnabled );
    326322  m_cTEncTop.setPictureTimingSEIEnabled( m_pictureTimingSEIEnabled );
    327 #if J0149_TONE_MAPPING_SEI
    328   m_cTEncTop.setToneMappingInfoSEIEnabled                 ( m_toneMappingInfoSEIEnabled );
    329   m_cTEncTop.setTMISEIToneMapId                           ( m_toneMapId );
    330   m_cTEncTop.setTMISEIToneMapCancelFlag                   ( m_toneMapCancelFlag );
    331   m_cTEncTop.setTMISEIToneMapPersistenceFlag              ( m_toneMapPersistenceFlag );
    332   m_cTEncTop.setTMISEICodedDataBitDepth                   ( m_toneMapCodedDataBitDepth );
    333   m_cTEncTop.setTMISEITargetBitDepth                      ( m_toneMapTargetBitDepth );
    334   m_cTEncTop.setTMISEIModelID                             ( m_toneMapModelId );
    335   m_cTEncTop.setTMISEIMinValue                            ( m_toneMapMinValue );
    336   m_cTEncTop.setTMISEIMaxValue                            ( m_toneMapMaxValue );
    337   m_cTEncTop.setTMISEISigmoidMidpoint                     ( m_sigmoidMidpoint );
    338   m_cTEncTop.setTMISEISigmoidWidth                        ( m_sigmoidWidth );
    339   m_cTEncTop.setTMISEIStartOfCodedInterva                 ( m_startOfCodedInterval );
    340   m_cTEncTop.setTMISEINumPivots                           ( m_numPivots );
    341   m_cTEncTop.setTMISEICodedPivotValue                     ( m_codedPivotValue );
    342   m_cTEncTop.setTMISEITargetPivotValue                    ( m_targetPivotValue );
    343   m_cTEncTop.setTMISEICameraIsoSpeedIdc                   ( m_cameraIsoSpeedIdc );
    344   m_cTEncTop.setTMISEICameraIsoSpeedValue                 ( m_cameraIsoSpeedValue );
    345   m_cTEncTop.setTMISEIExposureCompensationValueSignFlag   ( m_exposureCompensationValueSignFlag );
    346   m_cTEncTop.setTMISEIExposureCompensationValueNumerator  ( m_exposureCompensationValueNumerator );
    347   m_cTEncTop.setTMISEIExposureCompensationValueDenomIdc   ( m_exposureCompensationValueDenomIdc );
    348   m_cTEncTop.setTMISEIRefScreenLuminanceWhite             ( m_refScreenLuminanceWhite );
    349   m_cTEncTop.setTMISEIExtendedRangeWhiteLevel             ( m_extendedRangeWhiteLevel );
    350   m_cTEncTop.setTMISEINominalBlackLevelLumaCodeValue      ( m_nominalBlackLevelLumaCodeValue );
    351   m_cTEncTop.setTMISEINominalWhiteLevelLumaCodeValue      ( m_nominalWhiteLevelLumaCodeValue );
    352   m_cTEncTop.setTMISEIExtendedWhiteLevelLumaCodeValue     ( m_extendedWhiteLevelLumaCodeValue );
    353 #endif
    354323  m_cTEncTop.setFramePackingArrangementSEIEnabled( m_framePackingSEIEnabled );
    355324  m_cTEncTop.setFramePackingArrangementSEIType( m_framePackingSEIType );
     
    361330  m_cTEncTop.setGradualDecodingRefreshInfoEnabled( m_gradualDecodingRefreshInfoEnabled );
    362331  m_cTEncTop.setDecodingUnitInfoSEIEnabled( m_decodingUnitInfoSEIEnabled );
    363 #if L0208_SOP_DESCRIPTION_SEI
    364   m_cTEncTop.setSOPDescriptionSEIEnabled( m_SOPDescriptionSEIEnabled );
    365 #endif
    366 #if K0180_SCALABLE_NESTING_SEI
    367   m_cTEncTop.setScalableNestingSEIEnabled( m_scalableNestingSEIEnabled );
    368 #endif
    369332  m_cTEncTop.setUniformSpacingIdr          ( m_iUniformSpacingIdr );
    370333  m_cTEncTop.setNumColumnsMinus1           ( m_iNumColumnsMinus1 );
     
    461424  }
    462425#endif
    463 #if H_MV
    464   }
    465 #endif
     426
     427#if H_MV
     428  }
     429#endif
     430
    466431}
    467432
     
    718683}
    719684#endif
     685
    720686// ====================================================================================================================
    721687// Protected member functions
     
    728694 .
    729695 */
     696
    730697#if H_MV
    731698Void TAppEncTop::xGetBuffer( TComPicYuv*& rpcPicYuvRec, UInt layer)
     
    755722
    756723  }
     724
    757725#if H_MV
    758726  m_picYuvRec[layer]->pushBack( rpcPicYuvRec );
     
    764732Void TAppEncTop::xDeleteBuffer( )
    765733{
     734
    766735#if H_MV
    767736  for(Int layer=0; layer<m_picYuvRec.size(); layer++)
     
    788757  }
    789758#endif 
     759
    790760}
    791761
     
    817787  {
    818788    TComPicYuv*  pcPicYuvRec  = *(iterPicYuvRec++);
     789
    819790#if H_MV
    820791      if (m_pchReconFileList[layerId])
     
    844815  }
    845816#endif
     817
    846818}
    847819
     
    860832    case NAL_UNIT_CODED_SLICE_TRAIL_R:
    861833    case NAL_UNIT_CODED_SLICE_TRAIL_N:
    862     case NAL_UNIT_CODED_SLICE_TLA_R:
     834    case NAL_UNIT_CODED_SLICE_TLA:
    863835    case NAL_UNIT_CODED_SLICE_TSA_N:
    864836    case NAL_UNIT_CODED_SLICE_STSA_R:
    865837    case NAL_UNIT_CODED_SLICE_STSA_N:
    866     case NAL_UNIT_CODED_SLICE_BLA_W_LP:
    867     case NAL_UNIT_CODED_SLICE_BLA_W_RADL:
     838    case NAL_UNIT_CODED_SLICE_BLA:
     839    case NAL_UNIT_CODED_SLICE_BLANT:
    868840    case NAL_UNIT_CODED_SLICE_BLA_N_LP:
    869     case NAL_UNIT_CODED_SLICE_IDR_W_RADL:
     841    case NAL_UNIT_CODED_SLICE_IDR:
    870842    case NAL_UNIT_CODED_SLICE_IDR_N_LP:
    871843    case NAL_UNIT_CODED_SLICE_CRA:
    872844    case NAL_UNIT_CODED_SLICE_RADL_N:
    873     case NAL_UNIT_CODED_SLICE_RADL_R:
     845    case NAL_UNIT_CODED_SLICE_DLP:
    874846    case NAL_UNIT_CODED_SLICE_RASL_N:
    875     case NAL_UNIT_CODED_SLICE_RASL_R:
     847    case NAL_UNIT_CODED_SLICE_TFD:
    876848    case NAL_UNIT_VPS:
    877849    case NAL_UNIT_SPS:
     
    889861void TAppEncTop::printRateSummary()
    890862{
     863
    891864#if H_MV
    892865  Double time = (Double) m_frameRcvd[0] / m_iFrameRate;
     
    895868  Double time = (Double) m_iFrameRcvd / m_iFrameRate;
    896869#endif
     870
    897871  printf("Bytes written to file: %u (%.3f kbps)\n", m_totalBytes, 0.008 * m_totalBytes / time);
    898872#if VERBOSE_RATE
     
    963937}
    964938#endif
     939
    965940//! \}
  • branches/HTM-DEV-0.2-dev/source/App/TAppEncoder/TAppEncTop.h

    r368 r438  
    5959private:
    6060  // class interface
     61
    6162#if H_MV
    6263  std::vector<TEncTop*>      m_acTEncTopList ;              ///< encoder class per layer
     
    99100 
    100101  // file I/O
     102
    101103#if H_MV
    102104  Void xWriteOutput(std::ostream& bitstreamFile, Int iNumEncoded, std::list<AccessUnit>& accessUnits, UInt layerId); ///< write bitstream to file
     
    104106  Void xWriteOutput(std::ostream& bitstreamFile, Int iNumEncoded, const std::list<AccessUnit>& accessUnits); ///< write bitstream to file
    105107#endif
     108
    106109  void rateStatsAccum(const AccessUnit& au, const std::vector<UInt>& stats);
    107110  void printRateSummary();
     
    113116  Int  xGetMax( std::vector<Int>& vec);
    114117#endif
     118
    115119public:
    116120  TAppEncTop();
     
    118122 
    119123  Void        encode      ();                               ///< main encoding function
     124
    120125#if H_MV
    121126  TEncTop*    getTEncTopLayer(UInt layer) { return  m_acTEncTopList[layer]; }  ///< return pointer to encoder class for specific layer
     
    126131  TEncTop&    getTEncTop  ()   { return  m_cTEncTop; }      ///< return encoder class pointer reference
    127132#endif
     133
    128134};// END CLASS DEFINITION TAppEncTop
    129135
  • branches/HTM-DEV-0.2-dev/source/App/TAppEncoder/encmain.cpp

    r368 r438  
    6262  fprintf( stdout, "HM software: Encoder Version [%s]", NV_VERSION );
    6363#endif
     64
    6465  fprintf( stdout, NVM_ONOS );
    6566  fprintf( stdout, NVM_COMPILEDBY );
Note: See TracChangeset for help on using the changeset viewer.