shithub: openh264

Download patch

ref: 1e62aafcde45b0df339cd53ca5835413b50d6568
parent: 4fc27714bd219e2a3edb4c07a2e6ec13dc45aeeb
author: Daniel J. Hofmann <[email protected]>
date: Tue Oct 14 18:20:10 EDT 2014

Wc++11-extensions

--- a/codec/api/svc/codec_app_def.h
+++ b/codec/api/svc/codec_app_def.h
@@ -104,7 +104,7 @@
   ENCODER_OPTION_TRACE_CALLBACK_CONTEXT,
 
   // advanced algorithmetic settings
-  ENCODER_OPTION_IS_LOSSLESS_LINK,
+  ENCODER_OPTION_IS_LOSSLESS_LINK
 } ENCODER_OPTION;
 
 /* Option types introduced in decoder application */
@@ -120,7 +120,7 @@
   DECODER_OPTION_ERROR_CON_IDC, //not finished yet, indicate decoder error concealment status, in progress
   DECODER_OPTION_TRACE_LEVEL,
   DECODER_OPTION_TRACE_CALLBACK, // a void (*)(void* context, int level, const char* message) function which receives log messages
-  DECODER_OPTION_TRACE_CALLBACK_CONTEXT,
+  DECODER_OPTION_TRACE_CALLBACK_CONTEXT
 
 } DECODER_OPTION;
 
@@ -128,7 +128,7 @@
 typedef enum {
   ERROR_CON_DISABLE = 0,
   ERROR_CON_FRAME_COPY,
-  ERROR_CON_SLICE_COPY,
+  ERROR_CON_SLICE_COPY
 } ERROR_CON_IDC;
 
 typedef enum { //feedback that whether or not have VCL NAL in current AU
@@ -148,7 +148,7 @@
   SPATIAL_LAYER_1 = 1,
   SPATIAL_LAYER_2 = 2,
   SPATIAL_LAYER_3 = 3,
-  SPATIAL_LAYER_ALL = 4,
+  SPATIAL_LAYER_ALL = 4
 } LAYER_NUM;
 
 //enumerate the type of video bitstream which is provided to decoder
@@ -155,7 +155,7 @@
 typedef enum {
   VIDEO_BITSTREAM_AVC               = 0,
   VIDEO_BITSTREAM_SVC               = 1,
-  VIDEO_BITSTREAM_DEFAULT           = VIDEO_BITSTREAM_SVC,
+  VIDEO_BITSTREAM_DEFAULT           = VIDEO_BITSTREAM_SVC
 } VIDEO_BITSTREAM_TYPE;
 
 typedef enum {
@@ -164,7 +164,7 @@
   IDR_RECOVERY_REQUEST = 2,
   NO_LTR_MARKING_FEEDBACK = 3,
   LTR_MARKING_SUCCESS = 4,
-  LTR_MARKING_FAILED = 5,
+  LTR_MARKING_FAILED = 5
 } KEY_FRAME_REQUEST_TYPE;
 
 typedef struct {
@@ -205,7 +205,7 @@
   RC_QUALITY_MODE = 0,      //Quality mode
   RC_BITRATE_MODE = 1,   //Bitrate mode
   RC_BUFFERBASED_MODE = 2,//no bitrate control,only using buffer status,adjust the video quality
-  RC_OFF_MODE = -1,    // rate control off mode
+  RC_OFF_MODE = -1     // rate control off mode
 } RC_MODES;
 
 typedef enum {
@@ -220,7 +220,7 @@
   PRO_CAVLC444	= 244,
 
   PRO_SCALABLE_BASELINE	= 83,
-  PRO_SCALABLE_HIGH		= 86,
+  PRO_SCALABLE_HIGH		= 86
 } EProfileIdc;
 
 typedef enum {
@@ -277,13 +277,13 @@
 
 typedef enum {
   CAMERA_VIDEO_REAL_TIME, //camera video signal
-  SCREEN_CONTENT_REAL_TIME,//screen content signal
+  SCREEN_CONTENT_REAL_TIME //screen content signal
 } EUsageType;
 
 typedef enum {
   LOW_COMPLEXITY, //the lowest compleixty,the fastest speed,
   MEDIUM_COMPLEXITY, //medium complexity, medium speed,medium quality
-  HIGH_COMPLEXITY, //high complexity, lowest speed, high quality
+  HIGH_COMPLEXITY  //high complexity, lowest speed, high quality
 } ECOMPLEXITY_MODE;
 // TODO:  Refine the parameters definition.
 // SVC Encoding Parameters
--- a/codec/api/svc/codec_def.h
+++ b/codec/api/svc/codec_def.h
@@ -63,7 +63,7 @@
   videoFrameTypeI,		/* I frame type */
   videoFrameTypeP,		/* P frame type */
   videoFrameTypeSkip,		/* Skip the frame based encoder kernel */
-  videoFrameTypeIPMixed,		/* Frame type introduced I and P slices are mixing */
+  videoFrameTypeIPMixed 		/* Frame type introduced I and P slices are mixing */
 } EVideoFrameType;
 
 typedef enum {
@@ -72,7 +72,7 @@
   cmUnkonwReason,
   cmMallocMemeError,                /*Malloc a memory error*/
   cmInitExpected,			  /*Initial action is expected*/
-  cmUnsupportedData,
+  cmUnsupportedData
 } CM_RETURN;
 
 /* nal unit type */
@@ -93,7 +93,7 @@
   NAL_PRIORITY_DISPOSABLE = 0,
   NAL_PRIORITY_LOW        = 1,
   NAL_PRIORITY_HIGH       = 2,
-  NAL_PRIORITY_HIGHEST    = 3,
+  NAL_PRIORITY_HIGHEST    = 3
 };
 
 #define IS_PARAMETER_SET_NAL(eNalRefIdc, eNalType) \
@@ -116,7 +116,7 @@
   ET_IR_R3 = 0x10,				// Intra Refresh in predifined 10% MB
   ET_FEC_HALF = 0x20,				// Forward Error Correction in 50% redundency mode
   ET_FEC_FULL	= 0x40,				// Forward Error Correction in 100% redundency mode
-  ET_RFS = 0x80,					// Reference Frame Selection
+  ET_RFS = 0x80 					// Reference Frame Selection
 };
 
 /* information of coded Slice(=NAL)(s) */
--- a/codec/decoder/core/inc/error_code.h
+++ b/codec/decoder/core/inc/error_code.h
@@ -48,7 +48,7 @@
 ERR_MALLOC_FAILED		= 2,
 ERR_API_FAILED			= 3,
 
-ERR_BOUND				= 31,
+ERR_BOUND				= 31
 } EWelsErr;
 
 /*
@@ -68,7 +68,7 @@
 ERR_LEVEL_PARAM_SETS,
 ERR_LEVEL_SLICE_HEADER,
 ERR_LEVEL_SLICE_DATA,
-ERR_LEVEL_MB_DATA,
+ERR_LEVEL_MB_DATA
 };
 
 //-----------------------------------------------------------------------------------------------------------
@@ -180,7 +180,7 @@
 ERR_INFO_INVALID_MMCO_SHOART2LONG,
 ERR_INFO_INVALID_MMCO_REF_NUM_OVERFLOW,
 ERR_INFO_INVALID_MMCO_REF_NUM_NOT_ENOUGH,
-ERR_INFO_INVALID_MMCO_LONG_TERM_IDX_EXCEED_MAX,
+ERR_INFO_INVALID_MMCO_LONG_TERM_IDX_EXCEED_MAX
 };
 //-----------------------------------------------------------------------------------------------------------
 
--- a/codec/decoder/core/inc/wels_common_basis.h
+++ b/codec/decoder/core/inc/wels_common_basis.h
@@ -60,7 +60,7 @@
 PRO_CAVLC444	= 244,
 
 PRO_SCALABLE_BASELINE	= 83,
-PRO_SCALABLE_HIGH		= 86,
+PRO_SCALABLE_HIGH		= 86
 };
 
 /* Picture Size */
@@ -83,7 +83,7 @@
 MB_TOP      = 0x02,	// B
 MB_TOPRIGHT = 0x04,	// C
 MB_TOPLEFT	= 0x08,	// D,
