mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 11:41:09 +00:00
include all OMX extension headers if present
The OMX specs defines 8 headers that implementations can use to define their custom extensions. We were checking and including 3 and ignoring the other ones. https://bugzilla.gnome.org/show_bug.cgi?id=792043
This commit is contained in:
parent
13a43757f5
commit
ab181a4335
3 changed files with 89 additions and 1 deletions
35
configure.ac
35
configure.ac
|
@ -264,14 +264,27 @@ dnl Check for external OpenMAX IL headers
|
|||
AC_CHECK_HEADER([OMX_Core.h], [HAVE_EXTERNAL_OMX=yes], [HAVE_EXTERNAL_OMX=no], [AC_INCLUDES_DEFAULT])
|
||||
AM_CONDITIONAL(HAVE_EXTERNAL_OMX, test "x$HAVE_EXTERNAL_OMX" = "xyes")
|
||||
|
||||
dnl Our internal OpenMAX IL headers have OMX_VideoExt.h, OMX_IndexExt.h and OMX_ComponentExt.h
|
||||
dnl OMX defines 8 header files to contain extensions:
|
||||
dnl OMX_VideoExt.h, OMX_IndexExt.h, OMX_ComponentExt.h, OMX_CoreExt.h
|
||||
dnl OMX_AudioExt.h, OMX_IVCommonExt.h, OMX_ImageExt.h, OMX_OtherExt.h
|
||||
dnl The first 4 are present in our internal OpenMAX IL, the latter are not
|
||||
HAVE_VIDEO_EXT=yes
|
||||
HAVE_INDEX_EXT=yes
|
||||
HAVE_COMPONENT_EXT=yes
|
||||
HAVE_CORE_EXT=yes
|
||||
HAVE_AUDIO_EXT=no
|
||||
HAVE_IV_COMMON_EXT=no
|
||||
HAVE_IMAGE_EXT=no
|
||||
HAVE_OTHER_EXT=no
|
||||
if test "x$HAVE_EXTERNAL_OMX" = "xyes"; then
|
||||
AC_CHECK_HEADER([OMX_VideoExt.h], [HAVE_VIDEO_EXT=yes], [HAVE_VIDEO_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
AC_CHECK_HEADER([OMX_IndexExt.h], [HAVE_INDEX_EXT=yes], [HAVE_INDEX_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
AC_CHECK_HEADER([OMX_ComponentExt.h], [HAVE_COMPONENT_EXT=yes], [HAVE_COMPONENT_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
AC_CHECK_HEADER([OMX_CoreExt.h], [HAVE_CORE_EXT=yes], [HAVE_CORE_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
AC_CHECK_HEADER([OMX_AudioExt.h], [HAVE_AUDIO_EXT=yes], [HAVE_AUDIO_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
AC_CHECK_HEADER([OMX_IVCommonExt.h], [HAVE_IV_COMMON_EXT=yes], [HAVE_IV_COMMON_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
AC_CHECK_HEADER([OMX_ImageExt.h], [HAVE_IMAGE_EXT=yes], [HAVE_IMAGE_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
AC_CHECK_HEADER([OMX_OtherExt.h], [HAVE_OTHER_EXT=yes], [HAVE_OTHER_EXT=no], [AC_INCLUDES_DEFAULT])
|
||||
fi
|
||||
|
||||
VIDEO_HEADERS="#include <OMX_Video.h>"
|
||||
|
@ -290,6 +303,26 @@ if test "x$HAVE_COMPONENT_EXT" = "xyes"; then
|
|||
AC_DEFINE(HAVE_COMPONENT_EXT, 1, [OpenMAX IL has OMX_ComponentExt.h header])
|
||||
fi
|
||||
|
||||
if test "x$HAVE_CORE_EXT" = "xyes"; then
|
||||
AC_DEFINE(HAVE_CORE_EXT, 1, [OpenMAX IL has OMX_CoreExt.h header])
|
||||
fi
|
||||
|
||||
if test "x$HAVE_AUDIO_EXT" = "xyes"; then
|
||||
AC_DEFINE(HAVE_AUDIO_EXT, 1, [OpenMAX IL has OMX_AudioExt.h header])
|
||||
fi
|
||||
|
||||
if test "x$HAVE_IV_COMMON_EXT" = "xyes"; then
|
||||
AC_DEFINE(HAVE_IV_COMMON_EXT, 1, [OpenMAX IL has OMX_IVCommonExt.h header])
|
||||
fi
|
||||
|
||||
if test "x$HAVE_IMAGE_EXT" = "xyes"; then
|
||||
AC_DEFINE(HAVE_IMAGE_EXT, 1, [OpenMAX IL has OMX_ImageExt.h header])
|
||||
fi
|
||||
|
||||
if test "x$HAVE_OTHER_EXT" = "xyes"; then
|
||||
AC_DEFINE(HAVE_OTHER_EXT, 1, [OpenMAX IL has OMX_OtherExt.h header])
|
||||
fi
|
||||
|
||||
AC_CHECK_DECLS([OMX_VIDEO_CodingVP8],
|
||||
[
|
||||
AC_DEFINE(HAVE_VP8, 1, [OpenMAX IL has VP8 support])
|
||||
|
|
35
meson.build
35
meson.build
|
@ -251,6 +251,41 @@ if cc.has_header (
|
|||
cdata.set ('HAVE_COMPONENT_EXT', 1)
|
||||
endif
|
||||
|
||||
if cc.has_header (
|
||||
'OMX_CoreExt.h',
|
||||
args : gst_omx_args,
|
||||
required : false)
|
||||
cdata.set ('HAVE_CORE_EXT', 1)
|
||||
endif
|
||||
|
||||
if cc.has_header (
|
||||
'OMX_AudioExt.h',
|
||||
args : gst_omx_args,
|
||||
required : false)
|
||||
cdata.set ('HAVE_AUDIO_EXT', 1)
|
||||
endif
|
||||
|
||||
if cc.has_header (
|
||||
'OMX_IVCommonExt.h',
|
||||
args : gst_omx_args,
|
||||
required : false)
|
||||
cdata.set ('HAVE_IV_COMMON_EXT', 1)
|
||||
endif
|
||||
|
||||
if cc.has_header (
|
||||
'OMX_ImageExt.h',
|
||||
args : gst_omx_args,
|
||||
required : false)
|
||||
cdata.set ('HAVE_IMAGE_EXT', 1)
|
||||
endif
|
||||
|
||||
if cc.has_header (
|
||||
'OMX_OtherExt.h',
|
||||
args : gst_omx_args,
|
||||
required : false)
|
||||
cdata.set ('HAVE_OTHER_EXT', 1)
|
||||
endif
|
||||
|
||||
have_omx_vp8 = cc.has_header_symbol(
|
||||
'OMX_Video.h',
|
||||
'OMX_VIDEO_CodingVP8',
|
||||
|
|
20
omx/gstomx.h
20
omx/gstomx.h
|
@ -70,6 +70,26 @@
|
|||
#include <OMX_ComponentExt.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_CORE_EXT
|
||||
#include <OMX_CoreExt.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_AUDIO_EXT
|
||||
#include <OMX_AudioExt.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_IV_COMMON_EXT
|
||||
#include <OMX_IVCommonExt.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_IMAGE_EXT
|
||||
#include <OMX_ImageExt.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_OTHER_EXT
|
||||
#include <OMX_OtherExt.h>
|
||||
#endif
|
||||
|
||||
#ifdef GST_OMX_STRUCT_PACKING
|
||||
#pragma pack()
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue