summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h
diff options
context:
space:
mode:
authorLajos Molnar <lajos@google.com>2013-06-04 19:35:18 -0700
committerLajos Molnar <lajos@google.com>2013-06-05 19:33:33 +0000
commit7f616d3cc5366a4b8af20d3d0c768e3de1df0666 (patch)
tree3e0ec5b23d861c03b8342c114649b1688cbe9909 /media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h
parent50bdb73e04cbdf5a8da647f8830cd88663f20f14 (diff)
downloadframeworks_av-7f616d3cc5366a4b8af20d3d0c768e3de1df0666.zip
frameworks_av-7f616d3cc5366a4b8af20d3d0c768e3de1df0666.tar.gz
frameworks_av-7f616d3cc5366a4b8af20d3d0c768e3de1df0666.tar.bz2
stagefright: created SoftVideoDecoderOMXComponent
Created common base class for all software video decoders to make adding new features easier. Change-Id: Id89964e572d5cc5add02662273e6ae96c6b7eb12 Signed-off-by: Lajos Molnar <lajos@google.com>
Diffstat (limited to 'media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h')
-rw-r--r--media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h31
1 files changed, 7 insertions, 24 deletions
diff --git a/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h b/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h
index f71ccef..de14aaf 100644
--- a/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h
+++ b/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.h
@@ -18,15 +18,18 @@
#define SOFT_MPEG4_H_
-#include "SimpleSoftOMXComponent.h"
-#include <utils/KeyedVector.h>
+#include "SoftVideoDecoderOMXComponent.h"
struct tagvideoDecControls;
namespace android {
-struct SoftMPEG4 : public SimpleSoftOMXComponent {
+struct SoftMPEG4 : public SoftVideoDecoderOMXComponent {
SoftMPEG4(const char *name,
+ const char *componentRole,
+ OMX_VIDEO_CODINGTYPE codingType,
+ const CodecProfileLevel *profileLevels,
+ size_t numProfileLevels,
const OMX_CALLBACKTYPE *callbacks,
OMX_PTR appData,
OMX_COMPONENTTYPE **component);
@@ -34,17 +37,8 @@ struct SoftMPEG4 : public SimpleSoftOMXComponent {
protected:
virtual ~SoftMPEG4();
- virtual OMX_ERRORTYPE internalGetParameter(
- OMX_INDEXTYPE index, OMX_PTR params);
-
- virtual OMX_ERRORTYPE internalSetParameter(
- OMX_INDEXTYPE index, const OMX_PTR params);
-
- virtual OMX_ERRORTYPE getConfig(OMX_INDEXTYPE index, OMX_PTR params);
-
virtual void onQueueFilled(OMX_U32 portIndex);
virtual void onPortFlushCompleted(OMX_U32 portIndex);
- virtual void onPortEnableCompleted(OMX_U32 portIndex, bool enabled);
virtual void onReset();
private:
@@ -56,16 +50,12 @@ private:
enum {
MODE_MPEG4,
MODE_H263,
-
} mMode;
tagvideoDecControls *mHandle;
size_t mInputBufferCount;
- int32_t mWidth, mHeight;
- int32_t mCropLeft, mCropTop, mCropRight, mCropBottom;
-
bool mSignalledError;
bool mInitialized;
bool mFramesConfigured;
@@ -74,16 +64,9 @@ private:
int32_t mPvTime;
KeyedVector<int32_t, OMX_TICKS> mPvToOmxTimeMap;
- enum {
- NONE,
- AWAITING_DISABLED,
- AWAITING_ENABLED
- } mOutputPortSettingsChange;
-
- void initPorts();
status_t initDecoder();
- void updatePortDefinitions();
+ virtual void updatePortDefinitions();
bool portSettingsChanged();
DISALLOW_EVIL_CONSTRUCTORS(SoftMPEG4);