From: Gilbok Lee Date: Mon, 6 Jan 2025 02:02:21 +0000 (+0900) Subject: Merge branch 'upstream/1.24.10' into tizen_gst_1.24.10 X-Git-Tag: accepted/tizen/unified/20250113.094344~3^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c6e710201e50919df457575870af83cd698a3281;p=platform%2Fupstream%2Fgstreamer.git Merge branch 'upstream/1.24.10' into tizen_gst_1.24.10 Change-Id: I913bfe3f95a197a96283ab35506a437d04871357 --- c6e710201e50919df457575870af83cd698a3281 diff --cc meson_options.txt index 50ad357afa,5354a0f8bc..65915171db --- a/meson_options.txt +++ b/meson_options.txt @@@ -3,11 -3,10 +3,10 @@@ option('base', type : 'feature', value option('good', type : 'feature', value : 'enabled') option('ugly', type : 'feature', value : 'enabled') option('bad', type : 'feature', value : 'enabled') -option('libav', type : 'feature', value : 'auto') +option('libav', type : 'feature', value : 'enabled') option('devtools', type : 'feature', value : 'auto') -option('ges', type : 'feature', value : 'auto') -option('rtsp_server', type : 'feature', value : 'auto') +option('ges', type : 'feature', value : 'enabled') +option('rtsp_server', type : 'feature', value : 'enabled') - option('omx', type : 'feature', value : 'enabled') option('rs', type : 'feature', value : 'disabled') option('vaapi', type : 'feature', value : 'disabled') option('gst-examples', type : 'feature', value : 'auto', description : 'Build gst-examples subproject') diff --cc packaging/gstreamer.spec index 70c9616fc8,0000000000..dd26ce13da mode 100644,000000..100644 --- a/packaging/gstreamer.spec +++ b/packaging/gstreamer.spec @@@ -1,1331 -1,0 +1,1258 @@@ +%bcond_with x +%bcond_with wayland + +%define gst_branch 1.0 +%define _lib_gstreamer_dir %{_libdir}/gstreamer-%{gst_branch} +%define _lib_girepository %{_libdir}/girepository-%{gst_branch} +%define _enable_v4l2h264enc 0 +%define _enable_introspection 0 + +####################################################################### +## how to build each plugin : +## add define option at gbs build cmd like [ --define "plugin bad" ] +## if not, all the source code in subprojects will be built +####################################################################### + +%if 0%{?plugin:1} + %if "%{plugin}" == "core" + %define _name gstreamer + %define _core_opt "" + %endif + %if "%{plugin}" == "base" || "%{plugin}" == "good" || "%{plugin}" == "bad" || "%{plugin}" == "ugly" + %define _name gst-plugins-%{plugin} + %define _base_opt "" + %define _good_opt "" + %define _bad_opt "" + %define _ugly_opt "" + %endif - %if "%{plugin}" == "omx" || "%{plugin}" == "libav" ++ %if "%{plugin}" == "libav" + %define _name gst-%{plugin} - %define _omx_opt "" + %define _libav_opt "" + %endif + %if "%{plugin}" == "rs" + %define _name gst-rtsp-server + %define _rs_opt "" + %endif + %if "%{plugin}" == "es" + %define _name gst-editing-services + %define _es_opt "" + %endif + + %define _source_path subprojects/%{_name} + +%else + + %define plugin all + %define _name gstreamer + %define _source_path . + + # plugin option prefix + %define _core_opt gstreamer: + %define _base_opt gst-plugins-base: + %define _good_opt gst-plugins-good: + %define _bad_opt gst-plugins-bad: + %define _ugly_opt gst-plugins-ugly: - %define _omx_opt gst-omx: + %define _libav_opt gst-libav: + %define _rs_opt gst-rtsp-server: + %define _es_opt gst-editing-services: + +%endif + +Name: %{_name} - Version: 1.24.9 ++Version: 1.24.10 +Release: 0 +Summary: Streaming-Media Framework Runtime +License: LGPL-2.0+ +Group: Multimedia/Framework +Url: http://gstreamer.freedesktop.org/ +Source0: gstreamer-%{version}.tar.gz +Source1001: gstreamer.manifest +BuildRequires: meson >= 0.62.0 +BuildRequires: gettext-tools +BuildRequires: pkgconfig(glib-2.0) >= 2.32.0 + + +%if "%{plugin}" == "all" || "%{plugin}" == "core" + +BuildRequires: bison +BuildRequires: fdupes +BuildRequires: flex +BuildRequires: libtool +BuildRequires: pkgconfig(dlog) +%if "%{_enable_introspection}" == "1" +BuildRequires: pkgconfig(gobject-introspection-1.0) >= 1.31.1 +%endif +BuildRequires: pkgconfig(libxml-2.0) + +%description -n gstreamer +GStreamer is a streaming-media framework, based on graphs of filters +which operate on media data. Applications using this library can do +anything from real-time sound processing to playing videos, and just +about anything else media-related. Its plug-in-based architecture +means that new data types or processing capabilities can be added by +installing new plug-ins. + +%package -n gstreamer-utils +Summary: Streaming-Media Framework Runtime +Group: Multimedia/Framework +Provides: gstreamer:%{_bindir}/gst-launch-%{gst_branch} = %{version} +# Symbol for unversioned wrappers: +Provides: gstreamer-utils_versioned = %{version} + +%description -n gstreamer-utils +GStreamer is a streaming-media framework, based on graphs of filters +which operate on media data. Applications using this library can do +anything from real-time sound processing to playing videos, and just +about anything else media-related. Its plug-in-based architecture +means that new data types or processing capabilities can be added by +installing new plug-ins. + +%package -n gstreamer-devel +Summary: Include Files and Libraries mandatory for Development +Group: Development/Libraries +# gstreamer-utils is required for the gstreamer-provides rpm magic. +Requires: gstreamer-utils = %{version} +Requires: gstreamer = %{version} + +%description -n gstreamer-devel +This package contains all necessary include files and libraries needed +to develop applications that require these. + +%else + +BuildRequires: pkgconfig(gstreamer-1.0) + +%if "%{plugin}" != "base" +BuildRequires: pkgconfig(gstreamer-plugins-base-1.0) +%endif + +%endif + +####################################################### +## Package info of Base Plugin +####################################################### + +%if "%{plugin}" == "all" +%package -n gst-plugins-base +Summary: GStreamer Streaming-Media Framework Plug-Ins +Group: Multimedia/Framework +%endif + +%if "%{plugin}" == "all" || "%{plugin}" == "base" + +BuildRequires: orc >= 0.4.16 +BuildRequires: python +BuildRequires: pkgconfig(alsa) >= 0.9.1 +BuildRequires: pkgconfig(freetype2) >= 2.0.9 +BuildRequires: pkgconfig(libdrm) +BuildRequires: pkgconfig(libtbm) +BuildRequires: pkgconfig(libxml-2.0) +BuildRequires: pkgconfig(ogg) >= 1.0 +BuildRequires: pkgconfig(opus) +BuildRequires: pkgconfig(theoradec) >= 1.1 +BuildRequires: pkgconfig(theoraenc) >= 1.1 +BuildRequires: pkgconfig(vorbis) >= 1.0 +BuildRequires: pkgconfig(vorbisenc) >= 1.0 +BuildRequires: pkgconfig(zlib) +%if "%{_enable_introspection}" == "1" +BuildRequires: pkgconfig(gobject-introspection-1.0) >= 1.31.1 +%endif +%if "%{tizen_profile_name}" != "tv" +BuildRequires: update-desktop-files +%endif +%if %{with wayland} +%if 0%{?enable_gl:1} +BuildRequires: pkgconfig(gles20) +BuildRequires: pkgconfig(wayland-egl) >= 9.0 +%endif # wayland +%endif # gl +%if %{with x} +BuildRequires: pkgconfig(dri2proto) +BuildRequires: pkgconfig(libdri2) +BuildRequires: pkgconfig(ice) +BuildRequires: pkgconfig(sm) +BuildRequires: pkgconfig(xext) +BuildRequires: pkgconfig(xv) +BuildRequires: pkgconfig(xfixes) +%endif +# gstreamer-utils is required for the gstreamer-provides rpm magic. +Requires: gstreamer >= 1.0.0 +Requires: opus +Supplements: gstreamer + +%description -n gst-plugins-base +GStreamer is a streaming media framework based on graphs of filters +that operate on media data. Applications using this library can do +anything media-related, from real-time sound processing to playing +videos. Its plug-in-based architecture means that new data types or +processing capabilities can be added simply by installing new plug-ins. + +%if "%{tizen_profile_name}" != "tv" +%package -n gst-plugins-base-extension-adder +Summary: libgstadder.so for gst-plugins-base +Requires: gst-plugins-base = %{version}-%{release} +Provides: gst-plugins-base-profile_mobile = %{version}-%{release} + +%description -n gst-plugins-base-extension-adder +Libgstadder.so for gst-plugin-base. Supplicant for gst-plugin-base. +This is for Tizen mobile profile. +%endif + +%package -n gst-plugins-base-devel +Summary: Include files and Libraries +Requires: gst-plugins-base = %{version} + +%description -n gst-plugins-base-devel +This package contains all necessary include files and libraries needed +to compile and link applications that use gstreamer-plugins-base. + +%endif + +####################################################### +## Package info of Good Plugin +####################################################### + +%if "%{plugin}" == "all" +%package -n gst-plugins-good +Summary: GStreamer Streaming-Media Framework Plug-Ins +Group: Multimedia/Framework +%endif + +%if "%{plugin}" == "all" || "%{plugin}" == "good" + +BuildRequires: libjpeg-devel +BuildRequires: orc >= 0.4.16 +BuildRequires: python +BuildRequires: xsltproc +BuildRequires: pkgconfig(bzip2) +BuildRequires: pkgconfig(gio-2.0) +BuildRequires: pkgconfig(libpulse) >= 1.0 +BuildRequires: pkgconfig(libsoup-2.4) +BuildRequires: pkgconfig(libtbm) +BuildRequires: pkgconfig(libxml-2.0) >= 2.4.9 +BuildRequires: pkgconfig(vconf) +BuildRequires: pkgconfig(vpx) +BuildRequires: pkgconfig(zlib) +BuildRequires: pkgconfig(opencore-amrwb) +%if "%{tizen_profile_name}" != "tv" +BuildRequires: pkgconfig(opencore-amrnb) +BuildRequires: pkgconfig(libpng) >= 1.2 +%endif +%if %{with x} +BuildRequires: pkgconfig(ice) +BuildRequires: pkgconfig(sm) +BuildRequires: pkgconfig(xdamage) +BuildRequires: pkgconfig(xfixes) +# used by libgstvideo4linux2.so +BuildRequires: pkgconfig(xv) +%endif +Requires: gstreamer >= %{version} +Requires: gst-plugins-base >= %{version} +Requires: libsoup + +%description -n gst-plugins-good +GStreamer is a streaming media framework based on graphs of filters +that operate on media data. Applications using this library can do +anything media-related, from real-time sound processing to playing +videos. Its plug-in-based architecture means that new data types or +processing capabilities can be added simply by installing new plug-ins. + +%package -n gst-plugins-good-extra +Summary: Complementary plugins for gst-plugins-good +Group: Productivity/Multimedia/Other +Requires: gst-plugins-good = %{version} +Enhances: gst-plugins-good + +%description -n gst-plugins-good-extra +This package provides complementary plugins for gst-plugins-good and +plugins not included in official Tizen images, which may be used for development / experimental purposes. + +%if "%{tizen_profile_name}" != "tv" +%package -n gst-plugins-good-cairo +Summary: Cairo plugin for gst-plugins-good +Group: Multimedia/Framework +BuildRequires: pkgconfig(cairo) +BuildRequires: pkgconfig(cairo-gobject) +Requires: gst-plugins-good = %{version} +Enhances: gst-plugins-good + +%description -n gst-plugins-good-cairo +This package provides cairo plugin for gst-plugins-good and +this is not included in Tizen headless image. + +%package -n gst-plugins-good-v4l2 +Summary: Video4Linux2 plugin for gst-plugins-good +Group: Multimedia/Framework +BuildRequires: pkgconfig(libv4l2) +Requires: gst-plugins-good = %{version} +Enhances: gst-plugins-good + +%description -n gst-plugins-good-v4l2 +This package provides Video4Linux2 plugin for gst-plugins-good. +%endif + +%endif + +####################################################### +## Package info of Bad Plugin +####################################################### + +%if "%{plugin}" == "all" +%package -n gst-plugins-bad +Summary: GStreamer Streaming-Media Framework Plug-Ins +Group: Multimedia/Framework +%endif + +%if "%{plugin}" == "all" || "%{plugin}" == "bad" + +BuildRequires: python +BuildRequires: xsltproc +BuildRequires: pkgconfig(gio-2.0) >= 2.25.0 +BuildRequires: pkgconfig(libcurl) >= 7.21.0 +BuildRequires: pkgconfig(libexif) >= 0.6.16 +BuildRequires: pkgconfig(libsrtp2) >= 2.1.0 +BuildRequires: pkgconfig(libusb-1.0) +BuildRequires: pkgconfig(nice) +BuildRequires: pkgconfig(openal) +BuildRequires: pkgconfig(openssl1.1) +BuildRequires: pkgconfig(opus) +BuildRequires: pkgconfig(orc-0.4) >= 0.4.11 +BuildRequires: pkgconfig(sndfile) >= 1.0.16 +BuildRequires: pkgconfig(soundtouch) > 1.4 +%if "%{tizen_profile_name}" != "tv" +BuildRequires: pkgconfig(srt) +%endif +%if %{with wayland} +BuildRequires: pkgconfig(libdrm) +BuildRequires: pkgconfig(libxml-2.0) +BuildRequires: pkgconfig(wayland-client) >= 1.0.0 +BuildRequires: pkgconfig(wayland-cursor) >= 1.0.0 +BuildRequires: pkgconfig(wayland-protocols) +%endif +%if %{with x} +BuildRequires: pkgconfig(x11) +%endif +Requires: gstreamer >= %{version} + +%description -n gst-plugins-bad +GStreamer is a streaming media framework based on graphs of filters +that operate on media data. Applications using this library can do +anything media-related,from real-time sound processing to playing +videos. Its plug-in-based architecture means that new data types or +processing capabilities can be added simply by installing new plug-ins. + +%package -n gst-plugins-bad-devel +Summary: GStreamer Streaming-Media Framework Plug-Ins +Requires: gst-plugins-bad = %{version}-%{release} +Requires: gst-plugins-base-devel + +%description -n gst-plugins-bad-devel +GStreamer is a streaming media framework based on graphs of filters +that operate on media data. Applications using this library can do +anything media-related,from real-time sound processing to playing +videos. Its plug-in-based architecture means that new data types or +processing capabilities can be added simply by installing new plug-ins. + +%endif + +####################################################### +## Package info of Ugly Plugin +####################################################### + +%if "%{plugin}" == "all" +%package -n gst-plugins-ugly +Summary: GStreamer plugins from the "ugly" set +Group: Multimedia/Framework +%endif + +%if "%{plugin}" == "all" || "%{plugin}" == "ugly" + +BuildRequires: which + +%description -n gst-plugins-ugly + GStreamer is a streaming media framework, based on graphs of filters + which operate on media data. Applications using this library can do + anything from real-time sound processing to playing videos, and just + about anything else media-related. Its plugin-based architecture means + that new data types or processing capabilities can be added simply by + installing new plug-ins. + . + This packages contains plugins from the "ugly" set, a set of + good-quality plug-ins that might pose distribution problems. + +%endif + - ####################################################### - ## Package info of Omx Plugin - ####################################################### - - %if "%{tizen_profile_name}" != "tv" - %ifarch %{arm} aarch64 riscv64 - - %if "%{plugin}" == "all" - %package -n gst-omx - Summary: GStreamer plug-in that allows communication with OpenMAX IL components - Group: Multimedia/Framework - %endif - - %if "%{plugin}" == "all" || "%{plugin}" == "omx" - - BuildRequires: which - BuildRequires: pkgconfig(libtbm) - BuildRequires: pkgconfig(mm-common) - %if "%{target}" == "rpi" - BuildRequires: pkgconfig(bcm_host) - BuildRequires: pkgconfig(brcmegl) - %endif - - %description -n gst-omx - gst-openmax is a GStreamer plug-in that allows communication with OpenMAX IL components. - Multiple OpenMAX IL implementations can be used. - - %endif # plugin - %endif # arch - %endif # profile - +####################################################### +## Package info of libav Plugin +####################################################### + +%if "%{plugin}" == "all" +%package -n gst-libav +Summary: Libav plugin for GStreamer +Group: Multimedia/Framework +%endif + +%if "%{plugin}" == "all" || "%{plugin}" == "libav" + +BuildRequires: bzip2-devel +BuildRequires: gettext +BuildRequires: which +BuildRequires: yasm +BuildRequires: pkgconfig(libavcodec) +BuildRequires: pkgconfig(libavfilter) +BuildRequires: pkgconfig(libavformat) +BuildRequires: pkgconfig(libavutil) +BuildRequires: pkgconfig(orc-0.4) +BuildRequires: pkgconfig(theora) +BuildRequires: pkgconfig(vorbis) +BuildRequires: pkgconfig(zlib) + +%description -n gst-libav +This GStreamer plugin supports a large number of audio and video compression +formats through the use of the libav library. The plugin contains GStreamer +elements for decoding 90+ formats (AVI, MPEG, OGG, Matroska, ASF, ...), +demuxing 30+ formats and colorspace conversion. + +%endif + +####################################################### +## Package info of rtsp-server Plugin +####################################################### + +%if "%{plugin}" == "all" +%package -n gst-rtsp-server +Summary: Multimedia Framework Library +Group: System/Libraries +%endif + +%if "%{plugin}" == "all" || "%{plugin}" == "rs" + +Requires(post): /sbin/ldconfig +Requires(postun): /sbin/ldconfig + +%description -n gst-rtsp-server +This GStreamer plugin supports a large number of audio and video compression +formats through the use of the libav library. The plugin contains GStreamer +elements for decoding 90+ formats (AVI, MPEG, OGG, Matroska, ASF, ...), +demuxing 30+ formats and colorspace conversion. + +%package -n gst-rtsp-server-devel +Summary: Multimedia Framework RTSP server library (DEV) +Group: Development/Libraries +Requires: gst-rtsp-server = %{version}-%{release} + +%description -n gst-rtsp-server-devel + +%endif + +####################################################### +## Package info of editing-services Plugin +####################################################### + +%if "%{tizen_profile_name}" != "tv" + +%if "%{plugin}" == "all" +%package -n gst-editing-services +Summary: GStreamer Editing Service Plug-Ins +Group: Multimedia/Framework +%endif + +%if "%{plugin}" == "all" || "%{plugin}" == "es" + +BuildRequires: flex +BuildRequires: gtk-doc +BuildRequires: pkgconfig(libxml-2.0) +Requires: gstreamer >= 1.0.0 +Supplements: gstreamer + +%description -n gst-editing-services +This is a high-level library for facilitating the creation of audio/video +non-linear editors. + +%package -n gst-editing-services-devel +Summary: Development files for gst-editing-services +Requires: gst-editing-services = %{version}-%{release} + +%description -n gst-editing-services-devel +This package contains libraries and header files for +developing applications that use %{name} + +%endif # plugin + +%endif # profile + +####################################################### +## Prep +####################################################### + +%prep +%setup -q -n gstreamer-%{version} +cp %{SOURCE1001} ./gstreamer.manifest +cp %{SOURCE1001} ./gst-plugins-base.manifest +cp %{SOURCE1001} ./gst-plugins-good.manifest +cp %{SOURCE1001} ./gst-plugins-bad.manifest +cp %{SOURCE1001} ./gst-plugins-ugly.manifest +cp %{SOURCE1001} ./gst-libav.manifest +cp %{SOURCE1001} ./gst-rtsp-server.manifest +%if "%{tizen_profile_name}" != "tv" - cp %{SOURCE1001} ./gst-omx.manifest +cp %{SOURCE1001} ./gst-editing-services.manifest +%endif + +####################################################### +## Build +####################################################### + +%build + +%if "%{plugin}" != "all" +pushd %{_source_path} +%endif + +mkdir -p build +export CFLAGS="%{optflags} \ + -fno-strict-aliasing\ + -fstack-protector-strong\ + -Wl,-z,relro\ +%if "%{tizen_profile_name}" == "tv" + -Wno-declaration-after-statement\ +%endif + -D_FORTIFY_SOURCE=2" +export CXXFLAGS+=" -Wno-error" +export LDFLAGS+=" -pthread" + +meson --auto-features=disabled --prefix=/usr --libdir=%{_libdir} --datadir=%{_datadir} --sysconfdir=%{_hal_sysconfdir} \ +%if "%{plugin}" == "all" + %if "%{tizen_profile_name}" == "tv" + -D ges=disabled \ - -D omx=disabled \ + %endif # profile - %ifarch x86_64 %{ix86} - -D omx=disabled \ - %endif # arch + -D webrtc=enabled \ +%endif # plugin +%if "%{plugin}" == "all" || "%{plugin}" == "core" + -D %{_core_opt}check=enabled \ + -D %{_core_opt}coretracers=enabled \ + -D %{_core_opt}extra-checks=enabled \ + -D %{_core_opt}tools=enabled \ + %if "%{tizen_profile_name}" == "tv" + -D %{_core_opt}tv-profile=true \ + %endif # profile + %if "%{_enable_introspection}" == "1" + -D %{_core_opt}introspection=enabled \ + %endif # introspection +%endif # plugin +%if "%{plugin}" == "all" || "%{plugin}" == "base" + -D %{_base_opt}alsa=enabled \ + -D %{_base_opt}app=enabled \ + -D %{_base_opt}audioconvert=enabled \ + -D %{_base_opt}audiomixer=enabled \ + -D %{_base_opt}audiorate=enabled \ + -D %{_base_opt}audioresample=enabled \ + -D %{_base_opt}audiotestsrc=enabled \ + -D %{_base_opt}compositor=enabled \ + -D %{_base_opt}gio=enabled \ + -D %{_base_opt}gio-typefinder=enabled \ + -D %{_base_opt}ogg=enabled \ + -D %{_base_opt}opus=enabled \ + -D %{_base_opt}overlaycomposition=enabled \ + -D %{_base_opt}pbtypes=enabled \ + -D %{_base_opt}playback=enabled \ + -D %{_base_opt}rawparse=enabled \ + -D %{_base_opt}subparse=enabled \ + -D %{_base_opt}tbm=true \ + -D %{_base_opt}tcp=enabled \ + -D %{_base_opt}tools=disabled \ + -D %{_base_opt}theora=enabled \ + -D %{_base_opt}typefind=enabled \ + -D %{_base_opt}videoconvertscale=enabled \ + -D %{_base_opt}videorate=enabled \ + -D %{_base_opt}videotestsrc=enabled \ + -D %{_base_opt}volume=enabled \ + -D %{_base_opt}vorbis=enabled \ + %if "%{tizen_profile_name}" == "tv" + -D %{_base_opt}tv-profile=true \ + %else + -D %{_base_opt}adder=enabled \ + -D %{_base_opt}encoding=enabled \ + %if 0%{?enable_gl:1} + -D %{_base_opt}gl=enabled \ + %endif # gl + %endif # profile + %if "%{_enable_introspection}" == "1" + -D %{_base_opt}introspection=enabled \ + %endif # introspection +%endif # base plugin +%if "%{plugin}" == "all" || "%{plugin}" == "good" + %if 0%{?ENABLE_AALIB} + -D %{_good_opt}aalib=enabled \ + %endif + -D %{_good_opt}adaptivedemux2=enabled \ + -D %{_good_opt}amrwbdec=enabled \ + -D %{_good_opt}apetag=enabled \ + -D %{_good_opt}audiofx=enabled \ + -D %{_good_opt}audioparsers=enabled \ + -D %{_good_opt}autodetect=enabled \ + -D %{_good_opt}avi=enabled \ + -D %{_good_opt}debugutils=enabled \ + -D %{_good_opt}deinterlace=enabled \ + -D %{_good_opt}icydemux=enabled \ + -D %{_good_opt}id3demux=enabled \ + -D %{_good_opt}interleave=enabled \ + -D %{_good_opt}isomp4=enabled \ + -D %{_good_opt}jpeg=enabled \ + -D %{_good_opt}law=enabled \ + -D %{_good_opt}pulse=enabled \ + -D %{_good_opt}replaygain=enabled \ + -D %{_good_opt}rtp=enabled \ + -D %{_good_opt}rtpmanager=enabled \ + -D %{_good_opt}rtsp=enabled \ + -D %{_good_opt}soup=enabled \ + -D %{_good_opt}tbm=true \ + -D %{_good_opt}udp=enabled \ + -D %{_good_opt}videocrop=enabled \ + -D %{_good_opt}videofilter=enabled \ + -D %{_good_opt}vpx=enabled \ + -D %{_good_opt}wavenc=enabled \ + -D %{_good_opt}wavparse=enabled \ + %if "%{_enable_v4l2h264enc}" == "1" + -D %{_good_opt}v4l2h264enc=enabled \ + %endif + %if "%{tizen_profile_name}" == "tv" + -D %{_good_opt}tv-profile=true \ + %ifnarch %{arm} aarch64 + -D %{_good_opt}v4l2=enabled \ + %endif + %else + -D %{_good_opt}amrnb=enabled \ + -D %{_good_opt}cairo=enabled \ + -D %{_good_opt}effectv=enabled \ + -D %{_good_opt}flv=enabled \ + -D %{_good_opt}imagefreeze=enabled \ + -D %{_good_opt}matroska=enabled \ + -D %{_good_opt}multifile=enabled \ + -D %{_good_opt}png=enabled \ + -D %{_good_opt}smpte=enabled \ + -D %{_good_opt}v4l2=enabled \ + -D %{_good_opt}v4l2-libv4l2=enabled \ + -D %{_good_opt}v4l2-probe=true \ + -D %{_good_opt}videobox=enabled \ + -D %{_good_opt}videomixer=enabled \ + %endif # profile +%endif # plugin +%if "%{plugin}" == "all" || "%{plugin}" == "bad" + -D %{_bad_opt}aes=enabled \ + -D %{_bad_opt}audiobuffersplit=enabled \ + -D %{_bad_opt}audiolatency=enabled \ + -D %{_bad_opt}audiomixmatrix=enabled \ + -D %{_bad_opt}debugutils=enabled \ + -D %{_bad_opt}dtls=enabled \ + -D %{_bad_opt}gst_play_tests=false\ + -D %{_bad_opt}introspection=disabled \ + -D %{_bad_opt}ipcpipeline=enabled \ + -D %{_bad_opt}midi=enabled \ + -D %{_bad_opt}mpegtsdemux=enabled \ + -D %{_bad_opt}mpegtsmux=enabled \ + -D %{_bad_opt}netsim=enabled \ + -D %{_bad_opt}openal=enabled \ + -D %{_bad_opt}opus=enabled \ + -D %{_bad_opt}proxy=enabled \ + -D %{_bad_opt}sctp=enabled \ + -D %{_bad_opt}sdp=enabled \ + -D %{_bad_opt}shm=enabled \ + -D %{_bad_opt}soundtouch=enabled \ + -D %{_bad_opt}srtp=enabled \ + -D %{_bad_opt}timecode=enabled \ + -D %{_bad_opt}videoframe_audiolevel=enabled \ + -D %{_bad_opt}videoparsers=enabled \ + -D %{_bad_opt}webrtc=enabled \ + %if %{with wayland} + -D %{_bad_opt}wayland=enabled \ + %endif + %if "%{tizen_profile_name}" == "tv" + -D %{_bad_opt}tv-profile=true \ + %else + -D %{_bad_opt}autoconvert=enabled \ + -D %{_bad_opt}camerabin2=enabled \ + -D %{_bad_opt}coloreffects=enabled \ + -D %{_bad_opt}dash=enabled \ + -D %{_bad_opt}gaudieffects=enabled \ + -D %{_bad_opt}gdp=enabled \ + -D %{_bad_opt}hls=enabled \ + -D %{_bad_opt}id3tag=enabled \ + -D %{_bad_opt}jpegformat=enabled \ + -D %{_bad_opt}mpegdemux=enabled \ + -D %{_bad_opt}rist=enabled \ + -D %{_bad_opt}rtp=enabled \ + -D %{_bad_opt}srt=enabled \ + -D %{_bad_opt}smoothstreaming=enabled \ + %if 0%{?enable_gl:1} + -D %{_bad_opt}gl=enabled \ + %endif # gl + %endif # profile +%endif # plugin +%if "%{plugin}" == "all" || "%{plugin}" == "ugly" + %if "%{tizen_profile_name}" == "tv" + -D %{_ugly_opt}tv-profile=true \ + %else + -D %{_ugly_opt}asfdemux=enabled \ + %endif # profile +%endif # plugin +%if "%{plugin}" == "all" || "%{plugin}" == "libav" + %if "%{tizen_profile_name}" == "tv" + -D %{_libav_opt}tv-profile=true \ + %endif # profile +%endif # plugin +%if "%{plugin}" == "all" || "%{plugin}" == "rs" + %if "%{tizen_profile_name}" == "tv" + -D %{_rs_opt}tv-profile=true \ + %endif # profile + -D %{_rs_opt}introspection=disabled \ + -D %{_rs_opt}rtspclientsink=enabled \ +%endif +%if "%{tizen_profile_name}" != "tv" - %ifarch %{arm} aarch64 riscv64 - %if "%{plugin}" == "all" || "%{plugin}" == "omx" - -D %{_omx_opt}tools=disabled \ - %if "%{target}" == "rpi" - -D %{_omx_opt}header_path=/opt/vc/include/interface/vmcs_host/khronos/IL \ - -D %{_omx_opt}target=rpi \ - %else - %ifarch riscv64 - -D %{_omx_opt}target=generic \ - %else - %ifarch aarch64 - -D %{_omx_opt}target=exynos64 \ - %else - -D %{_omx_opt}target=exynos \ - -D %{_omx_opt}vp9=true \ - %endif # arch aarch64 - %endif # arch riscv64 - %endif # target - %endif # plugin - %endif # arch + %if "%{plugin}" == "all" || "%{plugin}" == "es" + -D %{_es_opt}introspection=disabled \ + -D %{_es_opt}tools=enabled \ + -D %{_es_opt}xptv=enabled \ + -D %{_es_opt}python=enabled \ + %endif # plugin +%endif # profile + build + +ninja -C build all %{?_smp_mflags} + +%if "%{plugin}" != "all" +popd +%endif + +####################################################### +## Install +####################################################### + +%install +rm -rf %{buildroot} +export DESTDIR=%{buildroot} +ninja -C %{_source_path}/build install +mkdir -p %{buildroot}%{_datadir}/gstreamer-%{gst_branch}/presets +rm -rf %{buildroot}%{_datadir}/gstreamer-%{gst_branch}/encoding-profiles +rm -rf %{buildroot}%{_datadir}/locale + +%clean +rm -rf $RPM_BUILD_ROOT + +%post -p /sbin/ldconfig +%postun -p /sbin/ldconfig + +####################################################### +## Packaging rpms +####################################################### + +###################### gstreamer ###################### + +%if "%{plugin}" == "all" || "%{plugin}" == "core" + +%files -n gstreamer +%manifest gstreamer.manifest +%defattr(-, root, root) +%license subprojects/gstreamer/COPYING +%dir %{_datadir}/gstreamer-%{gst_branch} +%dir %{_datadir}/gstreamer-%{gst_branch}/presets +%dir %{_lib_gstreamer_dir} +%{_lib_gstreamer_dir}/libgstcoreelements.so +%{_lib_gstreamer_dir}/libgstcoretracers.so +%dir %{_libexecdir}/gstreamer-%{gst_branch} +%{_libexecdir}/gstreamer-%{gst_branch}/gst-hotdoc-plugins-scanner +%{_libexecdir}/gstreamer-%{gst_branch}/gst-plugin-scanner +%{_libexecdir}/gstreamer-%{gst_branch}/gst-completion-helper +%exclude %{_libexecdir}/gstreamer-%{gst_branch}/gst-plugins-doc-cache-generator +%{_libdir}/libgstbase-%{gst_branch}.so.* +%{_libdir}/libgstcontroller-%{gst_branch}.so.* +%{_libdir}/libgstnet-%{gst_branch}.so.* +%{_libdir}/libgstcheck-%{gst_branch}.so.* +%{_libdir}/libgstreamer-%{gst_branch}.so.* +%if "%{_enable_introspection}" == "1" +%{_lib_girepository}/Gst-%{gst_branch}.typelib +%{_lib_girepository}/GstBase-%{gst_branch}.typelib +%{_lib_girepository}/GstController-%{gst_branch}.typelib +%{_lib_girepository}/GstNet-%{gst_branch}.typelib +%{_lib_girepository}/GstCheck-%{gst_branch}.typelib +%endif #introspection +%{_datadir}/gdb/auto-load/usr/%{_lib}/libgstreamer-%{gst_branch}*-gdb.py +%{_datadir}/gstreamer-%{gst_branch}/gdb/glib_gobject_helper.py +%{_datadir}/gstreamer-%{gst_branch}/gdb/gst_gdb.py + +%files -n gstreamer-utils +%manifest gstreamer.manifest +%defattr(-, root, root) +%license subprojects/gstreamer/COPYING +%{_bindir}/gst-inspect-%{gst_branch} +%{_bindir}/gst-launch-%{gst_branch} +%{_bindir}/gst-stats-%{gst_branch} +%{_bindir}/gst-typefind-%{gst_branch} +%exclude %doc %{_mandir}/man?/*-%{gst_branch}.* + +%files -n gstreamer-devel +%manifest gstreamer.manifest +%defattr(-, root, root) +%{_datadir}/aclocal/gst-element-check-%{gst_branch}.m4 +%{_includedir}/gstreamer-%{gst_branch}/gst/*.h +%{_includedir}/gstreamer-%{gst_branch}/gst/base/* +%{_includedir}/gstreamer-%{gst_branch}/gst/controller/* +%{_includedir}/gstreamer-%{gst_branch}/gst/net/* +%{_includedir}/gstreamer-%{gst_branch}/gst/check/* +%{_libdir}/libgstbase-%{gst_branch}.so +%{_libdir}/libgstcontroller-%{gst_branch}.so +%{_libdir}/libgstnet-%{gst_branch}.so +%{_libdir}/libgstcheck-%{gst_branch}.so +%{_libdir}/libgstreamer-%{gst_branch}.so +%{_libdir}/pkgconfig/gstreamer-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-base-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-controller-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-net-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-check-%{gst_branch}.pc +%if "%{_enable_introspection}" == "1" +%{_datadir}/gir-%{gst_branch}/Gst-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstBase-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstController-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstNet-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstCheck-%{gst_branch}.gir +%endif #introspection + +%changelog + +%endif + +###################### gst-plugins-base ###################### + +%if "%{plugin}" == "all" || "%{plugin}" == "base" + +%files -n gst-plugins-base +%manifest gst-plugins-base.manifest +%defattr(-, root, root) +%license subprojects/gst-plugins-base/COPYING +%{_lib_gstreamer_dir}/libgstalsa.so +%{_lib_gstreamer_dir}/libgstapp.so +%{_lib_gstreamer_dir}/libgstaudioconvert.so +%{_lib_gstreamer_dir}/libgstaudiomixer.so +%{_lib_gstreamer_dir}/libgstaudiorate.so +%{_lib_gstreamer_dir}/libgstaudioresample.so +%{_lib_gstreamer_dir}/libgstaudiotestsrc.so +%{_lib_gstreamer_dir}/libgstcompositor.so +%{_lib_gstreamer_dir}/libgstgio.so +%{_lib_gstreamer_dir}/libgstogg.so +%{_lib_gstreamer_dir}/libgstopus.so +%{_lib_gstreamer_dir}/libgstoverlaycomposition.so +%{_lib_gstreamer_dir}/libgstpbtypes.so +%{_lib_gstreamer_dir}/libgstplayback.so +%{_lib_gstreamer_dir}/libgstrawparse.so +%{_lib_gstreamer_dir}/libgstsubparse.so +%{_lib_gstreamer_dir}/libgsttcp.so +%{_lib_gstreamer_dir}/libgsttheora.so +%{_lib_gstreamer_dir}/libgsttypefindfunctions.so +%{_lib_gstreamer_dir}/libgstvideoconvertscale.so +%{_lib_gstreamer_dir}/libgstvideorate.so +%{_lib_gstreamer_dir}/libgstvideotestsrc.so +%{_lib_gstreamer_dir}/libgstvolume.so +%{_lib_gstreamer_dir}/libgstvorbis.so +%if %{with x} +%{_lib_gstreamer_dir}/libgstximagesink.so +%{_lib_gstreamer_dir}/libgstxvimagesink.so +%endif +%{_libdir}/libgstallocators-%{gst_branch}.so.* +%{_libdir}/libgstapp-%{gst_branch}.so.* +%{_libdir}/libgstaudio-%{gst_branch}.so.* +%{_libdir}/libgstfft-%{gst_branch}.so.* +%{_libdir}/libgstpbutils-%{gst_branch}.so.* +%{_libdir}/libgstriff-%{gst_branch}.so.* +%{_libdir}/libgstrtp-%{gst_branch}.so.* +%{_libdir}/libgstrtsp-%{gst_branch}.so.* +%{_libdir}/libgstsdp-%{gst_branch}.so.* +%{_libdir}/libgsttag-%{gst_branch}.so.* +%{_libdir}/libgstvideo-%{gst_branch}.so.* +%if "%{tizen_profile_name}" != "tv" +%{_lib_gstreamer_dir}/libgstencoding.so +%endif #profile +%if "%{_enable_introspection}" == "1" +%{_lib_girepository}/GstAllocators-%{gst_branch}.typelib +%{_lib_girepository}/GstApp-%{gst_branch}.typelib +%{_lib_girepository}/GstAudio-%{gst_branch}.typelib +%{_lib_girepository}/GstPbutils-%{gst_branch}.typelib +%{_lib_girepository}/GstRtp-%{gst_branch}.typelib +%{_lib_girepository}/GstRtsp-%{gst_branch}.typelib +%{_lib_girepository}/GstSdp-%{gst_branch}.typelib +%{_lib_girepository}/GstTag-%{gst_branch}.typelib +%{_lib_girepository}/GstVideo-%{gst_branch}.typelib +%endif #introspection +%dir %{_datadir}/gst-plugins-base/ +%dir %{_datadir}/gst-plugins-base/%{gst_branch}/ +%{_datadir}/gst-plugins-base/%{gst_branch}/license-translations.dict + +%if "%{tizen_profile_name}" != "tv" +%files -n gst-plugins-base-extension-adder +%{_lib_gstreamer_dir}/libgstadder.so +%license subprojects/gst-plugins-base/COPYING +%endif # profile + +%files -n gst-plugins-base-devel +%manifest gst-plugins-base.manifest +%defattr(-, root, root) +%{_includedir}/gstreamer-%{gst_branch}/gst/allocators/* +%{_includedir}/gstreamer-%{gst_branch}/gst/app/* +%{_includedir}/gstreamer-%{gst_branch}/gst/audio/* +%{_includedir}/gstreamer-%{gst_branch}/gst/fft/* +%{_includedir}/gstreamer-%{gst_branch}/gst/pbutils/* +%{_includedir}/gstreamer-%{gst_branch}/gst/riff/* +%{_includedir}/gstreamer-%{gst_branch}/gst/rtp/* +%{_includedir}/gstreamer-%{gst_branch}/gst/rtsp/* +%{_includedir}/gstreamer-%{gst_branch}/gst/sdp/* +%{_includedir}/gstreamer-%{gst_branch}/gst/tag/* +%{_includedir}/gstreamer-%{gst_branch}/gst/video/* +%if "%{plugin}" == "all" && "%{tizen_profile_name}" != "tv" +%exclude %{_includedir}/gstreamer-%{gst_branch}/gst/audio/audio-bad-prelude.h +%exclude %{_includedir}/gstreamer-%{gst_branch}/gst/audio/gstnonstreamaudiodecoder.h +%exclude %{_includedir}/gstreamer-%{gst_branch}/gst/audio/gstplanaraudioadapter.h +%endif +%{_libdir}/libgstallocators-%{gst_branch}.so +%{_libdir}/libgstapp-%{gst_branch}.so +%{_libdir}/libgstaudio-%{gst_branch}.so +%{_libdir}/libgstfft-%{gst_branch}.so +%{_libdir}/libgstpbutils-%{gst_branch}.so +%{_libdir}/libgstriff-%{gst_branch}.so +%{_libdir}/libgstrtp-%{gst_branch}.so +%{_libdir}/libgstrtsp-%{gst_branch}*.so +%{_libdir}/libgstsdp-%{gst_branch}.so +%{_libdir}/libgsttag-%{gst_branch}.so +%{_libdir}/libgstvideo-%{gst_branch}.so +%{_libdir}/pkgconfig/gstreamer-allocators-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-app-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-audio-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-fft-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-pbutils-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-plugins-base-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-riff-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-rtp-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-rtsp-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-sdp-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-tag-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-video-%{gst_branch}.pc +%if "%{_enable_introspection}" == "1" +%{_datadir}/gir-%{gst_branch}/GstAllocators-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstApp-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstAudio-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstPbutils-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstRtp-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstRtsp-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstSdp-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstTag-%{gst_branch}.gir +%{_datadir}/gir-%{gst_branch}/GstVideo-%{gst_branch}.gir +%endif # introspection + +%endif # plugin + +###################### gst-plugins-good ###################### + +%if "%{plugin}" == "all" || "%{plugin}" == "good" + +%files -n gst-plugins-good +%manifest gst-plugins-good.manifest +%defattr(-, root, root) +%license subprojects/gst-plugins-good/COPYING +%{_lib_gstreamer_dir}/libgstadaptivedemux2.so +%{_lib_gstreamer_dir}/libgstalaw.so +%{_lib_gstreamer_dir}/libgstamrwbdec.so +%{_lib_gstreamer_dir}/libgstapetag.so +%{_lib_gstreamer_dir}/libgstaudiofx.so +%{_lib_gstreamer_dir}/libgstaudioparsers.so +%{_lib_gstreamer_dir}/libgstautodetect.so +%{_lib_gstreamer_dir}/libgstavi.so +%{_lib_gstreamer_dir}/libgstdebug.so +%{_lib_gstreamer_dir}/libgstdeinterlace.so +%{_lib_gstreamer_dir}/libgsticydemux.so +%{_lib_gstreamer_dir}/libgstid3demux.so +%{_lib_gstreamer_dir}/libgstinterleave.so +%{_lib_gstreamer_dir}/libgstisomp4.so +%{_lib_gstreamer_dir}/libgstjpeg.so +%{_lib_gstreamer_dir}/libgstmulaw.so +%{_lib_gstreamer_dir}/libgstnavigationtest.so +%{_lib_gstreamer_dir}/libgstpulseaudio.so +%{_lib_gstreamer_dir}/libgstreplaygain.so +%{_lib_gstreamer_dir}/libgstrtp.so +%{_lib_gstreamer_dir}/libgstrtpmanager.so +%{_lib_gstreamer_dir}/libgstrtsp.so +%{_lib_gstreamer_dir}/libgstsoup.so +%{_lib_gstreamer_dir}/libgstudp.so +%{_lib_gstreamer_dir}/libgstvideocrop.so +%{_lib_gstreamer_dir}/libgstvideofilter.so +%{_lib_gstreamer_dir}/libgstvpx.so +%{_lib_gstreamer_dir}/libgstwavenc.so +%{_lib_gstreamer_dir}/libgstwavparse.so +%if %{with x} +%{_lib_gstreamer_dir}/libgstximagesrc.so +%endif # x +%if "%{tizen_profile_name}" != "tv" +%{_lib_gstreamer_dir}/libgstamrnb.so +%{_lib_gstreamer_dir}/libgsteffectv.so +%{_lib_gstreamer_dir}/libgstflv.so +%{_lib_gstreamer_dir}/libgstimagefreeze.so +%{_lib_gstreamer_dir}/libgstmatroska.so +%{_lib_gstreamer_dir}/libgstmultifile.so +%{_lib_gstreamer_dir}/libgstsmpte.so +%{_lib_gstreamer_dir}/libgstvideobox.so +%{_lib_gstreamer_dir}/libgstvideomixer.so +%exclude %{_datadir}/gstreamer-%{gst_branch}/presets/GstAmrnbEnc.prs +%else # profile +%ifnarch %{arm} aarch64 +%{_lib_gstreamer_dir}/libgstvideo4linux2.so +%endif # arch +%endif # profile +%{_datadir}/gstreamer-%{gst_branch}/presets/GstQTMux.prs +%{_datadir}/gstreamer-%{gst_branch}/presets/GstVP8Enc.prs + +%files -n gst-plugins-good-extra +%manifest gst-plugins-good.manifest +%defattr(-, root, root) +%license subprojects/gst-plugins-good/COPYING +%if 0%{?ENABLE_AALIB} +%{_lib_gstreamer_dir}/libgstaasink.so +%endif +%if "%{tizen_profile_name}" != "tv" +%{_lib_gstreamer_dir}/libgstimagefreeze.so +%{_lib_gstreamer_dir}/libgstpng.so +%endif + +%if "%{tizen_profile_name}" != "tv" +%files -n gst-plugins-good-cairo +%manifest gst-plugins-good.manifest +%defattr(-, root, root) +%license subprojects/gst-plugins-good/COPYING +%{_lib_gstreamer_dir}/libgstcairo.so + +%files -n gst-plugins-good-v4l2 +%manifest gst-plugins-good.manifest +%defattr(-, root, root) +%license subprojects/gst-plugins-good/COPYING +%{_lib_gstreamer_dir}/libgstvideo4linux2.so +%endif + +%endif + +###################### gst-plugins-bad ###################### + +%if "%{plugin}" == "all" || "%{plugin}" == "bad" + +%files -n gst-plugins-bad +%manifest gst-plugins-bad.manifest +%defattr(-, root, root) +%license subprojects/gst-plugins-bad/COPYING +%if "%{tizen_profile_name}" != "tv" +%{_lib_gstreamer_dir}/libgstautoconvert.so +%{_lib_gstreamer_dir}/libgstcamerabin.so +%{_lib_gstreamer_dir}/libgstcoloreffects.so +%{_lib_gstreamer_dir}/libgstdash.so +%{_lib_gstreamer_dir}/libgstgaudieffects.so +%{_lib_gstreamer_dir}/libgstgdp.so +%{_lib_gstreamer_dir}/libgsthls.so +%{_lib_gstreamer_dir}/libgstid3tag.so +%{_lib_gstreamer_dir}/libgstjpegformat.so +%{_lib_gstreamer_dir}/libgstmpegpsdemux.so +%{_lib_gstreamer_dir}/libgstrist.so +%{_lib_gstreamer_dir}/libgstsmoothstreaming.so +%{_lib_gstreamer_dir}/libgstsrt.so +%{_libdir}/libgstadaptivedemux-%{gst_branch}.so.0* +%{_libdir}/libgstbadaudio-%{gst_branch}.so.0* +%{_libdir}/libgstbasecamerabinsrc-%{gst_branch}.so.0* +%{_libdir}/libgstcuda-%{gst_branch}.so.0* +%{_libdir}/libgstinsertbin-%{gst_branch}.so.0* +%{_libdir}/libgstisoff-%{gst_branch}.so.0* +%{_libdir}/libgstphotography-%{gst_branch}.so.0* +%{_libdir}/libgstplay-%{gst_branch}.so.0* +%{_libdir}/libgstplayer-%{gst_branch}.so.0* +%{_libdir}/libgsturidownloader-%{gst_branch}.so.0* +%if 0%{?enable_gl:1} +%{_lib_gstreamer_dir}/libgstopengl.so +%{_libdir}/libgstgl-%{gst_branch}.so.0* +%endif +%endif # profile +%{_lib_gstreamer_dir}/libgstaes.so +%{_lib_gstreamer_dir}/libgstaudiobuffersplit.so +%{_lib_gstreamer_dir}/libgstaudiolatency.so +%{_lib_gstreamer_dir}/libgstaudiomixmatrix.so +%{_lib_gstreamer_dir}/libgstdebugutilsbad.so +%{_lib_gstreamer_dir}/libgstdtls.so +%{_lib_gstreamer_dir}/libgstipcpipeline.so +%{_lib_gstreamer_dir}/libgstmidi.so +%{_lib_gstreamer_dir}/libgstmpegtsdemux.so +%{_lib_gstreamer_dir}/libgstmpegtsmux.so +%{_lib_gstreamer_dir}/libgstnetsim.so +%{_lib_gstreamer_dir}/libgstnice.so +%{_lib_gstreamer_dir}/libgstopenal.so +%{_lib_gstreamer_dir}/libgstopusparse.so +%{_lib_gstreamer_dir}/libgstproxy.so +%if "%{tizen_profile_name}" != "tv" +%{_lib_gstreamer_dir}/libgstrtpmanagerbad.so +%endif +%{_lib_gstreamer_dir}/libgstsctp.so +%{_lib_gstreamer_dir}/libgstsdpelem.so +%{_lib_gstreamer_dir}/libgstshm.so +%{_lib_gstreamer_dir}/libgstsoundtouch.so +%{_lib_gstreamer_dir}/libgstsrtp.so +%{_lib_gstreamer_dir}/libgsttimecode.so +%{_lib_gstreamer_dir}/libgstvideoframe_audiolevel.so +%{_lib_gstreamer_dir}/libgstvideoparsersbad.so +%if %{with wayland} +%{_lib_gstreamer_dir}/libgstwaylandsink.so +%endif +%{_lib_gstreamer_dir}/libgstwebrtc.so +%{_libdir}/libgstcodecparsers-%{gst_branch}.so.0* +%{_libdir}/libgstcodecs-%{gst_branch}.so.0* +%{_libdir}/libgstmpegts-%{gst_branch}.so.0* +%{_libdir}/libgstsctp-%{gst_branch}.so.0* +%{_libdir}/libgsttranscoder-%{gst_branch}.so.0* +%if %{with wayland} +%{_libdir}/libgstwayland-%{gst_branch}.so.0* +%endif +%{_libdir}/libgstwebrtc-%{gst_branch}.so.0* +%{_libdir}/libgstwebrtcnice-%{gst_branch}.so.0* +%exclude %{_bindir}/gst-transcoder-%{gst_branch} + +%files -n gst-plugins-bad-devel +%manifest gst-plugins-bad.manifest +%defattr(-, root, root) +%if "%{tizen_profile_name}" != "tv" +%{_includedir}/gstreamer-%{gst_branch}/gst/audio/audio-bad-prelude.h +%{_includedir}/gstreamer-%{gst_branch}/gst/audio/gstnonstreamaudiodecoder.h +%{_includedir}/gstreamer-%{gst_branch}/gst/audio/gstplanaraudioadapter.h +%{_includedir}/gstreamer-%{gst_branch}/gst/basecamerabinsrc/* +%{_includedir}/gstreamer-%{gst_branch}/gst/cuda/* +%{_includedir}/gstreamer-%{gst_branch}/gst/insertbin/* +%{_includedir}/gstreamer-%{gst_branch}/gst/interfaces/* +%{_includedir}/gstreamer-%{gst_branch}/gst/isoff/* +%{_includedir}/gstreamer-%{gst_branch}/gst/play/* +%{_includedir}/gstreamer-%{gst_branch}/gst/player/* +%{_includedir}/gstreamer-%{gst_branch}/gst/uridownloader/* +%endif +%{_includedir}/gstreamer-%{gst_branch}/gst/codecparsers/* +%{_includedir}/gstreamer-%{gst_branch}/gst/mpegts/* +%{_includedir}/gstreamer-%{gst_branch}/gst/sctp/* +%{_includedir}/gstreamer-%{gst_branch}/gst/transcoder/* +%if %{with wayland} +%{_includedir}/gstreamer-%{gst_branch}/gst/wayland/* +%endif +%{_includedir}/gstreamer-%{gst_branch}/gst/webrtc/* +%if "%{tizen_profile_name}" != "tv" +%{_libdir}/libgstadaptivedemux*.so +%{_libdir}/libgstbadaudio*.so +%{_libdir}/libgstbasecamerabinsrc*.so +%{_libdir}/libgstcuda*.so +%{_libdir}/libgstinsertbin*.so +%{_libdir}/libgstisoff*.so +%{_libdir}/libgstphotography*.so +%{_libdir}/libgstplay*.so +%{_libdir}/libgsturidownloader*.so +%if 0%{?enable_gl:1} +%{_lib_gstreamer_dir}/include/gst/gl/* +%endif # gl +%endif # profile + +%{_libdir}/libgstcodecparsers*.so +%{_libdir}/libgstcodecs*.so +%{_libdir}/libgstmpegts*.so +%{_libdir}/libgstsctp*.so +%{_libdir}/libgsttranscoder*.so +%if %{with wayland} +%{_libdir}/libgstwayland*.so +%endif +%{_libdir}/libgstwebrtc*.so +%{_libdir}/pkgconfig/gstreamer-codecparsers-%{gst_branch}.pc +%if "%{tizen_profile_name}" != "tv" +%{_libdir}/pkgconfig/gstreamer-bad-audio-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-cuda-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-insertbin-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-photography-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-play-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-player-%{gst_branch}.pc +%if 0%{?enable_gl:1} +%{_libdir}/pkgconfig/gstreamer-gl-*.pc +%endif # gl +%endif # profile +%{_libdir}/pkgconfig/gstreamer-mpegts-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-plugins-bad-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-sctp-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-transcoder-%{gst_branch}.pc +%if %{with wayland} +%{_libdir}/pkgconfig/gstreamer-wayland-%{gst_branch}.pc +%endif +%{_libdir}/pkgconfig/gstreamer-webrtc-%{gst_branch}.pc +%{_libdir}/pkgconfig/gstreamer-webrtc-nice-%{gst_branch}.pc + +%endif # plugin + +###################### gst-plugins-ugly ###################### + +%if "%{plugin}" == "all" || "%{plugin}" == "ugly" + +%files -n gst-plugins-ugly +%manifest gst-plugins-ugly.manifest +%defattr(-,root,root,-) +%license subprojects/gst-plugins-ugly/COPYING +%if "%{tizen_profile_name}" != "tv" +%{_lib_gstreamer_dir}/libgstasf.so +%endif # profile + +%endif # plugin + +######################## gst-libav ########################### + +%if "%{plugin}" == "all" || "%{plugin}" == "libav" + +%files -n gst-libav +%manifest gst-libav.manifest +%defattr(-,root,root,-) +%license subprojects/gst-libav/COPYING +%{_lib_gstreamer_dir}/libgstlibav.so + +%endif + +###################### gst-rtsp-server ####################### + +%if "%{plugin}" == "all" || "%{plugin}" == "rs" + +%files -n gst-rtsp-server +%manifest gst-rtsp-server.manifest +%defattr(-,root,root,-) +%license subprojects/gst-rtsp-server/COPYING +%{_libdir}/libgstrtspserver*.so.* +%{_lib_gstreamer_dir}/libgstrtspclientsink.so + +%files -n gst-rtsp-server-devel +%defattr(-,root,root,-) +%{_libdir}/libgstrtspserver*.so +%{_includedir}/gstreamer-%{gst_branch}/gst/rtsp-server/rtsp-*.h +%{_includedir}/gstreamer-%{gst_branch}/gst/rtsp-server/gstwfd*.h +%{_libdir}/pkgconfig/gstreamer-rtsp-server-%{gst_branch}.pc + +%endif + +%if "%{tizen_profile_name}" != "tv" + - ########################## gst-omx ########################### - %ifarch %{arm} aarch64 riscv64 - - %if "%{plugin}" == "all" || "%{plugin}" == "omx" - - %files -n gst-omx - %manifest gst-omx.manifest - %defattr(-,root,root,-) - %license subprojects/gst-omx/COPYING - %{_lib_gstreamer_dir}/libgstomx.so - - %endif - - %endif # arch - +###################### gst-editing-services ####################### + +%if "%{plugin}" == "all" || "%{plugin}" == "es" + +%files -n gst-editing-services +%manifest gst-editing-services.manifest +%defattr(-,root,root,-) +%license subprojects/gst-editing-services/COPYING +%{_libdir}/libges-%{gst_branch}.so.* +%{_lib_gstreamer_dir}/libgstges.so +%{_lib_gstreamer_dir}/libgstnle.so +%exclude %{_libdir}/gst-validate-launcher/python/launcher/apps/geslaunch.py +%exclude %{_datadir}/gstreamer-%{gst_branch}/validate/scenarios/ges-edit-clip-while-paused.scenario +%{_bindir}/ges-launch-%{gst_branch} + +%files -n gst-editing-services-devel +%{_libdir}/libges-%{gst_branch}.so +%{_includedir}/gstreamer-%{gst_branch}/ges/* +%{_libdir}/pkgconfig/gst-editing-services-%{gst_branch}.pc + +%endif # plugin + +%endif # profile diff --cc subprojects/gst-libav/ext/libav/gstavviddec.c index 92d1bc67b6,2512098289..e9598c78cc --- a/subprojects/gst-libav/ext/libav/gstavviddec.c +++ b/subprojects/gst-libav/ext/libav/gstavviddec.c @@@ -2092,27 -2097,6 +2097,22 @@@ gst_ffmpegviddec_video_frame (GstFFMpeg GST_VIDEO_BUFFER_FLAG_TFF); } } +#ifdef TIZEN_FEATURE_LIBAV_VIDEODECODER_ADD_VIDEOMETA + { + GstVideoMeta *vmeta = gst_buffer_get_video_meta (output_frame->output_buffer); + if (!vmeta) { + GstVideoInfo *out_info = &ffmpegdec->output_state->info; + + GST_DEBUG_OBJECT (ffmpegdec, "add videometa for output buffer"); + + gst_buffer_add_video_meta_full (output_frame->output_buffer, GST_VIDEO_FRAME_FLAG_NONE, + GST_VIDEO_INFO_FORMAT (out_info), + GST_VIDEO_INFO_WIDTH (out_info), GST_VIDEO_INFO_HEIGHT (out_info), + GST_VIDEO_INFO_N_PLANES (out_info), out_info->offset, out_info->stride); + } + } +#endif /* TIZEN_FEATURE_LIBAV_VIDEODECODER_ADD_VIDEOMETA */ + - /* Temporarily release the video decoder stream lock so that other - * threads can continue decoding (e.g. call get_frame()) while data - * is being pushed downstream. - */ - GST_VIDEO_DECODER_STREAM_UNLOCK (ffmpegdec); *ret = gst_video_decoder_finish_frame (GST_VIDEO_DECODER (ffmpegdec), output_frame); diff --cc subprojects/gst-plugins-base/gst-libs/gst/video/meson.build index 3bdf259626,1b492fd9e0..64c4619f26 --- a/subprojects/gst-plugins-base/gst-libs/gst/video/meson.build +++ b/subprojects/gst-plugins-base/gst-libs/gst/video/meson.build @@@ -87,7 -83,7 +87,6 @@@ install_headers(video_headers, subdir video_mkenum_headers = [ 'video.h', 'video-anc.h', -- 'video-format.h', 'video-frame.h', 'video-chroma.h', 'video-color.h', @@@ -106,6 -102,6 +105,11 @@@ 'colorbalance.h', 'navigation.h', ] ++if get_option('tv-profile') ++ video_mkenum_headers += ['video-format_tv.h'] ++else ++ video_mkenum_headers += ['video-format.h'] ++endif video_enums = gnome.mkenums_simple('video-enumtypes', sources : video_mkenum_headers, diff --cc subprojects/gst-plugins-base/gst-libs/gst/video/video-format.h index 11e3edb46b,b853485329..97e32eca31 --- a/subprojects/gst-plugins-base/gst-libs/gst/video/video-format.h +++ b/subprojects/gst-plugins-base/gst-libs/gst/video/video-format.h @@@ -20,6 -20,6 +20,10 @@@ #ifndef __GST_VIDEO_FORMAT_H__ #define __GST_VIDEO_FORMAT_H__ ++#ifdef HAVE_CONFIG_H ++#include "config.h" ++#endif ++ #include G_BEGIN_DECLS @@@ -637,6 -619,6 +639,11 @@@ typedef enum * Since: 1.24 */ GST_VIDEO_FORMAT_RBGA, ++#ifdef TIZEN_PROFILE_TV ++ GST_VIDEO_FORMAT_STV0, /*< skip >*/ ++ GST_VIDEO_FORMAT_STV1, /*< skip >*/ ++#endif ++ } GstVideoFormat; #define GST_VIDEO_MAX_PLANES 4 @@@ -1105,6 -1087,6 +1112,28 @@@ gconstpointer gst_video_format_get_pal * Since: 1.24 */ #if G_BYTE_ORDER == G_BIG_ENDIAN ++#ifdef TIZEN_PROFILE_TV ++#define GST_VIDEO_FORMATS_ALL_STR "A444_16BE, A444_16LE, AYUV64, ARGB64, " \ ++ "RGBA64_BE, ARGB64_BE, BGRA64_BE, ABGR64_BE, RGBA64_LE, ARGB64_LE, " \ ++ "BGRA64_LE, ABGR64_LE, A422_16BE, A422_16LE, A420_16BE, A420_16LE, " \ ++ "A444_12BE, GBRA_12BE, A444_12LE, GBRA_12LE, Y412_BE, Y412_LE, A422_12BE, " \ ++ "A422_12LE, A420_12BE, A420_12LE, A444_10BE, GBRA_10BE, A444_10LE, " \ ++ "GBRA_10LE, A422_10BE, A422_10LE, A420_10BE, A420_10LE, Y410, BGR10A2_LE, " \ ++ "RGB10A2_LE, A444, GBRA, AYUV, VUYA, RGBA, RBGA, ARGB, BGRA, ABGR, A422, " \ ++ "A420, AV12, Y444_16BE, GBR_16BE, Y444_16LE, GBR_16LE, v216, P016_BE, " \ ++ "P016_LE, Y444_12BE, GBR_12BE, Y444_12LE, GBR_12LE, I422_12BE, I422_12LE, " \ ++ "Y212_BE, Y212_LE, I420_12BE, I420_12LE, P012_BE, P012_LE, Y444_10BE, " \ ++ "GBR_10BE, Y444_10LE, GBR_10LE, r210, I422_10BE, I422_10LE, NV16_10LE32, " \ ++ "Y210, UYVP, v210, I420_10BE, I420_10LE, P010_10BE, MT2110R, MT2110T, " \ ++ "NV12_10BE_8L128, NV12_10LE40_4L4, P010_10LE, NV12_10LE40, NV12_10LE32, " \ ++ "Y444, BGRP, GBR, RGBP, NV24, v308, IYU2, RGBx, xRGB, BGRx, xBGR, RGB, " \ ++ "BGR, Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ ++ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ ++ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_BE, GRAY16_LE, " \ ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ, " \ ++ "STV0, STV1" ++#else #define GST_VIDEO_FORMATS_ALL_STR "A444_16BE, A444_16LE, AYUV64, ARGB64, " \ "RGBA64_BE, ARGB64_BE, BGRA64_BE, ABGR64_BE, RGBA64_LE, ARGB64_LE, " \ "BGRA64_LE, ABGR64_LE, A422_16BE, A422_16LE, A420_16BE, A420_16LE, " \ @@@ -1122,9 -1104,8 +1151,11 @@@ "BGR, Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_BE, GRAY16_LE, " \ - "S420, ITLV, SN12, ST12, SN21, INVZ, STV0, STV1, " \ -- "GRAY10_LE32, GRAY8" ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ" ++#endif #elif G_BYTE_ORDER == G_LITTLE_ENDIAN ++#ifdef TIZEN_PROFILE_TV #define GST_VIDEO_FORMATS_ALL_STR "A444_16LE, A444_16BE, AYUV64, RGBA64_LE, " \ "ARGB64, ARGB64_LE, BGRA64_LE, ABGR64_LE, RGBA64_BE, ARGB64_BE, BGRA64_BE, " \ "ABGR64_BE, A422_16LE, A422_16BE, A420_16LE, A420_16BE, A444_12LE, " \ @@@ -1142,8 -1123,7 +1173,30 @@@ "Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_LE, GRAY16_BE, " \ - "S420, ITLV, SN12, ST12, SN21, INVZ, STV0, STV1, " \ -- "GRAY10_LE32, GRAY8" ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ, " \ ++ "STV0, STV1" ++#else ++#define GST_VIDEO_FORMATS_ALL_STR "A444_16LE, A444_16BE, AYUV64, RGBA64_LE, " \ ++ "ARGB64, ARGB64_LE, BGRA64_LE, ABGR64_LE, RGBA64_BE, ARGB64_BE, BGRA64_BE, " \ ++ "ABGR64_BE, A422_16LE, A422_16BE, A420_16LE, A420_16BE, A444_12LE, " \ ++ "GBRA_12LE, A444_12BE, GBRA_12BE, Y412_LE, Y412_BE, A422_12LE, A422_12BE, " \ ++ "A420_12LE, A420_12BE, A444_10LE, GBRA_10LE, A444_10BE, GBRA_10BE, " \ ++ "A422_10LE, A422_10BE, A420_10LE, A420_10BE, BGR10A2_LE, RGB10A2_LE, Y410, " \ ++ "A444, GBRA, AYUV, VUYA, RGBA, RBGA, ARGB, BGRA, ABGR, A422, A420, AV12, " \ ++ "Y444_16LE, GBR_16LE, Y444_16BE, GBR_16BE, v216, P016_LE, P016_BE, " \ ++ "Y444_12LE, GBR_12LE, Y444_12BE, GBR_12BE, I422_12LE, I422_12BE, Y212_LE, " \ ++ "Y212_BE, I420_12LE, I420_12BE, P012_LE, P012_BE, Y444_10LE, GBR_10LE, " \ ++ "Y444_10BE, GBR_10BE, r210, I422_10LE, I422_10BE, NV16_10LE32, Y210, UYVP, " \ ++ "v210, I420_10LE, I420_10BE, P010_10LE, NV12_10LE40, NV12_10LE32, " \ ++ "P010_10BE, MT2110R, MT2110T, NV12_10BE_8L128, NV12_10LE40_4L4, Y444, " \ ++ "BGRP, GBR, RGBP, NV24, v308, IYU2, RGBx, xRGB, BGRx, xBGR, RGB, BGR, " \ ++ "Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ ++ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ ++ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_LE, GRAY16_BE, " \ ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ" ++#endif #endif /** diff --cc subprojects/gst-plugins-base/gst-libs/gst/video/video-format_tv.h index 0000000000,0000000000..8f27a1d250 new file mode 100644 --- /dev/null +++ b/subprojects/gst-plugins-base/gst-libs/gst/video/video-format_tv.h @@@ -1,0 -1,0 +1,1293 @@@ ++/* GStreamer ++ * Copyright (C) <2011> Wim Taymans ++ * ++ * This library is free software; you can redistribute it and/or ++ * modify it under the terms of the GNU Library General Public ++ * License as published by the Free Software Foundation; either ++ * version 2 of the License, or (at your option) any later version. ++ * ++ * This library is distributed in the hope that it will be useful, ++ * but WITHOUT ANY WARRANTY; without even the implied warranty of ++ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ++ * Library General Public License for more details. ++ * ++ * You should have received a copy of the GNU Library General Public ++ * License along with this library; if not, write to the ++ * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, ++ * Boston, MA 02110-1301, USA. ++ */ ++ ++#ifndef __GST_VIDEO_FORMAT_H__ ++#define __GST_VIDEO_FORMAT_H__ ++ ++#ifdef HAVE_CONFIG_H ++#include "config.h" ++#endif ++ ++#include ++ ++G_BEGIN_DECLS ++ ++#include ++#include ++ ++/** ++ * GstVideoFormat: ++ * @GST_VIDEO_FORMAT_UNKNOWN: Unknown or unset video format id ++ * @GST_VIDEO_FORMAT_ENCODED: Encoded video format. Only ever use that in caps for ++ * special video formats in combination with non-system ++ * memory GstCapsFeatures where it does not make sense ++ * to specify a real video format. ++ * @GST_VIDEO_FORMAT_I420: planar 4:2:0 YUV ++ * @GST_VIDEO_FORMAT_S420: zero copy format for @GST_VIDEO_FORMAT_I420 ++ * @GST_VIDEO_FORMAT_YV12: planar 4:2:0 YVU (like I420 but UV planes swapped) ++ * @GST_VIDEO_FORMAT_YUY2: packed 4:2:2 YUV (Y0-U0-Y1-V0 Y2-U2-Y3-V2 Y4 ...) ++ * @GST_VIDEO_FORMAT_SUYV: zero copy format for @GST_VIDEO_FORMAT_YUY2 ++ * @GST_VIDEO_FORMAT_UYVY: packed 4:2:2 YUV (U0-Y0-V0-Y1 U2-Y2-V2-Y3 U4 ...) ++ * @GST_VIDEO_FORMAT_SYVY: zero copy format for @GST_VIDEO_FORMAT_UYVY ++ * @GST_VIDEO_FORMAT_VYUY: packed 4:2:2 YUV (V0-Y0-U0-Y1 V2-Y2-U2-Y3 V4 ...) ++ * @GST_VIDEO_FORMAT_AYUV: packed 4:4:4 YUV with alpha channel (A0-Y0-U0-V0 ...) ++ * @GST_VIDEO_FORMAT_RGBx: sparse rgb packed into 32 bit, space last ++ * @GST_VIDEO_FORMAT_BGRx: sparse reverse rgb packed into 32 bit, space last ++ * @GST_VIDEO_FORMAT_xRGB: sparse rgb packed into 32 bit, space first ++ * @GST_VIDEO_FORMAT_xBGR: sparse reverse rgb packed into 32 bit, space first ++ * @GST_VIDEO_FORMAT_RGBA: rgb with alpha channel last ++ * @GST_VIDEO_FORMAT_BGRA: reverse rgb with alpha channel last ++ * @GST_VIDEO_FORMAT_SR32: zero copy format for @GST_VIDEO_FORMAT_ARGB ++ * @GST_VIDEO_FORMAT_ARGB: rgb with alpha channel first ++ * @GST_VIDEO_FORMAT_ABGR: reverse rgb with alpha channel first ++ * @GST_VIDEO_FORMAT_RGB: RGB packed into 24 bits without padding (`R-G-B-R-G-B`) ++ * @GST_VIDEO_FORMAT_BGR: reverse RGB packed into 24 bits without padding (`B-G-R-B-G-R`) ++ * @GST_VIDEO_FORMAT_Y41B: planar 4:1:1 YUV ++ * @GST_VIDEO_FORMAT_Y42B: planar 4:2:2 YUV ++ * @GST_VIDEO_FORMAT_YVYU: packed 4:2:2 YUV (Y0-V0-Y1-U0 Y2-V2-Y3-U2 Y4 ...) ++ * @GST_VIDEO_FORMAT_Y444: planar 4:4:4 YUV ++ * @GST_VIDEO_FORMAT_v210: packed 4:2:2 10-bit YUV, complex format ++ * @GST_VIDEO_FORMAT_v216: packed 4:2:2 16-bit YUV, Y0-U0-Y1-V1 order ++ * @GST_VIDEO_FORMAT_NV12: planar 4:2:0 YUV with interleaved UV plane ++ * @GST_VIDEO_FORMAT_SN12: zero copy format for @GST_VIDEO_FORMAT_NV12 ++ * @GST_VIDEO_FORMAT_ST12: zero copy format for NV12T ++ * @GST_VIDEO_FORMAT_NV21: planar 4:2:0 YUV with interleaved VU plane ++ * @GST_VIDEO_FORMAT_SN21: zero copy format for @GST_VIDEO_FORMAT_NV21 ++ * @GST_VIDEO_FORMAT_NV12_10LE32: 10-bit variant of @GST_VIDEO_FORMAT_NV12, packed into 32bit words (MSB 2 bits padding) (Since: 1.14) ++ * @GST_VIDEO_FORMAT_GRAY8: 8-bit grayscale ++ * @GST_VIDEO_FORMAT_GRAY10_LE32: 10-bit grayscale, packed into 32bit words (2 bits padding) (Since: 1.14) ++ * @GST_VIDEO_FORMAT_GRAY16_BE: 16-bit grayscale, most significant byte first ++ * @GST_VIDEO_FORMAT_GRAY16_LE: 16-bit grayscale, least significant byte first ++ * @GST_VIDEO_FORMAT_v308: packed 4:4:4 YUV (Y-U-V ...) ++ * @GST_VIDEO_FORMAT_IYU2: packed 4:4:4 YUV (U-Y-V ...) (Since: 1.10) ++ * @GST_VIDEO_FORMAT_RGB16: rgb 5-6-5 bits per component ++ * @GST_VIDEO_FORMAT_BGR16: reverse rgb 5-6-5 bits per component ++ * @GST_VIDEO_FORMAT_RGB15: rgb 5-5-5 bits per component ++ * @GST_VIDEO_FORMAT_BGR15: reverse rgb 5-5-5 bits per component ++ * @GST_VIDEO_FORMAT_UYVP: packed 10-bit 4:2:2 YUV (U0-Y0-V0-Y1 U2-Y2-V2-Y3 U4 ...) ++ * @GST_VIDEO_FORMAT_A420: planar 4:4:2:0 AYUV ++ * @GST_VIDEO_FORMAT_RGB8P: 8-bit paletted RGB ++ * @GST_VIDEO_FORMAT_YUV9: planar 4:1:0 YUV ++ * @GST_VIDEO_FORMAT_YVU9: planar 4:1:0 YUV (like YUV9 but UV planes swapped) ++ * @GST_VIDEO_FORMAT_IYU1: packed 4:1:1 YUV (Cb-Y0-Y1-Cr-Y2-Y3 ...) ++ * @GST_VIDEO_FORMAT_ARGB64: rgb with alpha channel first, 16 bits (native endianness) per channel ++ * @GST_VIDEO_FORMAT_AYUV64: packed 4:4:4 YUV with alpha channel, 16 bits (native endianness) per channel (A0-Y0-U0-V0 ...) ++ * @GST_VIDEO_FORMAT_r210: packed 4:4:4 RGB, 10 bits per channel ++ * @GST_VIDEO_FORMAT_I420_10BE: planar 4:2:0 YUV, 10 bits per channel ++ * @GST_VIDEO_FORMAT_I420_10LE: planar 4:2:0 YUV, 10 bits per channel ++ * @GST_VIDEO_FORMAT_I422_10BE: planar 4:2:2 YUV, 10 bits per channel ++ * @GST_VIDEO_FORMAT_I422_10LE: planar 4:2:2 YUV, 10 bits per channel ++ * @GST_VIDEO_FORMAT_Y444_10BE: planar 4:4:4 YUV, 10 bits per channel (Since: 1.2) ++ * @GST_VIDEO_FORMAT_Y444_10LE: planar 4:4:4 YUV, 10 bits per channel (Since: 1.2) ++ * @GST_VIDEO_FORMAT_GBR: planar 4:4:4 RGB, 8 bits per channel (Since: 1.2) ++ * @GST_VIDEO_FORMAT_GBR_10BE: planar 4:4:4 RGB, 10 bits per channel (Since: 1.2) ++ * @GST_VIDEO_FORMAT_GBR_10LE: planar 4:4:4 RGB, 10 bits per channel (Since: 1.2) ++ * @GST_VIDEO_FORMAT_NV16: planar 4:2:2 YUV with interleaved UV plane (Since: 1.2) ++ * @GST_VIDEO_FORMAT_NV16_10LE32: 10-bit variant of @GST_VIDEO_FORMAT_NV16, packed into 32bit words (MSB 2 bits padding) (Since: 1.14) ++ * @GST_VIDEO_FORMAT_NV24: planar 4:4:4 YUV with interleaved UV plane (Since: 1.2) ++ * @GST_VIDEO_FORMAT_NV12_64Z32: NV12 with 64x32 tiling in zigzag pattern (Since: 1.4) ++ * @GST_VIDEO_FORMAT_A420_10BE: planar 4:4:2:0 YUV, 10 bits per channel (Since: 1.6) ++ * @GST_VIDEO_FORMAT_A420_10LE: planar 4:4:2:0 YUV, 10 bits per channel (Since: 1.6) ++ * @GST_VIDEO_FORMAT_A422_10BE: planar 4:4:2:2 YUV, 10 bits per channel (Since: 1.6) ++ * @GST_VIDEO_FORMAT_A422_10LE: planar 4:4:2:2 YUV, 10 bits per channel (Since: 1.6) ++ * @GST_VIDEO_FORMAT_A444_10BE: planar 4:4:4:4 YUV, 10 bits per channel (Since: 1.6) ++ * @GST_VIDEO_FORMAT_A444_10LE: planar 4:4:4:4 YUV, 10 bits per channel (Since: 1.6) ++ * @GST_VIDEO_FORMAT_NV61: planar 4:2:2 YUV with interleaved VU plane (Since: 1.6) ++ * @GST_VIDEO_FORMAT_P010_10BE: planar 4:2:0 YUV with interleaved UV plane, 10 bits per channel (Since: 1.10) ++ * @GST_VIDEO_FORMAT_P010_10LE: planar 4:2:0 YUV with interleaved UV plane, 10 bits per channel (Since: 1.10) ++ * @GST_VIDEO_FORMAT_GBRA: planar 4:4:4:4 ARGB, 8 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_GBRA_10BE: planar 4:4:4:4 ARGB, 10 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_GBRA_10LE: planar 4:4:4:4 ARGB, 10 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_GBR_12BE: planar 4:4:4 RGB, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_GBR_12LE: planar 4:4:4 RGB, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_GBRA_12BE: planar 4:4:4:4 ARGB, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_GBRA_12LE: planar 4:4:4:4 ARGB, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_I420_12BE: planar 4:2:0 YUV, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_I420_12LE: planar 4:2:0 YUV, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_I422_12BE: planar 4:2:2 YUV, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_I422_12LE: planar 4:2:2 YUV, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_Y444_12BE: planar 4:4:4 YUV, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_Y444_12LE: planar 4:4:4 YUV, 12 bits per channel (Since: 1.12) ++ * @GST_VIDEO_FORMAT_NV12_10LE40: Fully packed variant of NV12_10LE32 (Since: 1.16) ++ * @GST_VIDEO_FORMAT_Y210: packed 4:2:2 YUV, 10 bits per channel (Since: 1.16) ++ * @GST_VIDEO_FORMAT_Y410: packed 4:4:4 YUV, 10 bits per channel(A-V-Y-U...) (Since: 1.16) ++ * @GST_VIDEO_FORMAT_VUYA: packed 4:4:4 YUV with alpha channel (V0-U0-Y0-A0...) (Since: 1.16) ++ * @GST_VIDEO_FORMAT_BGR10A2_LE: packed 4:4:4 RGB with alpha channel(B-G-R-A), 10 bits for R/G/B channel and MSB 2 bits for alpha channel (Since: 1.16) ++ * @GST_VIDEO_FORMAT_RGB10A2_LE: packed 4:4:4 RGB with alpha channel(R-G-B-A), 10 bits for R/G/B channel and MSB 2 bits for alpha channel (Since: 1.18) ++ * @GST_VIDEO_FORMAT_Y444_16BE: planar 4:4:4 YUV, 16 bits per channel (Since: 1.18) ++ * @GST_VIDEO_FORMAT_Y444_16LE: planar 4:4:4 YUV, 16 bits per channel (Since: 1.18) ++ * @GST_VIDEO_FORMAT_P016_BE: planar 4:2:0 YUV with interleaved UV plane, 16 bits per channel (Since: 1.18) ++ * @GST_VIDEO_FORMAT_P016_LE: planar 4:2:0 YUV with interleaved UV plane, 16 bits per channel (Since: 1.18) ++ * @GST_VIDEO_FORMAT_P012_BE: planar 4:2:0 YUV with interleaved UV plane, 12 bits per channel (Since: 1.18) ++ * @GST_VIDEO_FORMAT_P012_LE: planar 4:2:0 YUV with interleaved UV plane, 12 bits per channel (Since: 1.18) ++ * @GST_VIDEO_FORMAT_Y212_BE: packed 4:2:2 YUV, 12 bits per channel (Y-U-Y-V) (Since: 1.18) ++ * @GST_VIDEO_FORMAT_Y212_LE: packed 4:2:2 YUV, 12 bits per channel (Y-U-Y-V) (Since: 1.18) ++ * @GST_VIDEO_FORMAT_Y412_BE: packed 4:4:4:4 YUV, 12 bits per channel(U-Y-V-A...) (Since: 1.18) ++ * @GST_VIDEO_FORMAT_Y412_LE: packed 4:4:4:4 YUV, 12 bits per channel(U-Y-V-A...) (Since: 1.18) ++ * @GST_VIDEO_FORMAT_NV12_4L4: NV12 with 4x4 tiles in linear order (Since: 1.18) ++ * @GST_VIDEO_FORMAT_NV12_32L32: NV12 with 32x32 tiles in linear order (Since: 1.18) ++ * @GST_VIDEO_FORMAT_RGBP: planar 4:4:4 RGB, 8 bits per channel (Since: 1.20) ++ * @GST_VIDEO_FORMAT_BGRP: planar 4:4:4 RGB, 8 bits per channel (Since: 1.20) ++ * @GST_VIDEO_FORMAT_AV12: Planar 4:2:0 YUV with interleaved UV plane with alpha as 3rd plane (Since: 1.20) ++ * @GST_VIDEO_FORMAT_ARGB64_LE: RGB with alpha channel first, 16 bits per channel ++ * @GST_VIDEO_FORMAT_ARGB64_BE: RGB with alpha channel first, 16 bits per channel ++ * @GST_VIDEO_FORMAT_RGBA64_LE: RGB with alpha channel last, 16 bits per channel ++ * @GST_VIDEO_FORMAT_RGBA64_BE: RGB with alpha channel last, 16 bits per channel ++ * @GST_VIDEO_FORMAT_BGRA64_LE: reverse RGB with alpha channel last, 16 bits per channel ++ * @GST_VIDEO_FORMAT_BGRA64_BE: reverse RGB with alpha channel last, 16 bits per channel ++ * @GST_VIDEO_FORMAT_ABGR64_LE: reverse RGB with alpha channel first, 16 bits per channel ++ * @GST_VIDEO_FORMAT_ABGR64_BE: reverse RGB with alpha channel first, 16 bits per channel ++ * @GST_VIDEO_FORMAT_NV12_16L32S: NV12 with 16x32 Y tiles and 16x16 UV tiles. (Since: 1.22) ++ * @GST_VIDEO_FORMAT_NV12_8L128 : NV12 with 8x128 tiles in linear order (Since: 1.22) ++ * @GST_VIDEO_FORMAT_NV12_10BE_8L128 : NV12 10bit big endian with 8x128 tiles in linear order (Since: 1.22) ++ * @GST_VIDEO_FORMAT_NV12_10LE40_4L4: @GST_VIDEO_FORMAT_NV12_10LE40 with 4x4 pixels tiles (5 bytes per tile row) (Since: 1.24) ++ * @GST_VIDEO_FORMAT_DMA_DRM: DMA DRM special format. It's only used with ++ * memory:DMABuf #GstCapsFeatures, where an extra ++ * parameter (drm-format) is required to define the ++ * image format and its memory layout. ++ * @GST_VIDEO_FORMAT_MT2110T : Mediatek 10bit NV12 little endian with 16x32 tiles in linear order, tiled 2 bits (Since: 1.24) ++ * @GST_VIDEO_FORMAT_MT2110R : Mediatek 10bit NV12 little endian with 16x32 tiles in linear order, raster 2 bits (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A422: planar 4:4:2:2 YUV, 8 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A444: planar 4:4:4:4 YUV, 8 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A444_12LE: planar 4:4:4:4 YUV, 12 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A444_12BE: planar 4:4:4:4 YUV, 12 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A422_12LE: planar 4:4:2:2 YUV, 12 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A422_12BE: planar 4:4:2:2 YUV, 12 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A420_12LE: planar 4:4:2:0 YUV, 12 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A420_12BE: planar 4:4:2:0 YUV, 12 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A444_16LE: planar 4:4:4:4 YUV, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A444_16BE: planar 4:4:4:4 YUV, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A422_16LE: planar 4:4:2:2 YUV, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A422_16BE: planar 4:4:2:2 YUV, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A420_16LE: planar 4:4:2:0 YUV, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_A420_16BE: planar 4:4:2:0 YUV, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_GBR_16LE: planar 4:4:4 RGB, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_GBR_16BE: planar 4:4:4 RGB, 16 bits per channel (Since: 1.24) ++ * @GST_VIDEO_FORMAT_RBGA: packed RGB with alpha, 8 bits per channel (Since: 1.24) ++ * ++ * Enum value describing the most common video formats. ++ * ++ * See the [GStreamer raw video format design document](https://gstreamer.freedesktop.org/documentation/additional/design/mediatype-video-raw.html#formats) ++ * for details about the layout and packing of these formats in memory. ++ */ ++typedef enum { ++ GST_VIDEO_FORMAT_UNKNOWN, ++ GST_VIDEO_FORMAT_ENCODED, ++ GST_VIDEO_FORMAT_I420, ++ GST_VIDEO_FORMAT_S420, ++ GST_VIDEO_FORMAT_YV12, ++ GST_VIDEO_FORMAT_YUY2, ++ GST_VIDEO_FORMAT_SUYV, ++ GST_VIDEO_FORMAT_UYVY, ++ GST_VIDEO_FORMAT_SYVY, ++ GST_VIDEO_FORMAT_ITLV, ++ GST_VIDEO_FORMAT_AYUV, ++ GST_VIDEO_FORMAT_RGBx, ++ GST_VIDEO_FORMAT_BGRx, ++ GST_VIDEO_FORMAT_xRGB, ++ GST_VIDEO_FORMAT_xBGR, ++ GST_VIDEO_FORMAT_RGBA, ++ GST_VIDEO_FORMAT_BGRA, ++ GST_VIDEO_FORMAT_SR32, ++ GST_VIDEO_FORMAT_ARGB, ++ GST_VIDEO_FORMAT_ABGR, ++ GST_VIDEO_FORMAT_RGB, ++ GST_VIDEO_FORMAT_BGR, ++ GST_VIDEO_FORMAT_Y41B, ++ GST_VIDEO_FORMAT_Y42B, ++ GST_VIDEO_FORMAT_YVYU, ++ GST_VIDEO_FORMAT_Y444, ++ GST_VIDEO_FORMAT_v210, ++ GST_VIDEO_FORMAT_v216, ++ GST_VIDEO_FORMAT_NV12, ++ GST_VIDEO_FORMAT_SN12, ++ GST_VIDEO_FORMAT_ST12, ++ GST_VIDEO_FORMAT_NV21, ++ GST_VIDEO_FORMAT_SN21, ++ GST_VIDEO_FORMAT_GRAY8, ++ GST_VIDEO_FORMAT_GRAY16_BE, ++ GST_VIDEO_FORMAT_GRAY16_LE, ++ GST_VIDEO_FORMAT_v308, ++ GST_VIDEO_FORMAT_RGB16, ++ GST_VIDEO_FORMAT_BGR16, ++ GST_VIDEO_FORMAT_RGB15, ++ GST_VIDEO_FORMAT_BGR15, ++ GST_VIDEO_FORMAT_UYVP, ++ GST_VIDEO_FORMAT_A420, ++ GST_VIDEO_FORMAT_RGB8P, ++ GST_VIDEO_FORMAT_YUV9, ++ GST_VIDEO_FORMAT_YVU9, ++ GST_VIDEO_FORMAT_IYU1, ++ GST_VIDEO_FORMAT_ARGB64, ++ GST_VIDEO_FORMAT_AYUV64, ++ GST_VIDEO_FORMAT_r210, ++ GST_VIDEO_FORMAT_I420_10BE, ++ GST_VIDEO_FORMAT_I420_10LE, ++ GST_VIDEO_FORMAT_I422_10BE, ++ GST_VIDEO_FORMAT_I422_10LE, ++ GST_VIDEO_FORMAT_Y444_10BE, ++ GST_VIDEO_FORMAT_Y444_10LE, ++ GST_VIDEO_FORMAT_GBR, ++ GST_VIDEO_FORMAT_GBR_10BE, ++ GST_VIDEO_FORMAT_GBR_10LE, ++ GST_VIDEO_FORMAT_NV16, ++ GST_VIDEO_FORMAT_NV24, ++ GST_VIDEO_FORMAT_NV12_64Z32, ++ GST_VIDEO_FORMAT_A420_10BE, ++ GST_VIDEO_FORMAT_A420_10LE, ++ GST_VIDEO_FORMAT_A422_10BE, ++ GST_VIDEO_FORMAT_A422_10LE, ++ GST_VIDEO_FORMAT_A444_10BE, ++ GST_VIDEO_FORMAT_A444_10LE, ++ GST_VIDEO_FORMAT_NV61, ++ GST_VIDEO_FORMAT_P010_10BE, ++ GST_VIDEO_FORMAT_P010_10LE, ++ GST_VIDEO_FORMAT_IYU2, ++ GST_VIDEO_FORMAT_VYUY, ++ GST_VIDEO_FORMAT_GBRA, ++ GST_VIDEO_FORMAT_GBRA_10BE, ++ GST_VIDEO_FORMAT_GBRA_10LE, ++ GST_VIDEO_FORMAT_GBR_12BE, ++ GST_VIDEO_FORMAT_GBR_12LE, ++ GST_VIDEO_FORMAT_GBRA_12BE, ++ GST_VIDEO_FORMAT_GBRA_12LE, ++ GST_VIDEO_FORMAT_I420_12BE, ++ GST_VIDEO_FORMAT_I420_12LE, ++ GST_VIDEO_FORMAT_I422_12BE, ++ GST_VIDEO_FORMAT_I422_12LE, ++ GST_VIDEO_FORMAT_Y444_12BE, ++ GST_VIDEO_FORMAT_Y444_12LE, ++ GST_VIDEO_FORMAT_GRAY10_LE32, ++ GST_VIDEO_FORMAT_NV12_10LE32, ++ GST_VIDEO_FORMAT_NV16_10LE32, ++ GST_VIDEO_FORMAT_NV12_10LE40, ++ GST_VIDEO_FORMAT_Y210, ++ GST_VIDEO_FORMAT_Y410, ++ GST_VIDEO_FORMAT_VUYA, ++ GST_VIDEO_FORMAT_BGR10A2_LE, ++ GST_VIDEO_FORMAT_INVZ, ++ GST_VIDEO_FORMAT_RGB10A2_LE, ++ GST_VIDEO_FORMAT_Y444_16BE, ++ GST_VIDEO_FORMAT_Y444_16LE, ++ GST_VIDEO_FORMAT_P016_BE, ++ GST_VIDEO_FORMAT_P016_LE, ++ GST_VIDEO_FORMAT_P012_BE, ++ GST_VIDEO_FORMAT_P012_LE, ++ GST_VIDEO_FORMAT_Y212_BE, ++ GST_VIDEO_FORMAT_Y212_LE, ++ GST_VIDEO_FORMAT_Y412_BE, ++ GST_VIDEO_FORMAT_Y412_LE, ++ /** ++ * GST_VIDEO_FORMAT_NV12_4L4: ++ * ++ * NV12 with 4x4 tiles in linear order. ++ * ++ * Since: 1.18 ++ */ ++ GST_VIDEO_FORMAT_NV12_4L4, ++ /** ++ * GST_VIDEO_FORMAT_NV12_32L32: ++ * ++ * NV12 with 32x32 tiles in linear order. ++ * ++ * Since: 1.18 ++ */ ++ GST_VIDEO_FORMAT_NV12_32L32, ++ ++ /** ++ * GST_VIDEO_FORMAT_RGBP: ++ * ++ * Planar 4:4:4 RGB, R-G-B order ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_RGBP, ++ ++ /** ++ * GST_VIDEO_FORMAT_BGRP: ++ * ++ * Planar 4:4:4 RGB, B-G-R order ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_BGRP, ++ ++ /** ++ * GST_VIDEO_FORMAT_AV12: ++ * ++ * Planar 4:2:0 YUV with interleaved UV plane with alpha as ++ * 3rd plane. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_AV12, ++ ++ /** ++ * GST_VIDEO_FORMAT_ARGB64_LE: ++ * ++ * RGB with alpha channel first, 16 bits (little endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_ARGB64_LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_ARGB64_BE: ++ * ++ * RGB with alpha channel first, 16 bits (big endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_ARGB64_BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_RGBA64_LE: ++ * ++ * RGB with alpha channel last, 16 bits (little endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_RGBA64_LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_RGBA64_BE: ++ * ++ * RGB with alpha channel last, 16 bits (big endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_RGBA64_BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_BGRA64_LE: ++ * ++ * Reverse RGB with alpha channel last, 16 bits (little endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_BGRA64_LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_BGRA64_BE: ++ * ++ * Reverse RGB with alpha channel last, 16 bits (big endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_BGRA64_BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_ABGR64_LE: ++ * ++ * Reverse RGB with alpha channel first, 16 bits (little endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_ABGR64_LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_ABGR64_BE: ++ * ++ * Reverse RGB with alpha channel first, 16 bits (big endian) ++ * per channel. ++ * ++ * Since: 1.20 ++ */ ++ GST_VIDEO_FORMAT_ABGR64_BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_NV12_16L32S: ++ * ++ * NV12 with 16x32 Y tiles and 16x16 UV tiles. ++ * ++ * Since: 1.22 ++ */ ++ GST_VIDEO_FORMAT_NV12_16L32S, ++ ++ /** ++ * GST_VIDEO_FORMAT_NV12_8L128: ++ * ++ * NV12 with 8x128 tiles in linear order. ++ * ++ * Since: 1.22 ++ */ ++ GST_VIDEO_FORMAT_NV12_8L128, ++ ++ /** ++ * GST_VIDEO_FORMAT_NV12_10BE_8L128: ++ * ++ * NV12 10bit big endian with 8x128 tiles in linear order. ++ * ++ * Since: 1.22 ++ */ ++ GST_VIDEO_FORMAT_NV12_10BE_8L128, ++ ++ /** ++ * GST_VIDEO_FORMAT_NV12_10LE40_4L4: ++ * ++ * @GST_VIDEO_FORMAT_NV12_10LE40 with 4x4 pixels tiles (5 bytes ++ * per tile row). This format is produced by Verisilicon/Hantro decoders. ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_NV12_10LE40_4L4, ++ ++ /** ++ * GST_VIDEO_FORMAT_DMA_DRM: ++ * ++ * @GST_VIDEO_FORMAT_DMA_DRM represent the DMA DRM special format. It's ++ * only used with memory:DMABuf #GstCapsFeatures, where an extra ++ * parameter (drm-format) is required to define the image format and ++ * its memory layout. ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_DMA_DRM, ++ ++ /** ++ * GST_VIDEO_FORMAT_MT2110T: ++ * ++ * Mediatek 10bit NV12 little endian with 16x32 tiles in linear order, tile 2 ++ * bits. ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_MT2110T, ++ ++ /** ++ * GST_VIDEO_FORMAT_MT2110R: ++ * ++ * Mediatek 10bit NV12 little endian with 16x32 tiles in linear order, raster ++ * 2 bits. ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_MT2110R, ++ ++ /** ++ * GST_VIDEO_FORMAT_A422: ++ * ++ * planar 4:4:2:2 YUV, 8 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A422, ++ ++ /** ++ * GST_VIDEO_FORMAT_A444: ++ * ++ * planar 4:4:4:4 YUV, 8 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A444, ++ ++ /** ++ * GST_VIDEO_FORMAT_A444_12LE: ++ * ++ * planar 4:4:4:4 YUV, 12 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A444_12LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A444_12BE: ++ * ++ * planar 4:4:4:4 YUV, 12 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A444_12BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A422_12LE: ++ * ++ * planar 4:4:2:2 YUV, 12 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A422_12LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A422_12BE: ++ * ++ * planar 4:4:2:2 YUV, 12 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A422_12BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A420_12LE: ++ * ++ * planar 4:4:2:0 YUV, 12 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A420_12LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A420_12BE: ++ * ++ * planar 4:4:2:0 YUV, 12 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A420_12BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A444_16LE: ++ * ++ * planar 4:4:4:4 YUV, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A444_16LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A444_16BE: ++ * ++ * planar 4:4:4:4 YUV, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A444_16BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A422_16LE: ++ * ++ * planar 4:4:2:2 YUV, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A422_16LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A422_16BE: ++ * ++ * planar 4:4:2:2 YUV, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A422_16BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A420_16LE: ++ * ++ * planar 4:4:2:0 YUV, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A420_16LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_A420_16BE: ++ * ++ * planar 4:4:2:0 YUV, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_A420_16BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_GBR_16LE: ++ * ++ * planar 4:4:4 RGB, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_GBR_16LE, ++ ++ /** ++ * GST_VIDEO_FORMAT_GBR_16BE: ++ * ++ * planar 4:4:4 RGB, 16 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_GBR_16BE, ++ ++ /** ++ * GST_VIDEO_FORMAT_RBGA: ++ * ++ * packed RGB with alpha, 8 bits per channel ++ * ++ * Since: 1.24 ++ */ ++ GST_VIDEO_FORMAT_RBGA, ++#ifdef TIZEN_PROFILE_TV ++ GST_VIDEO_FORMAT_STV0, ++ GST_VIDEO_FORMAT_STV1, ++#endif ++ ++} GstVideoFormat; ++ ++#define GST_VIDEO_MAX_PLANES 4 ++#define GST_VIDEO_MAX_COMPONENTS 4 ++ ++typedef struct _GstVideoFormatInfo GstVideoFormatInfo; ++ ++/** ++ * GstVideoFormatFlags: ++ * @GST_VIDEO_FORMAT_FLAG_YUV: The video format is YUV, components are numbered ++ * 0=Y, 1=U, 2=V. ++ * @GST_VIDEO_FORMAT_FLAG_RGB: The video format is RGB, components are numbered ++ * 0=R, 1=G, 2=B. ++ * @GST_VIDEO_FORMAT_FLAG_GRAY: The video is gray, there is one gray component ++ * with index 0. ++ * @GST_VIDEO_FORMAT_FLAG_ALPHA: The video format has an alpha components with ++ * the number 3. ++ * @GST_VIDEO_FORMAT_FLAG_LE: The video format has data stored in little ++ * endianness. ++ * @GST_VIDEO_FORMAT_FLAG_PALETTE: The video format has a palette. The palette ++ * is stored in the second plane and indexes are stored in the first plane. ++ * @GST_VIDEO_FORMAT_FLAG_COMPLEX: The video format has a complex layout that ++ * can't be described with the usual information in the #GstVideoFormatInfo. ++ * @GST_VIDEO_FORMAT_FLAG_UNPACK: This format can be used in a ++ * #GstVideoFormatUnpack and #GstVideoFormatPack function. ++ * @GST_VIDEO_FORMAT_FLAG_TILED: The format is tiled, there is tiling information ++ * in the last plane. ++ * @GST_VIDEO_FORMAT_FLAG_SUBTILES: The tile size varies per plane ++ * according to the subsampling. (Since: 1.22) ++ * ++ * The different video flags that a format info can have. ++ */ ++typedef enum ++{ ++ GST_VIDEO_FORMAT_FLAG_YUV = (1 << 0), ++ GST_VIDEO_FORMAT_FLAG_RGB = (1 << 1), ++ GST_VIDEO_FORMAT_FLAG_GRAY = (1 << 2), ++ GST_VIDEO_FORMAT_FLAG_ALPHA = (1 << 3), ++ GST_VIDEO_FORMAT_FLAG_LE = (1 << 4), ++ GST_VIDEO_FORMAT_FLAG_PALETTE = (1 << 5), ++ GST_VIDEO_FORMAT_FLAG_COMPLEX = (1 << 6), ++ GST_VIDEO_FORMAT_FLAG_UNPACK = (1 << 7), ++ GST_VIDEO_FORMAT_FLAG_TILED = (1 << 8), ++ /** ++ * GST_VIDEO_FORMAT_FLAG_SUBTILES: ++ * ++ * The tile size varies per plane according to the subsampling. ++ * ++ * Since: 1.22 ++ */ ++ GST_VIDEO_FORMAT_FLAG_SUBTILES = (1 << 9) ++} GstVideoFormatFlags; ++ ++/* YUV components */ ++#define GST_VIDEO_COMP_Y 0 ++#define GST_VIDEO_COMP_U 1 ++#define GST_VIDEO_COMP_V 2 ++ ++/* RGB components */ ++#define GST_VIDEO_COMP_R 0 ++#define GST_VIDEO_COMP_G 1 ++#define GST_VIDEO_COMP_B 2 ++ ++/* alpha component */ ++#define GST_VIDEO_COMP_A 3 ++ ++/* palette components */ ++#define GST_VIDEO_COMP_INDEX 0 ++#define GST_VIDEO_COMP_PALETTE 1 ++ ++#include ++ ++/** ++ * GstVideoPackFlags: ++ * @GST_VIDEO_PACK_FLAG_NONE: No flag ++ * @GST_VIDEO_PACK_FLAG_TRUNCATE_RANGE: When the source has a smaller depth ++ * than the target format, set the least significant bits of the target ++ * to 0. This is likely slightly faster but less accurate. When this flag ++ * is not specified, the most significant bits of the source are duplicated ++ * in the least significant bits of the destination. ++ * @GST_VIDEO_PACK_FLAG_INTERLACED: The source is interlaced. The unpacked ++ * format will be interlaced as well with each line containing ++ * information from alternating fields. (Since: 1.2) ++ * ++ * The different flags that can be used when packing and unpacking. ++ */ ++typedef enum ++{ ++ GST_VIDEO_PACK_FLAG_NONE = 0, ++ GST_VIDEO_PACK_FLAG_TRUNCATE_RANGE = (1 << 0), ++ GST_VIDEO_PACK_FLAG_INTERLACED = (1 << 1) ++} GstVideoPackFlags; ++ ++/** ++ * GstVideoFormatUnpack: ++ * @info: a #GstVideoFormatInfo ++ * @flags: flags to control the unpacking ++ * @dest: a destination array ++ * @data: pointers to the data planes ++ * @stride: strides of the planes ++ * @x: the x position in the image to start from ++ * @y: the y position in the image to start from ++ * @width: the amount of pixels to unpack. ++ * ++ * Unpacks @width pixels from the given planes and strides containing data of ++ * format @info. The pixels will be unpacked into @dest with each component ++ * interleaved as per @info's unpack_format, which will usually be one of ++ * #GST_VIDEO_FORMAT_ARGB, #GST_VIDEO_FORMAT_AYUV, #GST_VIDEO_FORMAT_ARGB64 or ++ * #GST_VIDEO_FORMAT_AYUV64 depending on the format to unpack. ++ * @dest should at least be big enough to hold @width * bytes_per_pixel bytes ++ * where bytes_per_pixel relates to the unpack format and will usually be ++ * either 4 or 8 depending on the unpack format. bytes_per_pixel will be ++ * the same as the pixel stride for plane 0 for the above formats. ++ * ++ * For subsampled formats, the components will be duplicated in the destination ++ * array. Reconstruction of the missing components can be performed in a ++ * separate step after unpacking. ++ */ ++typedef void (*GstVideoFormatUnpack) (const GstVideoFormatInfo *info, ++ GstVideoPackFlags flags, gpointer dest, ++ const gpointer data[GST_VIDEO_MAX_PLANES], ++ const gint stride[GST_VIDEO_MAX_PLANES], ++ gint x, gint y, gint width); ++/** ++ * GstVideoFormatPack: ++ * @info: a #GstVideoFormatInfo ++ * @flags: flags to control the packing ++ * @src: a source array ++ * @sstride: the source array stride ++ * @data: pointers to the destination data planes ++ * @stride: strides of the destination planes ++ * @chroma_site: the chroma siting of the target when subsampled (not used) ++ * @y: the y position in the image to pack to ++ * @width: the amount of pixels to pack. ++ * ++ * Packs @width pixels from @src to the given planes and strides in the ++ * format @info. The pixels from source have each component interleaved ++ * and will be packed into the planes in @data. ++ * ++ * This function operates on pack_lines lines, meaning that @src should ++ * contain at least pack_lines lines with a stride of @sstride and @y ++ * should be a multiple of pack_lines. ++ * ++ * Subsampled formats will use the horizontally and vertically cosited ++ * component from the source. Subsampling should be performed before ++ * packing. ++ * ++ * Because this function does not have a x coordinate, it is not possible to ++ * pack pixels starting from an unaligned position. For tiled images this ++ * means that packing should start from a tile coordinate. For subsampled ++ * formats this means that a complete pixel needs to be packed. ++ */ ++/* FIXME(2.0): remove the chroma_site, it is unused and is not relevant for ++ * packing, chroma subsampling based on chroma-site should be done in a separate ++ * step before packing*/ ++typedef void (*GstVideoFormatPack) (const GstVideoFormatInfo *info, ++ GstVideoPackFlags flags, ++ const gpointer src, gint sstride, ++ gpointer data[GST_VIDEO_MAX_PLANES], ++ const gint stride[GST_VIDEO_MAX_PLANES], ++ GstVideoChromaSite chroma_site, ++ gint y, gint width); ++ ++/** ++ * GstVideoFormatInfo: ++ * @format: #GstVideoFormat ++ * @name: string representation of the format ++ * @description: use readable description of the format ++ * @flags: #GstVideoFormatFlags ++ * @bits: The number of bits used to pack data items. This can be less than 8 ++ * when multiple pixels are stored in a byte. for values > 8 multiple bytes ++ * should be read according to the endianness flag before applying the shift ++ * and mask. ++ * @n_components: the number of components in the video format. ++ * @shift: the number of bits to shift away to get the component data ++ * @depth: the depth in bits for each component ++ * @pixel_stride: the pixel stride of each component. This is the amount of ++ * bytes to the pixel immediately to the right. When bits < 8, the stride is ++ * expressed in bits. For 24-bit RGB, this would be 3 bytes, for example, ++ * while it would be 4 bytes for RGBx or ARGB. ++ * @n_planes: the number of planes for this format. The number of planes can be ++ * less than the amount of components when multiple components are packed into ++ * one plane. ++ * @plane: the plane number where a component can be found ++ * @poffset: the offset in the plane where the first pixel of the components ++ * can be found. ++ * @w_sub: subsampling factor of the width for the component. Use ++ * GST_VIDEO_SUB_SCALE to scale a width. ++ * @h_sub: subsampling factor of the height for the component. Use ++ * GST_VIDEO_SUB_SCALE to scale a height. ++ * @unpack_format: the format of the unpacked pixels. This format must have the ++ * #GST_VIDEO_FORMAT_FLAG_UNPACK flag set. ++ * @unpack_func: an unpack function for this format ++ * @pack_lines: the amount of lines that will be packed ++ * @pack_func: an pack function for this format ++ * @tile_mode: The tiling mode ++ * @tile_ws: The width of a tile, in bytes, represented as a shift. DEPRECATED, ++ * use tile_info[] array instead. ++ * @tile_hs: The height of a tile, in bytes, represented as a shift. DEPREACTED, ++ * use tile_info[] array instead. ++ * @tile_info: Per-plane tile information ++ * ++ * Information for a video format. ++ */ ++struct _GstVideoFormatInfo { ++ GstVideoFormat format; ++ const gchar *name; ++ const gchar *description; ++ GstVideoFormatFlags flags; ++ guint bits; ++ guint n_components; ++ guint shift[GST_VIDEO_MAX_COMPONENTS]; ++ guint depth[GST_VIDEO_MAX_COMPONENTS]; ++ gint pixel_stride[GST_VIDEO_MAX_COMPONENTS]; ++ guint n_planes; ++ guint plane[GST_VIDEO_MAX_COMPONENTS]; ++ guint poffset[GST_VIDEO_MAX_COMPONENTS]; ++ guint w_sub[GST_VIDEO_MAX_COMPONENTS]; ++ guint h_sub[GST_VIDEO_MAX_COMPONENTS]; ++ ++ GstVideoFormat unpack_format; ++ GstVideoFormatUnpack unpack_func; ++ gint pack_lines; ++ GstVideoFormatPack pack_func; ++ ++ GstVideoTileMode tile_mode; ++ G_DEPRECATED_FOR(tile_info) guint tile_ws; ++ G_DEPRECATED_FOR(tile_info) guint tile_hs; ++ ++ /** ++ * GstVideoFormatInfo.tile_info: ++ * ++ * Information about the tiles for each of the planes. ++ * ++ * Since: 1.22 ++ */ ++ GstVideoTileInfo tile_info[GST_VIDEO_MAX_PLANES]; ++}; ++ ++/** ++ * GST_VIDEO_FORMAT_INFO_IS_VALID_RAW: ++ * ++ * Tests that the given #GstVideoFormatInfo represents a valid un-encoded ++ * format. ++ * ++ * Since: 1.22 ++ */ ++#define GST_VIDEO_FORMAT_INFO_IS_VALID_RAW(info) \ ++ (info != NULL && (info)->format > GST_VIDEO_FORMAT_ENCODED) ++ ++#define GST_VIDEO_FORMAT_INFO_FORMAT(info) ((info)->format) ++#define GST_VIDEO_FORMAT_INFO_NAME(info) ((info)->name) ++#define GST_VIDEO_FORMAT_INFO_FLAGS(info) ((info)->flags) ++ ++#define GST_VIDEO_FORMAT_INFO_IS_YUV(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_YUV) != 0) ++#define GST_VIDEO_FORMAT_INFO_IS_RGB(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_RGB) != 0) ++#define GST_VIDEO_FORMAT_INFO_IS_GRAY(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_GRAY) != 0) ++#define GST_VIDEO_FORMAT_INFO_HAS_ALPHA(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_ALPHA) != 0) ++#define GST_VIDEO_FORMAT_INFO_IS_LE(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_LE) != 0) ++#define GST_VIDEO_FORMAT_INFO_HAS_PALETTE(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_PALETTE) != 0) ++#define GST_VIDEO_FORMAT_INFO_IS_COMPLEX(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_COMPLEX) != 0) ++#define GST_VIDEO_FORMAT_INFO_IS_TILED(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_TILED) != 0) ++/** ++ * GST_VIDEO_FORMAT_INFO_HAS_SUBTILES: ++ * @info: a #GstVideoFormatInfo ++ * ++ * This macro checks if %GST_VIDEO_FORMAT_FLAG_SUBTILES is set. When this ++ * flag is set, it means that the tile sizes must be scaled as per the ++ * subsampling. ++ * ++ * Returns: %TRUE if the format uses subsampled tile sizes. ++ * ++ * Since: 1.22 ++ */ ++#define GST_VIDEO_FORMAT_INFO_HAS_SUBTILES(info) (((info)->flags & GST_VIDEO_FORMAT_FLAG_SUBTILES) != 0) ++ ++#define GST_VIDEO_FORMAT_INFO_BITS(info) ((info)->bits) ++#define GST_VIDEO_FORMAT_INFO_N_COMPONENTS(info) ((info)->n_components) ++#define GST_VIDEO_FORMAT_INFO_SHIFT(info,c) ((info)->shift[c]) ++#define GST_VIDEO_FORMAT_INFO_DEPTH(info,c) ((info)->depth[c]) ++/** ++ * GST_VIDEO_FORMAT_INFO_PSTRIDE: ++ * @info: a #GstVideoFormatInfo ++ * @c: the component index ++ * ++ * pixel stride for the given component. This is the amount of bytes to the ++ * pixel immediately to the right, so basically bytes from one pixel to the ++ * next. When bits < 8, the stride is expressed in bits. ++ * ++ * Examples: for 24-bit RGB, the pixel stride would be 3 bytes, while it ++ * would be 4 bytes for RGBx or ARGB, and 8 bytes for ARGB64 or AYUV64. ++ * For planar formats such as I420 the pixel stride is usually 1. For ++ * YUY2 it would be 2 bytes. ++ */ ++#define GST_VIDEO_FORMAT_INFO_PSTRIDE(info,c) ((info)->pixel_stride[c]) ++/** ++ * GST_VIDEO_FORMAT_INFO_N_PLANES: ++ * @info: a #GstVideoFormatInfo ++ * ++ * Number of planes. This is the number of planes the pixel layout is ++ * organized in in memory. The number of planes can be less than the ++ * number of components (e.g. Y,U,V,A or R, G, B, A) when multiple ++ * components are packed into one plane. ++ * ++ * Examples: RGB/RGBx/RGBA: 1 plane, 3/3/4 components; ++ * I420: 3 planes, 3 components; NV21/NV12: 2 planes, 3 components. ++ */ ++#define GST_VIDEO_FORMAT_INFO_N_PLANES(info) ((info)->n_planes) ++/** ++ * GST_VIDEO_FORMAT_INFO_PLANE: ++ * @info: a #GstVideoFormatInfo ++ * @c: the component index ++ * ++ * Plane number where the given component can be found. A plane may ++ * contain data for multiple components. ++ */ ++#define GST_VIDEO_FORMAT_INFO_PLANE(info,c) ((info)->plane[c]) ++#define GST_VIDEO_FORMAT_INFO_POFFSET(info,c) ((info)->poffset[c]) ++#define GST_VIDEO_FORMAT_INFO_W_SUB(info,c) ((info)->w_sub[c]) ++#define GST_VIDEO_FORMAT_INFO_H_SUB(info,c) ((info)->h_sub[c]) ++ ++/* rounds up */ ++#define GST_VIDEO_SUB_SCALE(scale,val) (-((-((gint)(val)))>>(scale))) ++ ++#define GST_VIDEO_FORMAT_INFO_SCALE_WIDTH(info,c,w) GST_VIDEO_SUB_SCALE ((info)->w_sub[c],(w)) ++#define GST_VIDEO_FORMAT_INFO_SCALE_HEIGHT(info,c,h) GST_VIDEO_SUB_SCALE ((info)->h_sub[c],(h)) ++ ++#define GST_VIDEO_FORMAT_INFO_DATA(info,planes,comp) \ ++ (((guint8*)(planes)[(info)->plane[comp]]) + (info)->poffset[comp]) ++/** ++ * GST_VIDEO_FORMAT_INFO_STRIDE: ++ * @info: a #GstVideoFormatInfo ++ * @strides: an array of strides ++ * @comp: the component index ++ * ++ * Row stride in bytes, that is number of bytes from the first pixel component ++ * of a row to the first pixel component in the next row. This might include ++ * some row padding (memory not actually used for anything, to make sure the ++ * beginning of the next row is aligned in a particular way). ++ */ ++#define GST_VIDEO_FORMAT_INFO_STRIDE(info,strides,comp) ((strides)[(info)->plane[comp]]) ++#define GST_VIDEO_FORMAT_INFO_OFFSET(info,offsets,comp) \ ++ (((offsets)[(info)->plane[comp]]) + (info)->poffset[comp]) ++ ++#define GST_VIDEO_FORMAT_INFO_TILE_MODE(info) ((info)->tile_mode) ++#define GST_VIDEO_FORMAT_INFO_TILE_WS(info) ((info)->tile_ws) ++#define GST_VIDEO_FORMAT_INFO_TILE_HS(info) ((info)->tile_hs) ++ ++/** ++ * GST_VIDEO_FORMAT_INFO_TILE_SIZE: ++ * @info: a #GstVideoFormatInfo ++ * @plane: the plane index ++ * ++ * Provides the size in bytes of a tile in the specified @plane. This replaces ++ * the width and height shift, which was limited to power of two dimensions. ++ * ++ * Since: 1.22 ++ */ ++#define GST_VIDEO_FORMAT_INFO_TILE_SIZE(info,plane) ((info)->tile_info[plane].size) ++ ++/** ++ * GST_VIDEO_FORMAT_INFO_TILE_WIDTH: ++ * @info: a #GstVideoFormatInfo ++ * @plane: the plane index ++ * ++ * See #GstVideoTileInfo.width. ++ * ++ * Return the width of one tile in pixels, zero if its not an integer. ++ * ++ * Since: 1.22 ++ */ ++#define GST_VIDEO_FORMAT_INFO_TILE_WIDTH(info,plane) ((info)->tile_info[plane].width) ++ ++/** ++ * GST_VIDEO_FORMAT_INFO_TILE_HEIGHT: ++ * @info: a #GstVideoFormatInfo ++ * @plane: the plane index ++ * ++ * See #GstVideoTileInfo.height. ++ * ++ * Returns the tile height. ++ * ++ * Since: 1.22 ++ */ ++#define GST_VIDEO_FORMAT_INFO_TILE_HEIGHT(info,plane) ((info)->tile_info[plane].height) ++ ++/** ++ * GST_VIDEO_FORMAT_INFO_TILE_STRIDE: ++ * @info: a #GstVideoFormatInfo ++ * @plane: the plane index ++ * ++ * See #GstVideoTileInfo.stride. ++ * ++ * Returns the stride of one tile, regardless of the internal details of the ++ * tile (could be a complex system with subtile) the tiles size should alway ++ * match the tile width multiplied by the tile stride. ++ * ++ * Since: 1.22 ++ */ ++#define GST_VIDEO_FORMAT_INFO_TILE_STRIDE(info,plane) ((info)->tile_info[plane].stride) ++ ++ ++GST_VIDEO_API ++void gst_video_format_info_component (const GstVideoFormatInfo *info, guint plane, gint components[GST_VIDEO_MAX_COMPONENTS]); ++ ++GST_VIDEO_API ++gint gst_video_format_info_extrapolate_stride (const GstVideoFormatInfo * finfo, ++ gint plane, gint stride); ++ ++/* format properties */ ++ ++GST_VIDEO_API ++GstVideoFormat gst_video_format_from_masks (gint depth, gint bpp, gint endianness, ++ guint red_mask, guint green_mask, ++ guint blue_mask, guint alpha_mask) G_GNUC_CONST; ++ ++GST_VIDEO_API ++GstVideoFormat gst_video_format_from_fourcc (guint32 fourcc) G_GNUC_CONST; ++ ++GST_VIDEO_API ++GstVideoFormat gst_video_format_from_string (const gchar *format) G_GNUC_CONST; ++ ++GST_VIDEO_API ++guint32 gst_video_format_to_fourcc (GstVideoFormat format) G_GNUC_CONST; ++ ++GST_VIDEO_API ++const gchar * gst_video_format_to_string (GstVideoFormat format) G_GNUC_CONST; ++ ++GST_VIDEO_API ++const GstVideoFormatInfo * ++ gst_video_format_get_info (GstVideoFormat format) G_GNUC_CONST; ++ ++GST_VIDEO_API ++gconstpointer gst_video_format_get_palette (GstVideoFormat format, gsize *size); ++ ++#define GST_VIDEO_SIZE_RANGE "(int) [ 1, max ]" ++#define GST_VIDEO_FPS_RANGE "(fraction) [ 0, max ]" ++ ++#if G_BYTE_ORDER == G_LITTLE_ENDIAN ++# define GST_VIDEO_NE(s) G_STRINGIFY(s)"_LE" ++# define GST_VIDEO_OE(s) G_STRINGIFY(s)"_BE" ++#else ++# define GST_VIDEO_NE(s) G_STRINGIFY(s)"_BE" ++# define GST_VIDEO_OE(s) G_STRINGIFY(s)"_LE" ++#endif ++ ++/** ++ * GST_VIDEO_FORMATS_ALL_STR: ++ * ++ * Declare all video formats as a string. ++ * ++ * Formats are sorted by decreasing "quality", using these criteria by priority: ++ * - number of components ++ * - depth ++ * - subsampling factor of the width ++ * - subsampling factor of the height ++ * - number of planes ++ * - native endianness preferred ++ * - pixel stride ++ * - poffset ++ * - prefer non-complex formats ++ * - prefer YUV formats over RGB ones ++ * - prefer I420 over YV12 ++ * - format name ++ * ++ * Since: 1.24 ++ */ ++#if G_BYTE_ORDER == G_BIG_ENDIAN ++#ifdef TIZEN_PROFILE_TV ++#define GST_VIDEO_FORMATS_ALL_STR "A444_16BE, A444_16LE, AYUV64, ARGB64, " \ ++ "RGBA64_BE, ARGB64_BE, BGRA64_BE, ABGR64_BE, RGBA64_LE, ARGB64_LE, " \ ++ "BGRA64_LE, ABGR64_LE, A422_16BE, A422_16LE, A420_16BE, A420_16LE, " \ ++ "A444_12BE, GBRA_12BE, A444_12LE, GBRA_12LE, Y412_BE, Y412_LE, A422_12BE, " \ ++ "A422_12LE, A420_12BE, A420_12LE, A444_10BE, GBRA_10BE, A444_10LE, " \ ++ "GBRA_10LE, A422_10BE, A422_10LE, A420_10BE, A420_10LE, Y410, BGR10A2_LE, " \ ++ "RGB10A2_LE, A444, GBRA, AYUV, VUYA, RGBA, RBGA, ARGB, BGRA, ABGR, A422, " \ ++ "A420, AV12, Y444_16BE, GBR_16BE, Y444_16LE, GBR_16LE, v216, P016_BE, " \ ++ "P016_LE, Y444_12BE, GBR_12BE, Y444_12LE, GBR_12LE, I422_12BE, I422_12LE, " \ ++ "Y212_BE, Y212_LE, I420_12BE, I420_12LE, P012_BE, P012_LE, Y444_10BE, " \ ++ "GBR_10BE, Y444_10LE, GBR_10LE, r210, I422_10BE, I422_10LE, NV16_10LE32, " \ ++ "Y210, UYVP, v210, I420_10BE, I420_10LE, P010_10BE, MT2110R, MT2110T, " \ ++ "NV12_10BE_8L128, NV12_10LE40_4L4, P010_10LE, NV12_10LE40, NV12_10LE32, " \ ++ "Y444, BGRP, GBR, RGBP, NV24, v308, IYU2, RGBx, xRGB, BGRx, xBGR, RGB, " \ ++ "BGR, Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ ++ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ ++ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_BE, GRAY16_LE, " \ ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ, " \ ++ "STV0, STV1" ++#else ++#define GST_VIDEO_FORMATS_ALL_STR "A444_16BE, A444_16LE, AYUV64, ARGB64, " \ ++ "RGBA64_BE, ARGB64_BE, BGRA64_BE, ABGR64_BE, RGBA64_LE, ARGB64_LE, " \ ++ "BGRA64_LE, ABGR64_LE, A422_16BE, A422_16LE, A420_16BE, A420_16LE, " \ ++ "A444_12BE, GBRA_12BE, A444_12LE, GBRA_12LE, Y412_BE, Y412_LE, A422_12BE, " \ ++ "A422_12LE, A420_12BE, A420_12LE, A444_10BE, GBRA_10BE, A444_10LE, " \ ++ "GBRA_10LE, A422_10BE, A422_10LE, A420_10BE, A420_10LE, Y410, BGR10A2_LE, " \ ++ "RGB10A2_LE, A444, GBRA, AYUV, VUYA, RGBA, RBGA, ARGB, BGRA, ABGR, A422, " \ ++ "A420, AV12, Y444_16BE, GBR_16BE, Y444_16LE, GBR_16LE, v216, P016_BE, " \ ++ "P016_LE, Y444_12BE, GBR_12BE, Y444_12LE, GBR_12LE, I422_12BE, I422_12LE, " \ ++ "Y212_BE, Y212_LE, I420_12BE, I420_12LE, P012_BE, P012_LE, Y444_10BE, " \ ++ "GBR_10BE, Y444_10LE, GBR_10LE, r210, I422_10BE, I422_10LE, NV16_10LE32, " \ ++ "Y210, UYVP, v210, I420_10BE, I420_10LE, P010_10BE, MT2110R, MT2110T, " \ ++ "NV12_10BE_8L128, NV12_10LE40_4L4, P010_10LE, NV12_10LE40, NV12_10LE32, " \ ++ "Y444, BGRP, GBR, RGBP, NV24, v308, IYU2, RGBx, xRGB, BGRx, xBGR, RGB, " \ ++ "BGR, Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ ++ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ ++ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_BE, GRAY16_LE, " \ ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ" ++#endif ++#elif G_BYTE_ORDER == G_LITTLE_ENDIAN ++#ifdef TIZEN_PROFILE_TV ++#define GST_VIDEO_FORMATS_ALL_STR "A444_16LE, A444_16BE, AYUV64, RGBA64_LE, " \ ++ "ARGB64, ARGB64_LE, BGRA64_LE, ABGR64_LE, RGBA64_BE, ARGB64_BE, BGRA64_BE, " \ ++ "ABGR64_BE, A422_16LE, A422_16BE, A420_16LE, A420_16BE, A444_12LE, " \ ++ "GBRA_12LE, A444_12BE, GBRA_12BE, Y412_LE, Y412_BE, A422_12LE, A422_12BE, " \ ++ "A420_12LE, A420_12BE, A444_10LE, GBRA_10LE, A444_10BE, GBRA_10BE, " \ ++ "A422_10LE, A422_10BE, A420_10LE, A420_10BE, BGR10A2_LE, RGB10A2_LE, Y410, " \ ++ "A444, GBRA, AYUV, VUYA, RGBA, RBGA, ARGB, BGRA, ABGR, A422, A420, AV12, " \ ++ "Y444_16LE, GBR_16LE, Y444_16BE, GBR_16BE, v216, P016_LE, P016_BE, " \ ++ "Y444_12LE, GBR_12LE, Y444_12BE, GBR_12BE, I422_12LE, I422_12BE, Y212_LE, " \ ++ "Y212_BE, I420_12LE, I420_12BE, P012_LE, P012_BE, Y444_10LE, GBR_10LE, " \ ++ "Y444_10BE, GBR_10BE, r210, I422_10LE, I422_10BE, NV16_10LE32, Y210, UYVP, " \ ++ "v210, I420_10LE, I420_10BE, P010_10LE, NV12_10LE40, NV12_10LE32, " \ ++ "P010_10BE, MT2110R, MT2110T, NV12_10BE_8L128, NV12_10LE40_4L4, Y444, " \ ++ "BGRP, GBR, RGBP, NV24, v308, IYU2, RGBx, xRGB, BGRx, xBGR, RGB, BGR, " \ ++ "Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ ++ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ ++ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_LE, GRAY16_BE, " \ ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ, " \ ++ "STV0, STV1" ++#else ++#define GST_VIDEO_FORMATS_ALL_STR "A444_16LE, A444_16BE, AYUV64, RGBA64_LE, " \ ++ "ARGB64, ARGB64_LE, BGRA64_LE, ABGR64_LE, RGBA64_BE, ARGB64_BE, BGRA64_BE, " \ ++ "ABGR64_BE, A422_16LE, A422_16BE, A420_16LE, A420_16BE, A444_12LE, " \ ++ "GBRA_12LE, A444_12BE, GBRA_12BE, Y412_LE, Y412_BE, A422_12LE, A422_12BE, " \ ++ "A420_12LE, A420_12BE, A444_10LE, GBRA_10LE, A444_10BE, GBRA_10BE, " \ ++ "A422_10LE, A422_10BE, A420_10LE, A420_10BE, BGR10A2_LE, RGB10A2_LE, Y410, " \ ++ "A444, GBRA, AYUV, VUYA, RGBA, RBGA, ARGB, BGRA, ABGR, A422, A420, AV12, " \ ++ "Y444_16LE, GBR_16LE, Y444_16BE, GBR_16BE, v216, P016_LE, P016_BE, " \ ++ "Y444_12LE, GBR_12LE, Y444_12BE, GBR_12BE, I422_12LE, I422_12BE, Y212_LE, " \ ++ "Y212_BE, I420_12LE, I420_12BE, P012_LE, P012_BE, Y444_10LE, GBR_10LE, " \ ++ "Y444_10BE, GBR_10BE, r210, I422_10LE, I422_10BE, NV16_10LE32, Y210, UYVP, " \ ++ "v210, I420_10LE, I420_10BE, P010_10LE, NV12_10LE40, NV12_10LE32, " \ ++ "P010_10BE, MT2110R, MT2110T, NV12_10BE_8L128, NV12_10LE40_4L4, Y444, " \ ++ "BGRP, GBR, RGBP, NV24, v308, IYU2, RGBx, xRGB, BGRx, xBGR, RGB, BGR, " \ ++ "Y42B, NV16, NV61, YUY2, YVYU, UYVY, VYUY, I420, YV12, NV12, NV21, " \ ++ "NV12_16L32S, NV12_32L32, NV12_4L4, NV12_64Z32, NV12_8L128, Y41B, IYU1, " \ ++ "YUV9, YVU9, BGR16, RGB16, BGR15, RGB15, RGB8P, GRAY16_LE, GRAY16_BE, " \ ++ "GRAY10_LE32, GRAY8, " \ ++ "S420, ITLV, SN12, ST12, SN21, INVZ" ++#endif ++#endif ++ ++/** ++ * GST_VIDEO_FORMATS_ANY_STR: ++ * ++ * This is similar to %GST_VIDEO_FORMATS_ALL_STR but includes formats like ++ * DMA_DRM for which no software converter exists. This should be used for ++ * passthrough template caps. ++ * ++ * Since: 1.24 ++ */ ++#define GST_VIDEO_FORMATS_ANY_STR "DMA_DRM, " GST_VIDEO_FORMATS_ALL_STR ++ ++/** ++ * GST_VIDEO_FORMATS_ALL: ++ * ++ * List of all video formats, for use in template caps strings. ++ * ++ * Formats are sorted by decreasing "quality", using these criteria by priority: ++ * - number of components ++ * - depth ++ * - subsampling factor of the width ++ * - subsampling factor of the height ++ * - number of planes ++ * - native endianness preferred ++ * - pixel stride ++ * - poffset ++ * - prefer non-complex formats ++ * - prefer YUV formats over RGB ones ++ * - prefer I420 over YV12 ++ * - format name ++ */ ++#define GST_VIDEO_FORMATS_ALL "{ " GST_VIDEO_FORMATS_ALL_STR " }" ++ ++/** ++ * GST_VIDEO_FORMATS_ANY: ++ * ++ * This is similar to %GST_VIDEO_FORMATS_ALL but includes formats like DMA_DRM ++ * that do not have a software converter. This should be used for passthrough ++ * template caps. ++ * ++ * Since: 1.24 ++ */ ++#define GST_VIDEO_FORMATS_ANY "{ " GST_VIDEO_FORMATS_ANY_STR " }" ++ ++GST_VIDEO_API ++const GstVideoFormat * gst_video_formats_raw (guint * len); ++ ++GST_VIDEO_API ++const GstVideoFormat * gst_video_formats_any (guint * len); ++ ++/** ++ * GST_VIDEO_CAPS_MAKE: ++ * @format: string format that describes the pixel layout, as string ++ * (e.g. "I420", "RGB", "YV12", "YUY2", "AYUV", etc.) ++ * ++ * Generic caps string for video, for use in pad templates. ++ */ ++#define GST_VIDEO_CAPS_MAKE(format) \ ++ "video/x-raw, " \ ++ "format = (string) " format ", " \ ++ "width = " GST_VIDEO_SIZE_RANGE ", " \ ++ "height = " GST_VIDEO_SIZE_RANGE ", " \ ++ "framerate = " GST_VIDEO_FPS_RANGE ++ ++/** ++ * GST_VIDEO_CAPS_MAKE_WITH_FEATURES: ++ * @format: string format that describes the pixel layout, as string ++ * (e.g. "I420", "RGB", "YV12", "YUY2", "AYUV", etc.) ++ * @features: Requires caps features as a string, e.g. ++ * "memory:SystemMemory". ++ * ++ * Generic caps string for video, for use in pad templates. ++ * ++ * Since: 1.2 ++ */ ++#define GST_VIDEO_CAPS_MAKE_WITH_FEATURES(features,format) \ ++ "video/x-raw(" features "), " \ ++ "format = (string) " format ", " \ ++ "width = " GST_VIDEO_SIZE_RANGE ", " \ ++ "height = " GST_VIDEO_SIZE_RANGE ", " \ ++ "framerate = " GST_VIDEO_FPS_RANGE ++ ++GST_VIDEO_API ++GstCaps * gst_video_make_raw_caps (const GstVideoFormat formats[], guint len); ++ ++GST_VIDEO_API ++GstCaps * gst_video_make_raw_caps_with_features (const GstVideoFormat formats[], guint len, ++ GstCapsFeatures * features); ++ ++ ++G_END_DECLS ++ ++#endif /* __GST_VIDEO_FORMAT_H__ */ diff --cc subprojects/gst-plugins-good/gst/isomp4/qtdemux.c index 3b0c589787,48b628494a..3a46455473 --- a/subprojects/gst-plugins-good/gst/isomp4/qtdemux.c +++ b/subprojects/gst-plugins-good/gst/isomp4/qtdemux.c @@@ -5778,11 -5211,10 +5784,14 @@@ gst_qtdemux_loop_state_header (GstQTDem beach: if (ret == GST_FLOW_EOS && (qtdemux->got_moov || qtdemux->media_caps)) { /* digested all data, show what we have */ +#ifdef TIZEN_FEATURE_QTDEMUX_MODIFICATION + if (qtdemux->spherical_metadata) + _send_spherical_metadata_msg_to_bus (qtdemux); +#endif /* TIZEN_FEATURE_QTDEMUX_MODIFICATION */ - qtdemux_prepare_streams (qtdemux); + ret = qtdemux_prepare_streams (qtdemux); + if (ret != GST_FLOW_OK) + return ret; + QTDEMUX_EXPOSE_LOCK (qtdemux); ret = qtdemux_expose_streams (qtdemux); QTDEMUX_EXPOSE_UNLOCK (qtdemux); diff --cc subprojects/gst-plugins-good/gst/rtsp/gstrtspsrc.c index 542e81dfcc,a12a6f0cc2..b084c57453 --- a/subprojects/gst-plugins-good/gst/rtsp/gstrtspsrc.c +++ b/subprojects/gst-plugins-good/gst/rtsp/gstrtspsrc.c @@@ -315,12 -315,8 +315,13 @@@ gst_rtsp_backchannel_get_type (void #define DEFAULT_IS_LIVE TRUE #define DEFAULT_IGNORE_X_SERVER_REPLY FALSE #define DEFAULT_FORCE_NON_COMPLIANT_URL FALSE + #define DEFAULT_TCP_TIMESTAMP FALSE +#ifdef TIZEN_FEATURE_RTSP_MODIFICATION +#define DEFAULT_START_POSITION 0 +#define DEFAULT_STREAM_INFO_MESSAGE TRUE +#endif + enum { PROP_0, @@@ -1627,11 -1604,8 +1660,12 @@@ gst_rtspsrc_init (GstRTSPSrc * src src->prop_extra_http_request_headers = gst_structure_new_empty ("extra-http-request-headers"); src->force_non_compliant_url = DEFAULT_FORCE_NON_COMPLIANT_URL; + src->tcp_timestamp = DEFAULT_TCP_TIMESTAMP; +#ifdef TIZEN_FEATURE_RTSP_MODIFICATION + g_mutex_init (&(src)->pause_lock); + g_cond_init (&(src)->open_end); +#endif /* get a list of all extensions */ src->extensions = gst_rtsp_ext_list_get (); diff --cc subprojects/gst-plugins-good/gst/wavparse/gstwavparse.c index 9f52ec4eab,f2fa1e45c5..50e4131123 --- a/subprojects/gst-plugins-good/gst/wavparse/gstwavparse.c +++ b/subprojects/gst-plugins-good/gst/wavparse/gstwavparse.c @@@ -1437,17 -1466,8 +1466,13 @@@ gst_wavparse_stream_headers (GstWavPars goto exit; } gst_adapter_flush (wav->adapter, 8); +#ifdef TIZEN_FEATURE_WAVPARSE_MODIFICATION - if (gst_adapter_available (wav->adapter) < 24) { ++ if (gst_adapter_available (wav->adapter) < data_size) { + goto exit; + } - data = gst_adapter_map (wav->adapter, 24); ++#endif + data = gst_adapter_map (wav->adapter, data_size); tempo = GST_READ_FLOAT_LE (data + 20); - #else - acid = (const gst_riff_acid *) gst_adapter_map (wav->adapter, - data_size); - tempo = acid->tempo; - #endif gst_adapter_unmap (wav->adapter); } else { GstMapInfo map; diff --cc subprojects/gst-rtsp-server/NEWS index 9fd58a795f,2a914ca858..2a914ca858 mode 100755,100644..100755 --- a/subprojects/gst-rtsp-server/NEWS +++ b/subprojects/gst-rtsp-server/NEWS diff --cc subprojects/gstreamer/gst/gstutils.c index 53afbcbee8,99e95dd0aa..b9f1598e14 --- a/subprojects/gstreamer/gst/gstutils.c +++ b/subprojects/gstreamer/gst/gstutils.c @@@ -4770,109 -4771,6 +4774,109 @@@ invalid } } +#ifdef TIZEN_PROFILE_TV +/** + * gst_element_query_resource + * @element: (in): a #GstElement to invoke the resource query on. + * @resources: (out): a pointer to the list of resources asked for. + * Returns: TRUE if the query could be performed. + */ +gboolean +gst_element_query_resource (GstElement * element, GList ** resource_list) +{ + GstQuery *query; + gboolean ret; + char resources[250]; + char *element_resource; + guint count = 0, i = 0; - GstObject *object; ++ GObject *object; + int resource_num; + + if (resource_list == NULL) { + return FALSE; + } + + query = gst_query_new_resource (resources); + if (GST_IS_BIN (element)) { + count = gst_child_proxy_get_children_count ((GstChildProxy *)element); + for (i = 0; i < count; i++) { + if (!(object = gst_child_proxy_get_child_by_index ((GstChildProxy *)element, i))) + continue; + + if (GST_IS_BIN (object)) { + ret = gst_element_query_resource ((GstElement *)object, resource_list); + gst_object_unref (object); + continue; + } + + ret = gst_element_query ((GstElement *) object, query); + if (ret) { + element_resource = gst_query_parse_resource (query); + resource_num = (int) atoi (element_resource); + GST_DEBUG_OBJECT (element, + "\n resource ID received after query is :%d\n", resource_num); + if (NULL == (g_list_find (*resource_list, (gconstpointer)resource_num))) { + *resource_list = + g_list_append (*resource_list, GINT_TO_POINTER (resource_num)); + } + } + gst_object_unref (object); + } + } else { + ret = gst_element_query ((GstElement *) element, query); + if (ret) { + element_resource = gst_query_parse_resource (query); + resource_num = (int) atoi (element_resource); + GST_DEBUG_OBJECT (element, "\n resource ID received after query is :%d\n", + resource_num); + if (NULL == (g_list_find (*resource_list, (gconstpointer)resource_num))) { + *resource_list = + g_list_append (*resource_list, GINT_TO_POINTER (resource_num)); + } + } + } + gst_query_unref (query); + return TRUE; +} + +static void +set_family_id (const GValue * item, gpointer user_data) +{ + gpointer object = g_value_get_object (item); + if (GST_IS_PAD (object)) { + GstPad *pad = GST_PAD_CAST (object); + g_object_set (G_OBJECT (pad), "family-id", (int) user_data, NULL); + } else if (GST_IS_ELEMENT (object)) { + gst_set_family_id_to_child (GST_ELEMENT_CAST (object), (int) user_data); + } + return; +} + +void +gst_set_family_id_to_child (GstElement * child, int id) +{ + GstIterator *it; + if (!GST_IS_ELEMENT (child)) + return; + g_object_set (G_OBJECT (child), "family-id", id, NULL); + it = gst_element_iterate_pads (child); + gst_iterator_foreach (it, (GstIteratorForeachFunction) set_family_id, + (gpointer) id); + gst_iterator_free (it); + it = NULL; + + if (!GST_IS_BIN (child)) + return; + it = gst_bin_iterate_recurse (GST_BIN (child)); + gst_iterator_foreach (it, (GstIteratorForeachFunction) set_family_id, + (gpointer) id); + gst_iterator_free (it); + it = NULL; + return; +} + +#endif + /** * gst_type_mark_as_plugin_api: * @type: a GType diff --cc subprojects/win-pkgconfig/download-binary.py index baca7d6ca8,baca7d6ca8..0000000000 deleted file mode 100644,100644 --- a/subprojects/win-pkgconfig/download-binary.py +++ /dev/null @@@ -1,61 -1,61 +1,0 @@@ --#!/usr/bin/env python3 -- --import os --import sys --import ssl --import zipfile --import hashlib --import urllib.request --import urllib.error -- --# Disable certificate checking because it always fails on Windows --# We verify the checksum anyway. --ctx = ssl.create_default_context() --ctx.check_hostname = False --ctx.verify_mode = ssl.CERT_NONE -- --BASENAME = 'pkg-config.zip' --GSTREAMER_URL = 'https://gstreamer.freedesktop.org/src/mirror/pkg-config.zip' -- --zip_sha256 = sys.argv[1] --source_dir = os.path.join( -- os.environ['MESON_SOURCE_ROOT'], os.environ['MESON_SUBDIR']) --dest = BASENAME --dest_path = os.path.join(source_dir, dest) -- -- --def get_sha256(zipf): -- hasher = hashlib.sha256() -- with open(zipf, 'rb') as f: -- hasher.update(f.read()) -- return hasher.hexdigest() -- -- --if os.path.isfile(dest_path): -- found_sha256 = get_sha256(dest_path) -- if found_sha256 == zip_sha256: -- print('{} already downloaded'.format(dest)) -- sys.exit(0) -- else: -- print('{} checksum mismatch, redownloading'.format(dest)) -- --url = GSTREAMER_URL.format(dest) --print('Downloading {} to {}'.format(GSTREAMER_URL.format(dest), dest)) --try: -- with open(dest_path, 'wb') as d: -- f = urllib.request.urlopen(url, context=ctx) -- d.write(f.read()) --except urllib.error.URLError as ex: -- curdir = os.path.dirname(sys.argv[0]) -- print('Couldn\'t download {!r}! Try downloading it manually and ' -- 'placing it into {!r}'.format(dest, curdir)) -- --found_sha256 = get_sha256(dest_path) --if found_sha256 != zip_sha256: -- print('SHA256 of downloaded file {} was {} instead of {}' -- ''.format(dest, found_sha256, zip_sha256)) -- sys.exit(1) -- --print('Extracting {}'.format(dest)) --zf = zipfile.ZipFile(dest_path, "r") --zf.extractall(path=source_dir) diff --cc subprojects/win-pkgconfig/meson.build index 79ee4d4d40,79ee4d4d40..0000000000 deleted file mode 100644,100644 --- a/subprojects/win-pkgconfig/meson.build +++ /dev/null @@@ -1,19 -1,19 +1,0 @@@ --project('win-pkgconfig', version : '0.29.2') -- --py3 = import('python3').find_python() -- --if host_machine.system() != 'windows' -- error('Can only download pkgconfig for Windows, sorry') --endif -- --message('Downloading pkg-config.exe binary for Windows...') -- --zip_hash = 'b74be141a53f193727fdcb33e9a052a38d9b79c6262326d264e502796b73dfe1' -- --ret = run_command(py3, files('download-binary.py'), zip_hash, check: true) --if ret.returncode() != 0 -- message(ret.stdout()) -- error(ret.stderr()) --endif -- --meson.override_find_program('pkg-config', find_program('pkg-config.exe'))