-MB_PRIVATE  = 0x10,
+MB_PRIVATE  = 0x10
 };
 /* MB Type & Sub-MB Type */
 typedef int32_t MbType;
--- a/codec/encoder/core/inc/rc.h
+++ b/codec/encoder/core/inc/rc.h
@@ -56,7 +56,7 @@
 enum {
   BITS_NORMAL,
   BITS_LIMITED,
-  BITS_EXCEEDED,
+  BITS_EXCEEDED
 };
 
 enum {
@@ -102,7 +102,7 @@
   GOM_ROW_MODE1_720P    = 2,
   QP_RANGE_UPPER_MODE1  = 9,
   QP_RANGE_LOWER_MODE1  = 4,
-  QP_RANGE_INTRA_MODE1  = 3,
+  QP_RANGE_INTRA_MODE1  = 3
 };
 
 //bits allocation
--- a/codec/encoder/core/inc/ref_list_mgr_svc.h
+++ b/codec/encoder/core/inc/ref_list_mgr_svc.h
@@ -50,7 +50,7 @@
 
 typedef enum {
 LTR_DIRECT_MARK = 0,
-LTR_DELAY_MARK = 1,
+LTR_DELAY_MARK = 1
 } LTR_MARKING_PROCESS_MODE;
 
 typedef enum {
@@ -57,7 +57,7 @@
 FRAME_NUM_EQUAL    = 0x01,
 FRAME_NUM_BIGGER   = 0x02,
 FRAME_NUM_SMALLER  = 0x04,
-FRAME_NUM_OVER_MAX = 0x08,
+FRAME_NUM_OVER_MAX = 0x08
 } COMPARE_FRAME_NUM;
 
 /*
--- a/codec/encoder/core/inc/svc_mode_decision.h
+++ b/codec/encoder/core/inc/svc_mode_decision.h
@@ -55,7 +55,7 @@
 
 typedef enum {
 STATIC,
-SCROLLED,
+SCROLLED
 } ESkipModes;
 
 // NOILP ILFMD ENTRANCE
--- a/codec/encoder/core/inc/svc_motion_estimate.h
+++ b/codec/encoder/core/inc/svc_motion_estimate.h
@@ -62,7 +62,7 @@
 
 // derived ME methods combination
 ME_DIA_CROSS    = (ME_DIA | ME_CROSS),   // DIA+CROSS
-ME_DIA_CROSS_FME  = (ME_DIA_CROSS | ME_FME), // DIA+CROSS+FME
+ME_DIA_CROSS_FME  = (ME_DIA_CROSS | ME_FME)  // DIA+CROSS+FME
 };
 
 union SadPredISatdUnit {
--- a/codec/encoder/core/inc/wels_const.h
+++ b/codec/encoder/core/inc/wels_const.h
@@ -192,7 +192,7 @@
 typedef enum {
 RECIEVE_UNKOWN = 0,
 RECIEVE_SUCCESS = 1,
-RECIEVE_FAILED = 2,
+RECIEVE_FAILED = 2
 } LTR_MARKING_RECEIVE_STATE;
 
 enum {
--- a/codec/processing/interface/IWelsVP.h
+++ b/codec/processing/interface/IWelsVP.h
@@ -142,7 +142,7 @@
 typedef enum {
   SIMILAR_SCENE,   //similar scene
   MEDIUM_CHANGED_SCENE,   //medium changed scene
-  LARGE_CHANGED_SCENE,    //large changed scene
+  LARGE_CHANGED_SCENE     //large changed scene
 } ESceneChangeIdc;
 
 typedef enum {
@@ -149,7 +149,7 @@
   NO_STATIC,  // motion block
   COLLOCATED_STATIC, // collocated static block
   SCROLLED_STATIC,  // scrolled static block
-  BLOCK_STATIC_IDC_ALL,
+  BLOCK_STATIC_IDC_ALL
 } EStaticBlockIdc;
 
 typedef struct {
@@ -195,7 +195,7 @@
 
 typedef enum {
   AQ_QUALITY_MODE,   //Quality mode
-  AQ_BITRATE_MODE,   //Bitrate mode
+  AQ_BITRATE_MODE    //Bitrate mode
 } EAQModes;
 
 typedef struct {