HEVC Test Model (HM)  HM-16.18
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Namespaces | Macros | Enumerations | Functions
TAppEncCfg.cpp File Reference

Handle encoder configuration parameters. More...

#include <stdio.h>
#include <stdlib.h>
#include <cassert>
#include <cstring>
#include <string>
#include <limits>
#include "TLibCommon/TComRom.h"
#include "TAppEncCfg.h"
#include "TAppCommon/program_options_lite.h"
#include "TLibEncoder/TEncRateCtrl.h"
Include dependency graph for TAppEncCfg.cpp:

Go to the source code of this file.

Classes

struct  MapStrToProfile
 
struct  MapStrToUIProfileName
 
struct  MapStrToTier
 
struct  MapStrToLevel
 
struct  MapStrToCostMode
 
struct  MapStrToScalingListMode
 
struct  SMultiValueInput< T >
 

Namespaces

 Level
 

Macros

#define MACRO_TO_STRING_HELPER(val)   #val
 
#define MACRO_TO_STRING(val)   MACRO_TO_STRING_HELPER(val)
 
#define xConfirmPara(a, b)   check_failed |= confirmPara(a,b)
 

Enumerations

enum  UIProfileName {
  UI_NONE = 0, UI_MAIN = 1, UI_MAIN10 = 2, UI_MAIN10_STILL_PICTURE =10002,
  UI_MAINSTILLPICTURE = 3, UI_MAINREXT = 4, UI_HIGHTHROUGHPUTREXT = 5, UI_MONOCHROME_8 = 1008,
  UI_MONOCHROME_12 = 1012, UI_MONOCHROME_16 = 1016, UI_MAIN_12 = 1112, UI_MAIN_422_10 = 1210,
  UI_MAIN_422_12 = 1212, UI_MAIN_444 = 1308, UI_MAIN_444_10 = 1310, UI_MAIN_444_12 = 1312,
  UI_MAIN_444_16 = 1316, UI_MAIN_INTRA = 2108, UI_MAIN_10_INTRA = 2110, UI_MAIN_12_INTRA = 2112,
  UI_MAIN_422_10_INTRA = 2210, UI_MAIN_422_12_INTRA = 2212, UI_MAIN_444_INTRA = 2308, UI_MAIN_444_10_INTRA = 2310,
  UI_MAIN_444_12_INTRA = 2312, UI_MAIN_444_16_INTRA = 2316, UI_MAIN_444_STILL_PICTURE = 11308, UI_MAIN_444_16_STILL_PICTURE = 12316,
  UI_HIGHTHROUGHPUT_444 = 21308, UI_HIGHTHROUGHPUT_444_10 = 21310, UI_HIGHTHROUGHPUT_444_14 = 21314, UI_HIGHTHROUGHPUT_444_16_INTRA = 22316
}
 

Functions

static istream & Level::operator>> (istream &in, Tier &tier)
 
static istream & Level::operator>> (istream &in, Name &level)
 
static struct MapStrToProfile strToProfile []
 
static struct MapStrToUIProfileName strToUIProfileName []
 
static const UIProfileName validRExtHighThroughPutProfileNames [2][4]
 
static const UIProfileName validRExtProfileNames [2][4][4]
 
static struct MapStrToTier strToTier []
 
static struct MapStrToLevel strToLevel []
 
UInt g_uiMaxCpbSize [2][21]
 
static struct MapStrToCostMode strToCostMode []
 
static struct
MapStrToScalingListMode 
strToScalingListMode []
 
std::istringstream & operator>> (std::istringstream &in, GOPEntry &entry)
 
Bool confirmPara (Bool bflag, const TChar *message)
 
static ChromaFormat numberToChromaFormat (const Int val)
 
template<typename T , typename P >
static std::string enumToString (P map[], UInt mapLen, const T val)
 
template<typename T , typename P >
static istream & readStrToEnum (P map[], UInt mapLen, istream &in, T &val)
 
static istream & operator>> (istream &in, UIProfileName &profile)
 
static istream & operator>> (istream &in, CostMode &mode)
 
static istream & operator>> (istream &in, ScalingListMode &mode)
 
template<class T >
static istream & operator>> (std::istream &in, SMultiValueInput< T > &values)
 
template<class T >
static istream & operator>> (std::istream &in, TAppEncCfg::OptionalValue< T > &value)
 
static Void automaticallySelectRExtProfile (const Bool bUsingGeneralRExtTools, const Bool bUsingChromaQPAdjustment, const Bool bUsingExtendedPrecision, const Bool bIntraConstraintFlag, UInt &bitDepthConstraint, ChromaFormat &chromaFormatConstraint, const Int maxBitDepth, const ChromaFormat chromaFormat)
 
const TCharprofileToString (const Profile::Name profile)
 

Detailed Description

Handle encoder configuration parameters.

Definition in file TAppEncCfg.cpp.

Macro Definition Documentation

#define MACRO_TO_STRING (   val)    MACRO_TO_STRING_HELPER(val)

Definition at line 53 of file TAppEncCfg.cpp.

#define MACRO_TO_STRING_HELPER (   val)    #val

Definition at line 52 of file TAppEncCfg.cpp.

