[astyle]: formating coding style

git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@186 6e48237b-75ef-9749-8fc9-41990f28c85a
This commit is contained in:
ChenHengming
2008-01-24 21:36:21 +00:00
parent 95704e887c
commit 608671728d
8 changed files with 26 additions and 30 deletions

View File

@@ -7,7 +7,6 @@ add_library(mpp_codec STATIC
mpp_buf_slot.cpp mpp_buf_slot.cpp
mpp_enc.cpp mpp_enc.cpp
mpp_dec.cpp mpp_dec.cpp
) )
set_target_properties(mpp_codec PROPERTIES FOLDER "mpp/codec") set_target_properties(mpp_codec PROPERTIES FOLDER "mpp/codec")
add_subdirectory(dec) add_subdirectory(dec)

View File

@@ -34,7 +34,8 @@ extern RK_U32 mpp_debug;
#define mpp_dbg(flag, fmt, ...) _mpp_dbg(mpp_debug, flag, fmt, ## __VA_ARGS__) #define mpp_dbg(flag, fmt, ...) _mpp_dbg(mpp_debug, flag, fmt, ## __VA_ARGS__)
class Mpp { class Mpp
{
public: public:
Mpp(MppCtxType type, MppCodingType coding); Mpp(MppCtxType type, MppCodingType coding);
~Mpp(); ~Mpp();

View File

@@ -20,8 +20,7 @@
#include "rk_type.h" #include "rk_type.h"
enum __MIDL___MIDL_itf_dxva2api_0000_0000_0012 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0012 {
{
DXVA2_PictureParametersBufferType = 0, DXVA2_PictureParametersBufferType = 0,
DXVA2_MacroBlockControlBufferType = 1, DXVA2_MacroBlockControlBufferType = 1,
DXVA2_ResidualDifferenceBufferType = 2, DXVA2_ResidualDifferenceBufferType = 2,
@@ -33,8 +32,7 @@ enum __MIDL___MIDL_itf_dxva2api_0000_0000_0012
DXVA2_FilmGrainBuffer = 8 DXVA2_FilmGrainBuffer = 8
}; };
typedef struct _DXVA2_ConfigPictureDecode typedef struct _DXVA2_ConfigPictureDecode {
{
//GUID guidConfigBitstreamEncryption; //GUID guidConfigBitstreamEncryption;
//GUID guidConfigMBcontrolEncryption; //GUID guidConfigMBcontrolEncryption;
//GUID guidConfigResidDiffEncryption; //GUID guidConfigResidDiffEncryption;
@@ -52,10 +50,9 @@ typedef struct _DXVA2_ConfigPictureDecode
//UINT Config4GroupedCoefs; //UINT Config4GroupedCoefs;
//USHORT ConfigMinRenderTargetBuffCount; //USHORT ConfigMinRenderTargetBuffCount;
//USHORT ConfigDecoderSpecific; //USHORT ConfigDecoderSpecific;
}DXVA2_ConfigPictureDecode; } DXVA2_ConfigPictureDecode;
typedef struct _DXVA2_DecodeBufferDesc typedef struct _DXVA2_DecodeBufferDesc {
{
RK_U32 CompressedBufferType; RK_U32 CompressedBufferType;
RK_U32 BufferIndex; RK_U32 BufferIndex;
RK_U32 DataOffset; RK_U32 DataOffset;

View File

@@ -418,8 +418,7 @@ typedef struct _DXVA_PicParams_H264_MVC {
} DXVA_PicParams_H264_MVC, *LPDXVA_PicParams_H264_MVC; } DXVA_PicParams_H264_MVC, *LPDXVA_PicParams_H264_MVC;
typedef struct h264d_syntax_t typedef struct h264d_syntax_t {
{
RK_U32 num; RK_U32 num;
DXVA2_DecodeBufferDesc *buf; DXVA2_DecodeBufferDesc *buf;
} H264D_Syntax_t; } H264D_Syntax_t;

View File

@@ -14,7 +14,7 @@ macro(add_mpp_test module)
if(${test_tag}) if(${test_tag})
add_executable(${test_name} ${test_name}.c) add_executable(${test_name} ${test_name}.c)
target_link_libraries(${test_name} mpp) target_link_libraries(${test_name} mpp)
set_target_properties(${test_name} PROPERTIES FOLDER "mpp/test") set_target_properties(${test_name} PROPERTIES FOLDER "mpp/test")
install(TARGETS ${test_name} RUNTIME DESTINATION ${TEST_INSTALL_DIR}) install(TARGETS ${test_name} RUNTIME DESTINATION ${TEST_INSTALL_DIR})
endif() endif()
endmacro() endmacro()

View File

@@ -14,7 +14,7 @@ macro(add_mpp_osal_test module)
if(${test_tag}) if(${test_tag})
add_executable(${test_name} ${test_name}.c) add_executable(${test_name} ${test_name}.c)
target_link_libraries(${test_name} osal) target_link_libraries(${test_name} osal)
set_target_properties(${test_name} PROPERTIES FOLDER "osal/test") set_target_properties(${test_name} PROPERTIES FOLDER "osal/test")
install(TARGETS ${test_name} RUNTIME DESTINATION ${TEST_INSTALL_DIR}) install(TARGETS ${test_name} RUNTIME DESTINATION ${TEST_INSTALL_DIR})
add_test(NAME ${test_name} COMMAND ${test_name}) add_test(NAME ${test_name} COMMAND ${test_name})
endif() endif()

View File

@@ -14,7 +14,7 @@ macro(add_mpp_test module)
if(${test_tag}) if(${test_tag})
add_executable(${test_name} ${test_name}.c) add_executable(${test_name} ${test_name}.c)
target_link_libraries(${test_name} mpp) target_link_libraries(${test_name} mpp)
set_target_properties(${test_name} PROPERTIES FOLDER "test") set_target_properties(${test_name} PROPERTIES FOLDER "test")
install(TARGETS ${test_name} RUNTIME DESTINATION ${TEST_INSTALL_DIR}) install(TARGETS ${test_name} RUNTIME DESTINATION ${TEST_INSTALL_DIR})
add_test(NAME ${test_name} COMMAND ${test_name}) add_test(NAME ${test_name} COMMAND ${test_name})
endif() endif()

View File

@@ -232,7 +232,7 @@ PARSE_OPINIONS_OUT:
static RK_S32 readBytesFromFile(RK_U8* buf, RK_S32 aBytes, FILE* file) static RK_S32 readBytesFromFile(RK_U8* buf, RK_S32 aBytes, FILE* file)
{ {
RK_S32 ret = 0; RK_S32 ret = 0;
if ((NULL == buf) || (NULL == file) || (0 == aBytes)) { if ((NULL == buf) || (NULL == file) || (0 == aBytes)) {
return -1; return -1;
@@ -261,14 +261,14 @@ static RK_S32 vpu_encode_demo(VpuApiDemoCmdContext_t *cmd)
EncInputStream_t *enc_in = NULL; EncInputStream_t *enc_in = NULL;
EncParameter_t *enc_param = NULL; EncParameter_t *enc_param = NULL;
RK_S64 fakeTimeUs = 0; RK_S64 fakeTimeUs = 0;
RK_U32 w_align = 0; RK_U32 w_align = 0;
RK_U32 h_align = 0; RK_U32 h_align = 0;
int Format = VPU_H264ENC_YUV420_SEMIPLANAR; int Format = VPU_H264ENC_YUV420_SEMIPLANAR;
if (cmd == NULL) { if (cmd == NULL) {
return -1; return -1;
} }
if ((cmd->have_input == 0) || (cmd->width <= 0) || (cmd->height <= 0) if ((cmd->have_input == 0) || (cmd->width <= 0) || (cmd->height <= 0)
|| (cmd->coding <= OMX_RK_VIDEO_CodingAutoDetect)) { || (cmd->coding <= OMX_RK_VIDEO_CodingAutoDetect)) {
@@ -475,7 +475,7 @@ ENCODE_OUT:
static RK_S32 vpu_decode_demo(VpuApiDemoCmdContext_t *cmd) static RK_S32 vpu_decode_demo(VpuApiDemoCmdContext_t *cmd)
{ {
FILE* pInFile = NULL; FILE* pInFile = NULL;
FILE* pOutFile = NULL; FILE* pOutFile = NULL;
struct VpuCodecContext* ctx = NULL; struct VpuCodecContext* ctx = NULL;
RK_S32 fileSize = 0, pkt_size = 0; RK_S32 fileSize = 0, pkt_size = 0;
@@ -489,13 +489,13 @@ static RK_S32 vpu_decode_demo(VpuApiDemoCmdContext_t *cmd)
RK_S64 fakeTimeUs = 0; RK_S64 fakeTimeUs = 0;
RK_U8* pExtra = NULL; RK_U8* pExtra = NULL;
RK_U32 extraSize = 0; RK_U32 extraSize = 0;
RK_U32 wAlign16 = 0; RK_U32 wAlign16 = 0;
RK_U32 hAlign16 = 0; RK_U32 hAlign16 = 0;
RK_U32 frameSize = 0; RK_U32 frameSize = 0;
if (cmd == NULL) { if (cmd == NULL) {
return -1; return -1;
} }
if ((cmd->have_input == 0) || (cmd->width <= 0) || (cmd->height <= 0) if ((cmd->have_input == 0) || (cmd->width <= 0) || (cmd->height <= 0)
|| (cmd->coding <= OMX_RK_VIDEO_CodingAutoDetect)) { || (cmd->coding <= OMX_RK_VIDEO_CodingAutoDetect)) {
@@ -710,12 +710,12 @@ DECODE_OUT:
int main(int argc, char **argv) int main(int argc, char **argv)
{ {
RK_S32 ret = 0; RK_S32 ret = 0;
VpuApiDemoCmdContext_t demoCmdCtx; VpuApiDemoCmdContext_t demoCmdCtx;
VpuApiDemoCmdContext_t *cmd = NULL; VpuApiDemoCmdContext_t *cmd = NULL;
VPU_API_DEMO_DEBUG_DISABLE = 0; VPU_API_DEMO_DEBUG_DISABLE = 0;
mpp_log("/******* vpu api demo in *******/\n"); mpp_log("/******* vpu api demo in *******/\n");
if (argc == 1) { if (argc == 1) {
show_usage(); show_usage();
mpp_log("vpu api demo complete directly\n"); mpp_log("vpu api demo complete directly\n");