diff options
Diffstat (limited to 'media/omx-plugin')
-rw-r--r-- | media/omx-plugin/OmxPlugin.cpp | 26 | ||||
-rw-r--r-- | media/omx-plugin/lib/ics/libstagefright/moz.build | 15 | ||||
-rw-r--r-- | media/omx-plugin/lib/ics/libutils/moz.build | 7 | ||||
-rw-r--r-- | media/omx-plugin/lib/ics/libvideoeditorplayer/moz.build | 7 | ||||
-rw-r--r-- | media/omx-plugin/moz.build | 33 |
5 files changed, 22 insertions, 66 deletions
diff --git a/media/omx-plugin/OmxPlugin.cpp b/media/omx-plugin/OmxPlugin.cpp index 4b6641c46..ce132b8e2 100644 --- a/media/omx-plugin/OmxPlugin.cpp +++ b/media/omx-plugin/OmxPlugin.cpp @@ -10,11 +10,7 @@ #include <stagefright/MetaData.h> #include <stagefright/OMXCodec.h> #include <media/stagefright/MediaErrors.h> -#ifdef MOZ_WIDGET_GONK -#include <OMX.h> -#else #include <stagefright/OMXClient.h> -#endif #include <algorithm> #include "mozilla/Assertions.h" @@ -125,7 +121,6 @@ public: bool ReadAudio(AudioFrame *aFrame, int64_t aSeekTimeUs); }; -#if !defined(MOZ_WIDGET_GONK) static class OmxClientInstance { public: OmxClientInstance() @@ -156,7 +151,6 @@ private: OMXClient *mClient; status_t mStatus; } sClientInstance; -#endif OmxDecoder::OmxDecoder(PluginHost *aPluginHost, Decoder *aDecoder) : mPluginHost(aPluginHost), @@ -210,16 +204,6 @@ public: } }; -#ifdef MOZ_WIDGET_GONK -static sp<IOMX> sOMX = nullptr; -static sp<IOMX> GetOMX() { - if(sOMX.get() == nullptr) { - sOMX = reinterpret_cast<IOMX*>(new OMX); - } - return sOMX; -} -#endif - static uint32_t GetDefaultStagefrightFlags(PluginHost *aPluginHost) { @@ -246,11 +230,6 @@ GetDefaultStagefrightFlags(PluginHost *aPluginHost) static uint32_t GetVideoCreationFlags(PluginHost* aPluginHost) { -#ifdef MOZ_WIDGET_GONK - // Flag value of zero means return a hardware or software decoder - // depending on what the device supports. - return 0; -#else // Check whether the user has set a pref to override our default OMXCodec // CreationFlags flags. This is useful for A/B testing hardware and software // decoders for performance and bugs. The interesting flag values are: @@ -271,7 +250,6 @@ static uint32_t GetVideoCreationFlags(PluginHost* aPluginHost) flags |= GetDefaultStagefrightFlags(aPluginHost); return static_cast<uint32_t>(flags); -#endif } enum ColorFormatSupport { @@ -481,11 +459,7 @@ bool OmxDecoder::Init() int64_t totalDurationUs = 0; -#ifdef MOZ_WIDGET_GONK - sp<IOMX> omx = GetOMX(); -#else sp<IOMX> omx = sClientInstance.get()->interface(); -#endif sp<MediaSource> videoTrack; sp<MediaSource> videoSource; diff --git a/media/omx-plugin/lib/ics/libstagefright/moz.build b/media/omx-plugin/lib/ics/libstagefright/moz.build index 1fe19a5fd..b156d151e 100644 --- a/media/omx-plugin/lib/ics/libstagefright/moz.build +++ b/media/omx-plugin/lib/ics/libstagefright/moz.build @@ -5,14 +5,13 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. DIST_INSTALL = False -if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'gonk': - SOURCES += [ - 'libstagefright.cpp', - ] - # Some codec-related code uses multi-character constants; allow this. - # XXX: could instead use the FOURCC macro to define these constants. - if CONFIG['GNU_CC'] or CONFIG['CLANG_CL']: - SOURCES['libstagefright.cpp'].flags += ['-Wno-error=multichar'] +SOURCES += [ + 'libstagefright.cpp', +] +# Some codec-related code uses multi-character constants; allow this. +# XXX: could instead use the FOURCC macro to define these constants. +if CONFIG['GNU_CC'] or CONFIG['CLANG_CL']: + SOURCES['libstagefright.cpp'].flags += ['-Wno-error=multichar'] SharedLibrary('stagefright') diff --git a/media/omx-plugin/lib/ics/libutils/moz.build b/media/omx-plugin/lib/ics/libutils/moz.build index efce12194..7fa617fb3 100644 --- a/media/omx-plugin/lib/ics/libutils/moz.build +++ b/media/omx-plugin/lib/ics/libutils/moz.build @@ -5,10 +5,9 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. DIST_INSTALL = False -if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'gonk': - SOURCES += [ - 'libutils.cpp', - ] +SOURCES += [ + 'libutils.cpp', +] SharedLibrary('utils') diff --git a/media/omx-plugin/lib/ics/libvideoeditorplayer/moz.build b/media/omx-plugin/lib/ics/libvideoeditorplayer/moz.build index 4314b1aa2..f05f0f3c9 100644 --- a/media/omx-plugin/lib/ics/libvideoeditorplayer/moz.build +++ b/media/omx-plugin/lib/ics/libvideoeditorplayer/moz.build @@ -5,10 +5,9 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. DIST_INSTALL = False -if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'gonk': - SOURCES += [ - 'libvideoeditorplayer.cpp', - ] +SOURCES += [ + 'libvideoeditorplayer.cpp', +] SharedLibrary('videoeditorplayer') diff --git a/media/omx-plugin/moz.build b/media/omx-plugin/moz.build index 80b8534f2..004a8bdba 100644 --- a/media/omx-plugin/moz.build +++ b/media/omx-plugin/moz.build @@ -20,13 +20,10 @@ SOURCES += [ SharedLibrary('omxplugin') -if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk': - pass -else: - LOCAL_INCLUDES += [ - 'include/ics', - 'include/ics/media/stagefright/openmax', - ] +LOCAL_INCLUDES += [ + 'include/ics', + 'include/ics/media/stagefright/openmax', +] if CONFIG['GNU_CXX']: # Stagefright header files define many multichar constants. @@ -35,23 +32,11 @@ if CONFIG['GNU_CXX']: '-Wno-shadow', ] -if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk': - EXTRA_DSO_LDOPTS += [ - '-lutils', - '-lstagefright', - '-lmedia', - '-lstagefright_omx', - '-lbinder', - '-lui', - '-lhardware', - '-lcutils', - ] -else: - USE_LIBS += [ - '/media/omx-plugin/lib/ics/libstagefright/stagefright', - '/media/omx-plugin/lib/ics/libutils/utils', - 'videoeditorplayer', - ] +USE_LIBS += [ + '/media/omx-plugin/lib/ics/libstagefright/stagefright', + '/media/omx-plugin/lib/ics/libutils/utils', + 'videoeditorplayer', +] # Don't use STL wrappers; this isn't Gecko code DISABLE_STL_WRAPPING = True |