#define xConfirmPara (   a,
 
)    check_failed |= confirmPara(a,b)

Enumeration Type Documentation

Enumerator
UI_NONE 
UI_MAIN 
UI_MAIN10 
UI_MAIN10_STILL_PICTURE 
UI_MAINSTILLPICTURE 
UI_MAINREXT 
UI_HIGHTHROUGHPUTREXT 
UI_MONOCHROME_8 
UI_MONOCHROME_12 
UI_MONOCHROME_16 
UI_MAIN_12 
UI_MAIN_422_10 
UI_MAIN_422_12 
UI_MAIN_444 
UI_MAIN_444_10 
UI_MAIN_444_12 
UI_MAIN_444_16 
UI_MAIN_INTRA 
UI_MAIN_10_INTRA 
UI_MAIN_12_INTRA 
UI_MAIN_422_10_INTRA 
UI_MAIN_422_12_INTRA 
UI_MAIN_444_INTRA 
UI_MAIN_444_10_INTRA 
UI_MAIN_444_12_INTRA 
UI_MAIN_444_16_INTRA 
UI_MAIN_444_STILL_PICTURE 
UI_MAIN_444_16_STILL_PICTURE 
UI_HIGHTHROUGHPUT_444 
UI_HIGHTHROUGHPUT_444_10 
UI_HIGHTHROUGHPUT_444_14 
UI_HIGHTHROUGHPUT_444_16_INTRA 

Definition at line 58 of file TAppEncCfg.cpp.

Function Documentation

static Void automaticallySelectRExtProfile ( const Bool  bUsingGeneralRExtTools,
const Bool  bUsingChromaQPAdjustment,
const Bool  bUsingExtendedPrecision,
const Bool  bIntraConstraintFlag,
UInt bitDepthConstraint,
ChromaFormat chromaFormatConstraint,
const Int  maxBitDepth,
const ChromaFormat  chromaFormat 
)
static

Definition at line 564 of file TAppEncCfg.cpp.

Bool confirmPara ( Bool  bflag,
const TChar message 
)

Definition at line 3021 of file TAppEncCfg.cpp.

template<typename T , typename P >
static std::string enumToString ( map[],
UInt  mapLen,
const T  val 
)
static

Definition at line 368 of file TAppEncCfg.cpp.

static ChromaFormat numberToChromaFormat ( const Int  val)
inlinestatic

Definition at line 198 of file TAppEncCfg.cpp.

std::istringstream& operator>> ( std::istringstream &  in,
GOPEntry entry 
)

Definition at line 158 of file TAppEncCfg.cpp.

static istream& operator>> ( istream &  in,
UIProfileName profile 
)
inlinestatic

Definition at line 402 of file TAppEncCfg.cpp.

static istream& operator>> ( istream &  in,
CostMode mode 
)
inlinestatic

Definition at line 420 of file TAppEncCfg.cpp.

static istream& operator>> ( istream &  in,
ScalingListMode mode 
)
inlinestatic

Definition at line 425 of file TAppEncCfg.cpp.

template<class T >
static istream& operator>> ( std::istream &  in,
SMultiValueInput< T > &  values 
)
inlinestatic

Definition at line 453 of file TAppEncCfg.cpp.

template<class T >
static istream& operator>> ( std::istream &  in,
TAppEncCfg::OptionalValue< T > &  value 
)
inlinestatic

Definition at line 547 of file TAppEncCfg.cpp.

const TChar* profileToString ( const Profile::Name  profile)

Definition at line 2784 of file TAppEncCfg.cpp.

template<typename T , typename P >
static istream& readStrToEnum ( map[],
UInt  mapLen,
istream &  in,
T &  val 
)
static

Definition at line 381 of file TAppEncCfg.cpp.

Variable Documentation

UInt g_uiMaxCpbSize[2][21]
Initial value:
=
{
{ 0, 0, 0, 350000, 0, 0, 1500000, 3000000, 0, 6000000, 10000000, 0, 12000000, 20000000, 0, 25000000, 40000000, 60000000, 60000000, 120000000, 240000000 },
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 30000000, 50000000, 0, 100000000, 160000000, 240000000, 240000000, 480000000, 800000000 }
}

Definition at line 332 of file TAppEncCfg.cpp.

struct MapStrToCostMode strToCostMode[]
static
struct MapStrToLevel strToLevel[]
static
struct MapStrToProfile strToProfile[]
static
Initial value:
=
{
{"none", Profile::NONE },
{"main", Profile::MAIN },
{"main10", Profile::MAIN10 },
{"main-still-picture", Profile::MAINSTILLPICTURE },
{"main10-still-picture", Profile::MAIN10 },
{"main-RExt", Profile::MAINREXT },
{"high-throughput-RExt", Profile::HIGHTHROUGHPUTREXT }
}
struct MapStrToScalingListMode strToScalingListMode[]
static
struct MapStrToTier strToTier[]
static
Initial value:
=
{
{"main", Level::MAIN},
{"high", Level::HIGH},
}
struct MapStrToUIProfileName strToUIProfileName[]
static
const UIProfileName validRExtHighThroughPutProfileNames[2][4]
static
const UIProfileName validRExtProfileNames[2][4][4]
static