aboutsummaryrefslogtreecommitdiffstats
path: root/videocodec/OMXVideoDecoderVP8.cpp
diff options
context:
space:
mode:
authorYuanjun Huang <yuanjun.huang@intel.com>2015-07-01 02:41:11 +0800
committerPatrick Tjin <pattjin@google.com>2015-07-01 08:34:37 -0700
commit11c1c17fed35585f9256031ee70db1c6c18d0219 (patch)
tree03775ce24bfe08f6aad7a476f9e1efa6e6271228 /videocodec/OMXVideoDecoderVP8.cpp
parent94dc18063f6f0f60d99feaa0ffb1fc103d49c2c8 (diff)
downloadandroid_hardware_intel_common_omx-components-11c1c17fed35585f9256031ee70db1c6c18d0219.tar.gz
android_hardware_intel_common_omx-components-11c1c17fed35585f9256031ee70db1c6c18d0219.tar.bz2
android_hardware_intel_common_omx-components-11c1c17fed35585f9256031ee70db1c6c18d0219.zip
Revert "omx-component: Adding media resource management support"
Bug: 20165724 A more comprehensive codec level resource manager is implemented. This reverts commit f832fbe64172f3dcde2bf8d7f960375efd8a30d9. Change-Id: Ia45655873c9b7e9d57bed6c8d5dad29e219a2e3c
Diffstat (limited to 'videocodec/OMXVideoDecoderVP8.cpp')
-rw-r--r--videocodec/OMXVideoDecoderVP8.cpp27
1 files changed, 1 insertions, 26 deletions
diff --git a/videocodec/OMXVideoDecoderVP8.cpp b/videocodec/OMXVideoDecoderVP8.cpp
index 1dad3ae..013bf8b 100644
--- a/videocodec/OMXVideoDecoderVP8.cpp
+++ b/videocodec/OMXVideoDecoderVP8.cpp
@@ -22,10 +22,6 @@
// Be sure to have an equal string in VideoDecoderHost.cpp (libmix)
static const char* VP8_MIME_TYPE = "video/x-vnd.on2.vp8";
-// codec number limitation
-#define INSTANCE_LIMITATION 4
-static int gInstanceNumber = 0;
-
OMXVideoDecoderVP8::OMXVideoDecoderVP8() {
LOGV("OMXVideoDecoderVP8 is constructed.");
mVideoDecoder = createVideoDecoder(VP8_MIME_TYPE);
@@ -38,7 +34,6 @@ OMXVideoDecoderVP8::OMXVideoDecoderVP8() {
}
OMXVideoDecoderVP8::~OMXVideoDecoderVP8() {
- gInstanceNumber --;
LOGV("OMXVideoDecoderVP8 is destructed.");
}
@@ -133,26 +128,6 @@ OMX_ERRORTYPE OMXVideoDecoderVP8::SetMaxOutputBufferCount(OMX_PARAM_PORTDEFINITI
p->nBufferCountActual = OUTPORT_NATIVE_BUFFER_COUNT;
return OMXVideoDecoderBase::SetMaxOutputBufferCount(p);
}
+DECLARE_OMX_COMPONENT("OMX.Intel.VideoDecoder.VP8", "video_decoder.vp8", OMXVideoDecoderVP8);
-#define DECLARE_OMX_COMPONENT_VP8(NAME, ROLE, CLASS) \
- static const char *gName = (const char *)(NAME);\
- static const char *gRole = (const char *)(ROLE);\
- OMX_ERRORTYPE CreateInstance(OMX_PTR *instance) {\
- *instance = NULL;\
- if (gInstanceNumber + 1 > INSTANCE_LIMITATION) {\
- return OMX_ErrorInsufficientResources;\
- } else {\
- gInstanceNumber ++;\
- }\
- ComponentBase *inst = new CLASS;\
- if (!inst) {\
- return OMX_ErrorInsufficientResources;\
- }\
- *instance = inst;\
- return OMX_ErrorNone;\
- }\
- struct wrs_omxil_cmodule_ops_s gOps = {CreateInstance};\
- struct wrs_omxil_cmodule_s WRS_OMXIL_CMODULE_SYMBOL = {gName, &gRole, 1, &gOps};
-
-DECLARE_OMX_COMPONENT_VP8("OMX.Intel.VideoDecoder.VP8", "video_decoder.vp8", OMXVideoDecoderVP8);