gConfig.nCores = 1; gConfig.coreTeamMap[0] = '0'; gConfig.encodingPreset = 3;// # encoding preset 0: DEFAULT, 1: HIGH_QUALITY, 2: HIGH_SPEED, 3:USER_DEFINED gConfig.rateControlPreset = 5;// # 5: IVIDEO_USER_DEFINED, 4: IVIDEO_NONE, 2: IVIDEO_STORAGE, 1: IVIDEO_LOW_DELAY gConfig.maxWidth = 352;// # Max Frame width gConfig.maxHeight = 240;// # Max Frame height gConfig.inputChromaFormat = 1;// # 1 => XDM_YUV_420P, Only 1 is supported. gConfig.inputContentType = 0;// # Input buffer content type, 0 -> Progressive Type, 1-> Interlaced. gConfig.mvAccuracy = 2;//# Pixel accuracy of the motion vector, 0 => integer pel 2=> quarter pel gConfig.generateHeader = 0;// # 1: Encode only header, 0: Encode entire access unit, including the headers gConfig.forceFrame = -1 ;//# -1: IVIDEO_NA_FRAME, 3: IVIDEO_IDR_FRAME gConfig.dataLayout = 0 ; gConfig.sampleAspectRatioHeight = 1 ;//# Aspect Ratio Height gConfig.sampleAspectRatioWidth = 1 ;//# Aspect Ratio Width gConfig.rateControlParamsPreset = 1; gConfig.qpI = -1;// # Initial QP for I/IDR frames, -1 indicates codec chosen gConfig.qpP = -1;// # Initial QP for P frames gConfig.qpOffsetB = 4;// # Offset of B frames QP from P frames gConfig.CbQPIndexOffset = 0 ;//# Specifies offset to be added to luma QP for addressing QPC values table for Cb components gConfig.CrQPIndexOffset = 0 ;//# Specifies offset to be added to luma QP for addressing QPC values table for Cr components gConfig.initialBufferLevel = basic_encoder_params.targetBitRate*2 ; gConfig.HRDBufferSize = basic_encoder_params.targetBitRate*2 ; gConfig.enablePRC = 1;// # Control Flag to enable MB level Perceptual Rate Control, 0 => Disable, 1 => Enable gConfig.frameSkipAfterSceneChange = 1; gConfig.scalingMatrixPreset = 0 ; gConfig.suppressHighFreqCoeffs = 1 ; gConfig.interCodingPreset = 1 ;//# Inter coding mode preset, 0 => deafult values, 1 => user defined gConfig.MvRangeVerP = 32 ;// # Vertical Motion Vector Range for P frames in integer pixels, Range supported is 16 to 496 gConfig.MvRangeHorP = 144;// # Horizontal Motion Vector Range for P frames in integer pixels, Range supported is 16 to 496 gConfig.MvRangeVerB = 32 ;// # Vertical Motion Vector Range for B frames in integer pixels, Range supported is 16 to 496 gConfig.MvRangeHorB = 144 ;//# Horizontal Motion Vector Range for B frames in integer pixels, Range supported is 16 to 496 gConfig.maxMVperMB = 4 ;//# Maximum MV per MB (Values of 1 & 4 are valid) gConfig.intraCodingPreset = 1 ;//# Intra coding mode preset, 0 => deafult values, 1 => user defined gConfig.enableIntraPartition = 4 ; gConfig.intraRefreshMethod = 0 ;//# IH264_INTRAREFRESH_NONE = 0, IH264_INTRAREFRESH_CYCLIC_MBS = 1 gConfig.intraRefreshRate = 0 ; gConfig.constrainedIntraPredEnable = 0;// # Controls the intra macroblock coding in inter slices gConfig.entropyCodingMode = 1;// # Enropy coding type, (0 => CAVLC, 1 => CABAC) gConfig.sliceCodingPreset = 0 ;//# Preset value for slice coding mode, 0 => deafult values, 1 => user defined gConfig.streamFormat = 0;// # Type of bitstream to be encoded, 0 => Byte stream format, 1=> NALU format(without start code) gConfig.sliceMode = 0 ; gConfig.sliceUnitSize = 1200 ;//# Number of macroblocks per slice gConfig.loopfilterPreset = 1 ;//# Preset value for loop filter operation parameters, 0 => default values, 1 => user defined gConfig.loopfilterDisableIDC = 2 ;//# Disable H.264 loop filter, (0=Filter, 1= NoFilter, 2 = No loop filter across slices) gConfig.filterOffsetA = 0 ;//# Alpha offset for loop filter gConfig.filterOffsetB = 0 ;//# Beta offset for loop filter gConfig.vuiCodingPreset = 1;// # Preset value for VUI Control Params, 0 => deafult values, 1 => user defined gConfig.aspectRatioInfoPresentFlag = 1 ;//# Controls the insertion of aspect ratio information in VUI part of bit-stream gConfig.aspectRatioIdc = 1 ;//# Aspect ratio ID gConfig.videoSignalTypePresentFlag = 0 ;//# controls the insertion of video signal type in VUI part of bit-stream gConfig.videoFormat = 2 ;//# Video signal type gConfig.videoFullRangeFlag = 0 ;//# Flag to specigy Range of the pixels gConfig.colourDescriptionPresentFlag = 1 ; gConfig.colourPrimaries = 5;// # chromaticity coordinates of the source primaries(Table E-3 in standard) gConfig.transferCharacteristics = 5;// # opto-electronic transfer characteristic of the source picture(Table E-4 in standard) gConfig.matrixCoefficients = 5; gConfig.timingInfoPresentFlag = 1;// # Controls the insertion of timing info related parameters in VUI part of bit-stream gConfig.gopStructure = 0 ;//# GOP structure, 0 => Open or Non uniform(IBBPBBP), 1 => Closed or Uniform (BBIBBPBB) gConfig.log2MaxFNumMinus4 = 0; gConfig.picOrderCountType = 0 ;// # Picture order count type gConfig.transformBlockSize = 1 ;// # Tranform type, 0:4x4 only, 1: 8x8 only - 4x4 for BP, 8x8 for HP gConfig.topFieldFirstFlag = 1 ;// # Flag to indicate field order in interlaced content gConfig.interlaceCodingType = 4 ;//# Interlced field coding type selection, 2 => MRF 3=> ARF 4=> SPF gConfig.debugTraceLevel = 0 ;//# Debug trace Enable 0 - Disable, 1- Level1, 2 - Level2, 3 - Level3, gConfig.lastNFramesToLog = 5 ;//# Last N frames to log into debug trace buffer gConfig.maxInterFrameInterval = 3; gConfig.profile = 100; // = 66;// # Encoding profile 100 => HP, 77 => MP, 66 => BP. gConfig.level = 40; // = 40;// # Level IDC (e.g. 20 = level 2.0) gConfig.inputWidth = 352; // = 352;// # width of image gConfig.inputHeight = 240; // = 240;// # Height of image gConfig.targetFrameRate = 30000; gConfig.targetBitRate = 50000;// # Target Bit Rate in Bits per second. gConfig.intraFrameInterval = 15; gConfig.interFrameInterval = 3; gConfig.qpMaxI = 51;// # was 51 Maximum QP for I/IDR frames gConfig.qpMinI = 1;// # Minimum QP for I/IDR frames gConfig.qpMaxP = 51;// # was 51 Maximum QP for P frames gConfig.qpMinP = 1;// # Minimum QP for P frames gConfig.qpMaxB = 51 ;//# Maximum QP for B frames gConfig.qpMinB = 1 ;//# Minimum QP for B frames gConfig.rcAlgo = 2; gConfig.IDRFrameInterval = 0;