diff options
-rw-r--r-- | videocodec/Android.mk | 3 | ||||
-rw-r--r-- | videocodec/OMXVideoDecoderBase.h | 2 | ||||
-rw-r--r-- | videocodec/OMXVideoDecoderVP9HWR.cpp | 8 | ||||
-rw-r--r-- | videocodec/OMXVideoDecoderVP9Hybrid.cpp | 6 | ||||
-rw-r--r-- | videocodec/OMXVideoEncoderBase.cpp | 8 | ||||
-rw-r--r-- | videocodec/libvpx_internal/libvpx.mk | 8 | ||||
-rw-r--r-- | videocodec/libvpx_internal/libvpx/vp8/decoder/onyxd_if.c | 4 | ||||
-rw-r--r-- | videocodec/libvpx_internal/libvpx/vp8/encoder/pickinter.c | 2 | ||||
-rwxr-xr-x | videocodec/securevideo/moorefield/OMXVideoDecoderAVCSecure.cpp | 2 |
9 files changed, 15 insertions, 28 deletions
diff --git a/videocodec/Android.mk b/videocodec/Android.mk index d3b3366..6a79dd0 100644 --- a/videocodec/Android.mk +++ b/videocodec/Android.mk @@ -227,6 +227,9 @@ LOCAL_CFLAGS += -Werror LOCAL_MODULE_TAGS := optional LOCAL_MODULE := libOMXVideoDecoderVP9Hybrid +# OMXVideoDecoderVP9Hybrid.h hides overloaded virtual function FillRenderBuffer. +LOCAL_CLANG_CFLAGS += -Wno-overloaded-virtual + ifeq ($(TARGET_BOARD_PLATFORM),merrifield) LOCAL_CFLAGS += -DVED_TILING endif diff --git a/videocodec/OMXVideoDecoderBase.h b/videocodec/OMXVideoDecoderBase.h index 49610a7..48706b8 100644 --- a/videocodec/OMXVideoDecoderBase.h +++ b/videocodec/OMXVideoDecoderBase.h @@ -27,7 +27,7 @@ #include "graphics.h" #endif -static const char* VA_VED_RAW_MIME_TYPE = "video/x-raw-vaved"; +static constexpr const char* VA_VED_RAW_MIME_TYPE = "video/x-raw-vaved"; static const uint32_t VA_VED_COLOR_FORMAT = 0x20; diff --git a/videocodec/OMXVideoDecoderVP9HWR.cpp b/videocodec/OMXVideoDecoderVP9HWR.cpp index 2170fd0..4482c37 100644 --- a/videocodec/OMXVideoDecoderVP9HWR.cpp +++ b/videocodec/OMXVideoDecoderVP9HWR.cpp @@ -88,8 +88,6 @@ OMXVideoDecoderVP9HWR::~OMXVideoDecoderVP9HWR() { LOGV("OMXVideoDecoderVP9HWR is destructed."); - unsigned int i = 0; - if (mVADisplay) { vaTerminate(mVADisplay); mVADisplay = NULL; @@ -401,7 +399,6 @@ OMX_ERRORTYPE OMXVideoDecoderVP9HWR::ProcessorProcess( { OMX_ERRORTYPE ret; OMX_BUFFERHEADERTYPE *inBuffer = *pBuffers[INPORT_INDEX]; - OMX_BUFFERHEADERTYPE *outBuffer = *pBuffers[OUTPORT_INDEX]; OMX_BOOL isResolutionChange = OMX_FALSE; if (inBuffer->pBuffer == NULL) { @@ -593,11 +590,6 @@ OMX_ERRORTYPE OMXVideoDecoderVP9HWR::FillRenderBuffer(OMX_BUFFERHEADERTYPE **pBu void *dst = buffer->pBuffer; uint8_t *dst_y = (uint8_t *)dst; - const OMX_PARAM_PORTDEFINITIONTYPE *paramPortDefinitionInput - = this->ports[INPORT_INDEX]->GetPortDefinition(); - - size_t inBufferWidth = paramPortDefinitionInput->format.video.nFrameWidth; - size_t inBufferHeight = paramPortDefinitionInput->format.video.nFrameHeight; const OMX_PARAM_PORTDEFINITIONTYPE *paramPortDefinitionOutput = this->ports[OUTPORT_INDEX]->GetPortDefinition(); diff --git a/videocodec/OMXVideoDecoderVP9Hybrid.cpp b/videocodec/OMXVideoDecoderVP9Hybrid.cpp index cbca17c..55d481a 100644 --- a/videocodec/OMXVideoDecoderVP9Hybrid.cpp +++ b/videocodec/OMXVideoDecoderVP9Hybrid.cpp @@ -201,7 +201,6 @@ OMX_ERRORTYPE OMXVideoDecoderVP9Hybrid::ProcessorFlush(OMX_U32 portIndex) { OMX_ERRORTYPE OMXVideoDecoderVP9Hybrid::ProcessorPreFillBuffer(OMX_BUFFERHEADERTYPE* buffer) { unsigned int handle = (unsigned int)buffer->pBuffer; - unsigned int i = 0; if (buffer->nOutputPortIndex == OUTPORT_INDEX){ mSingalRenderDone(mHybridCtx,handle); @@ -295,11 +294,6 @@ OMX_ERRORTYPE OMXVideoDecoderVP9Hybrid::ProcessorProcess( return ret; } -static int ALIGN(int x, int y) { - // y must be a power of 2. - return (x + y - 1) & ~(y - 1); -} - OMX_ERRORTYPE OMXVideoDecoderVP9Hybrid::FillRenderBuffer(OMX_BUFFERHEADERTYPE **pBuffer, buffer_retain_t *retain, OMX_U32 inportBufferFlags, diff --git a/videocodec/OMXVideoEncoderBase.cpp b/videocodec/OMXVideoEncoderBase.cpp index 5e918c9..37f53d2 100644 --- a/videocodec/OMXVideoEncoderBase.cpp +++ b/videocodec/OMXVideoEncoderBase.cpp @@ -273,17 +273,13 @@ OMX_ERRORTYPE OMXVideoEncoderBase::SetVideoEncoderParam() { Encode_Status ret = ENCODE_SUCCESS; PortVideo *port_in = NULL; - PortVideo *port_out = NULL; - OMX_VIDEO_CONTROLRATETYPE controlrate; const OMX_PARAM_PORTDEFINITIONTYPE *paramPortDefinitionInput = NULL; LOGV("OMXVideoEncoderBase::SetVideoEncoderParam called\n"); port_in = static_cast<PortVideo *>(ports[INPORT_INDEX]); - port_out = static_cast<PortVideo *>(ports[OUTPORT_INDEX]); paramPortDefinitionInput = port_in->GetPortDefinition(); mEncoderParams->resolution.height = paramPortDefinitionInput->format.video.nFrameHeight; mEncoderParams->resolution.width = paramPortDefinitionInput->format.video.nFrameWidth; - const OMX_VIDEO_PARAM_BITRATETYPE *bitrate = port_out->GetPortBitrateParam(); mEncoderParams->frameRate.frameRateDenom = 1; if(mConfigFramerate.xEncodeFramerate != 0) { @@ -362,8 +358,6 @@ OMX_ERRORTYPE OMXVideoEncoderBase::ProcessorInit(void) { } OMX_ERRORTYPE OMXVideoEncoderBase::ProcessorDeinit(void) { - OMX_ERRORTYPE ret; - if(mVideoEncoder) { mVideoEncoder->stop(); } @@ -813,8 +807,6 @@ OMX_ERRORTYPE OMXVideoEncoderBase::SetStoreMetaDataInBuffers(OMX_PTR pStructure) StoreMetaDataInBuffersParams *p = (StoreMetaDataInBuffersParams *)pStructure; VideoParamsStoreMetaDataInBuffers StoreMetaDataInBuffers; PortVideo *port = static_cast<PortVideo *>(this->ports[INPORT_INDEX]); - PortVideo *output_port = static_cast<PortVideo *>(this->ports[OUTPORT_INDEX]); - uint32_t maxSize = 0; CHECK_TYPE_HEADER(p); CHECK_PORT_INDEX(p, INPORT_INDEX); diff --git a/videocodec/libvpx_internal/libvpx.mk b/videocodec/libvpx_internal/libvpx.mk index 461f683..5a95803 100644 --- a/videocodec/libvpx_internal/libvpx.mk +++ b/videocodec/libvpx_internal/libvpx.mk @@ -42,6 +42,14 @@ libvpx_codec_srcs := $(shell cat $(libvpx_config_dir)/libvpx_srcs.txt) LOCAL_SHARED_LIBRARIES += liblog LOCAL_LDLIBS := -L$(SYSROOT)/usr/lib -llog LOCAL_CFLAGS := -DHAVE_CONFIG_H=vpx_config.h + +# Static functions declared in headers. b/18632512 +LOCAL_CFLAGS += -Wno-unused-function + +# Clang complains about every partial initialized structure, +# in vp[89]_[cd]x_iface.c +LOCAL_CLANG_CFLAGS += -Wno-missing-field-initializers + LOCAL_CFLAGS += -Werror LOCAL_MODULE := libvpx_internal diff --git a/videocodec/libvpx_internal/libvpx/vp8/decoder/onyxd_if.c b/videocodec/libvpx_internal/libvpx/vp8/decoder/onyxd_if.c index 8e3deeb..35b541e 100644 --- a/videocodec/libvpx_internal/libvpx/vp8/decoder/onyxd_if.c +++ b/videocodec/libvpx_internal/libvpx/vp8/decoder/onyxd_if.c @@ -313,8 +313,8 @@ int vp8dx_receive_compressed_data(VP8D_COMP *pbi, size_t size, VP8_COMMON *cm = &pbi->common; volatile int retcode; - size = size; // to remove warning - source = source; + (void) size; + (void) source; pbi->common.error.error_code = VPX_CODEC_OK; retcode = check_fragments_for_errors(pbi); diff --git a/videocodec/libvpx_internal/libvpx/vp8/encoder/pickinter.c b/videocodec/libvpx_internal/libvpx/vp8/encoder/pickinter.c index 53c140f..6f09d78 100644 --- a/videocodec/libvpx_internal/libvpx/vp8/encoder/pickinter.c +++ b/videocodec/libvpx_internal/libvpx/vp8/encoder/pickinter.c @@ -55,7 +55,7 @@ int vp8_skip_fractional_mv_step(MACROBLOCK *mb, BLOCK *b, BLOCKD *d, (void) mvcost; (void) distortion; (void) sse; - mb = mb; // remove warning + (void) mb; bestmv->as_mv.row <<= 3; bestmv->as_mv.col <<= 3; return 0; diff --git a/videocodec/securevideo/moorefield/OMXVideoDecoderAVCSecure.cpp b/videocodec/securevideo/moorefield/OMXVideoDecoderAVCSecure.cpp index f976e0b..1e81645 100755 --- a/videocodec/securevideo/moorefield/OMXVideoDecoderAVCSecure.cpp +++ b/videocodec/securevideo/moorefield/OMXVideoDecoderAVCSecure.cpp @@ -147,8 +147,6 @@ OMX_ERRORTYPE OMXVideoDecoderAVCSecure::ProcessorDeinit(void) { } OMX_ERRORTYPE OMXVideoDecoderAVCSecure::ProcessorStart(void) { - uint32_t imrOffset = 0; - uint32_t dataBufferSize = DATA_BUFFER_SIZE; EnableIEDSession(true); uint32_t ret = drm_vendor_api.drm_start_playback(); |