Moved 'x264enc' from -bad to -ugly

This commit is contained in:
Jan Schmidt 2009-06-05 19:32:26 +01:00
parent 4d9a0e832c
commit 271788c9ae
13 changed files with 1 additions and 1593 deletions

View file

@ -1359,29 +1359,6 @@ AG_GST_CHECK_FEATURE(THEORADEC, [ogg theora codec], theoraexpdec, [
AC_SUBST(THEORADEC_CFLAGS) AC_SUBST(THEORADEC_CFLAGS)
]) ])
dnl *** x264 (MPEG-4 part 10/h.264/AVC encoder) ***
translit(dnm, m, l) AM_CONDITIONAL(USE_X264, true)
AG_GST_CHECK_FEATURE(X264, [x264 plug-in], x264, [
AG_GST_CHECK_LIBHEADER(X264, x264, x264_nal_encode, -lm, x264.h,
AC_MSG_CHECKING([for uptodate x264 API version])
dnl _stdint not yet generated, so no compiling
AC_TRY_CPP([
#include <x264.h>
#if X264_BUILD < 55
#error "x264 build too old"
#endif
], [
AC_MSG_RESULT(yes)
X264_LIBS="$LDFLAGS -lx264 -lm"
X264_CFLAGS="$CFLAGS"
AC_SUBST(X264_LIBS)
AC_SUBST(X264_CFLAGS)
], [
AC_MSG_RESULT(no)
HAVE_X264=no
]))
])
dnl *** XVID *** dnl *** XVID ***
translit(dnm, m, l) AM_CONDITIONAL(USE_XVID, true) translit(dnm, m, l) AM_CONDITIONAL(USE_XVID, true)
AG_GST_CHECK_FEATURE(XVID, [xvid plugins], xvid, [ AG_GST_CHECK_FEATURE(XVID, [xvid plugins], xvid, [
@ -1494,7 +1471,6 @@ AM_CONDITIONAL(USE_SPC, false)
AM_CONDITIONAL(USE_SWFDEC, false) AM_CONDITIONAL(USE_SWFDEC, false)
AM_CONDITIONAL(USE_THEORADEC, false) AM_CONDITIONAL(USE_THEORADEC, false)
AM_CONDITIONAL(USE_TIMIDITY, false) AM_CONDITIONAL(USE_TIMIDITY, false)
AM_CONDITIONAL(USE_X264, false)
AM_CONDITIONAL(USE_XVID, false) AM_CONDITIONAL(USE_XVID, false)
AM_CONDITIONAL(USE_WILDMIDI, false) AM_CONDITIONAL(USE_WILDMIDI, false)
AM_CONDITIONAL(USE_WININET, false) AM_CONDITIONAL(USE_WININET, false)
@ -1680,7 +1656,6 @@ ext/spc/Makefile
ext/swfdec/Makefile ext/swfdec/Makefile
ext/theora/Makefile ext/theora/Makefile
ext/timidity/Makefile ext/timidity/Makefile
ext/x264/Makefile
ext/xvid/Makefile ext/xvid/Makefile
po/Makefile.in po/Makefile.in
docs/Makefile docs/Makefile

View file

@ -115,7 +115,6 @@ EXTRA_HFILES = \
$(top_srcdir)/ext/theora/theoradec.h \ $(top_srcdir)/ext/theora/theoradec.h \
$(top_srcdir)/ext/timidity/gsttimidity.h \ $(top_srcdir)/ext/timidity/gsttimidity.h \
$(top_srcdir)/ext/timidity/gstwildmidi.h \ $(top_srcdir)/ext/timidity/gstwildmidi.h \
$(top_srcdir)/ext/x264/gstx264enc.h \
$(top_srcdir)/gst/aacparse/gstaacparse.h \ $(top_srcdir)/gst/aacparse/gstaacparse.h \
$(top_srcdir)/gst/amrparse/gstamrparse.h \ $(top_srcdir)/gst/amrparse/gstamrparse.h \
$(top_srcdir)/gst/autoconvert/gstautoconvert.h \ $(top_srcdir)/gst/autoconvert/gstautoconvert.h \

View file

@ -84,7 +84,6 @@
<xi:include href="xml/element-videomark.xml" /> <xi:include href="xml/element-videomark.xml" />
<xi:include href="xml/element-videoparse.xml" /> <xi:include href="xml/element-videoparse.xml" />
<xi:include href="xml/element-wildmidi.xml" /> <xi:include href="xml/element-wildmidi.xml" />
<xi:include href="xml/element-x264enc.xml" />
</chapter> </chapter>
<chapter> <chapter>
@ -163,7 +162,6 @@
<xi:include href="xml/plugin-videosignal.xml" /> <xi:include href="xml/plugin-videosignal.xml" />
<xi:include href="xml/plugin-vmnc.xml" /> <xi:include href="xml/plugin-vmnc.xml" />
<xi:include href="xml/plugin-wildmidi.xml" /> <xi:include href="xml/plugin-wildmidi.xml" />
<xi:include href="xml/plugin-x264.xml" />
<xi:include href="xml/plugin-xvid.xml" /> <xi:include href="xml/plugin-xvid.xml" />
</chapter> </chapter>

View file

@ -1026,19 +1026,6 @@ GST_IS_WILDMIDI_CLASS
GST_TYPE_WILDMIDI GST_TYPE_WILDMIDI
</SECTION> </SECTION>
<SECTION>
<FILE>element-x264enc</FILE>
<TITLE>x264enc</TITLE>
GstX264Enc
<SUBSECTION Standard>
GstX264EncClass
GST_X264_ENC
GST_X264_ENC_CLASS
GST_IS_X264_ENC
GST_IS_X264_ENC_CLASS
GST_TYPE_X264_ENC
</SECTION>
<SECTION> <SECTION>
<FILE>element-mimdec</FILE> <FILE>element-mimdec</FILE>
<TITLE>mimdec</TITLE> <TITLE>mimdec</TITLE>

View file

@ -1,34 +0,0 @@
<plugin>
<name>x264</name>
<description>libx264-based H264 plugins</description>
<filename>../../ext/x264/.libs/libgstx264.so</filename>
<basename>libgstx264.so</basename>
<version>0.10.12.1</version>
<license>GPL</license>
<source>gst-plugins-bad</source>
<package>GStreamer Bad Plug-ins git/prerelease</package>
<origin>Unknown package origin</origin>
<elements>
<element>
<name>x264enc</name>
<longname>x264enc</longname>
<class>Codec/Encoder/Video</class>
<description>H264 Encoder</description>
<author>Josef Zlomek &lt;josef.zlomek@itonis.tv&gt;, Mark Nauwelaerts &lt;mnauw@users.sf.net&gt;</author>
<pads>
<caps>
<name>sink</name>
<direction>sink</direction>
<presence>always</presence>
<details>video/x-raw-yuv, format=(fourcc)I420, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 16, 2147483647 ], height=(int)[ 16, 2147483647 ]</details>
</caps>
<caps>
<name>src</name>
<direction>source</direction>
<presence>always</presence>
<details>video/x-h264, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ]</details>
</caps>
</pads>
</element>
</elements>
</plugin>

View file

@ -312,12 +312,6 @@ endif
TARKIN_DIR= TARKIN_DIR=
# endif # endif
if USE_X264
X264_DIR=x264
else
X264_DIR=
endif
# if USE_XINE # if USE_XINE
# XINE_DIR=xine # XINE_DIR=xine
# else # else
@ -382,7 +376,6 @@ SUBDIRS=\
$(TARKIN_DIR) \ $(TARKIN_DIR) \
$(THEORA_DIR) \ $(THEORA_DIR) \
$(TIMIDITY_DIR) \ $(TIMIDITY_DIR) \
$(X264_DIR) \
$(XINE_DIR) \ $(XINE_DIR) \
$(XVID_DIR) $(XVID_DIR)
@ -426,5 +419,4 @@ DIST_SUBDIRS = \
swfdec \ swfdec \
theora \ theora \
timidity \ timidity \
x264 \
xvid xvid

View file

@ -1,44 +0,0 @@
[_presets_]
version=0.10
element-name=GstX264Enc
[Profile Baseline]
_meta/comment=Baseline Profile
bframes=0
cabac=false
dct8x8=false
[Profile Main]
_meta/comment=Main Profile
cabac=true
dct8x8=false
[Profile High]
_meta/comment=High Profile
cabac=true
dct8x8=true
[Quality Low]
_meta/comment=Low quality
pass=qual
quantizer=27
subme=4
threads=0
[Quality Normal]
_meta/comment=Normal quality
pass=qual
quantizer=21
me=umh
subme=6
ref=3
threads=0
[Quality High]
_meta/comment=High quality
pass=qual
quantizer=18
me=umh
subme=6
ref=3
threads=0

View file

@ -1,21 +0,0 @@
plugin_LTLIBRARIES = libgstx264.la
libgstx264_la_SOURCES = gstx264enc.c
libgstx264_la_CFLAGS = \
$(GST_PLUGINS_BASE_CFLAGS) \
$(GST_CFLAGS) \
$(X264_CFLAGS)
libgstx264_la_LIBADD = \
$(GST_PLUGINS_BASE_LIBS) -lgstvideo-$(GST_MAJORMINOR) \
$(GST_LIBS) \
$(X264_LIBS)
libgstx264_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
libgstx264_la_LIBTOOLFLAGS = --tag=disable-static
noinst_HEADERS = gstx264enc.h
presetdir = $(datadir)/gstreamer-$(GST_MAJORMINOR)/presets
preset_DATA = GstX264Enc.prs
EXTRA_DIST = $(preset_DATA)

File diff suppressed because it is too large Load diff

View file

@ -1,110 +0,0 @@
/* GStreamer H264 encoder plugin
* Copyright (C) 2005 Michal Benes <michal.benes@itonis.tv>
* Copyright (C) 2005 Josef Zlomek <josef.zlomek@itonis.tv>
*
* 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., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#ifndef __GST_X264_ENC_H__
#define __GST_X264_ENC_H__
#include <gst/gst.h>
#include <gst/video/video.h>
#include "_stdint.h"
#include <x264.h>
G_BEGIN_DECLS
#define GST_TYPE_X264_ENC \
(gst_x264_enc_get_type())
#define GST_X264_ENC(obj) \
(G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_X264_ENC,GstX264Enc))
#define GST_X264_ENC_CLASS(klass) \
(G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_X264_ENC,GstX264EncClass))
#define GST_IS_X264_ENC(obj) \
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_X264_ENC))
#define GST_IS_X264_ENC_CLASS(klass) \
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_X264_ENC))
typedef struct _GstX264Enc GstX264Enc;
typedef struct _GstX264EncClass GstX264EncClass;
struct _GstX264Enc
{
GstElement element;
/*< private >*/
GstPad *sinkpad;
GstPad *srcpad;
x264_t *x264enc;
x264_param_t x264param;
/* properties */
guint threads;
gint pass;
guint quantizer;
gchar *mp_cache_file;
gboolean byte_stream;
guint bitrate;
gint me;
guint subme;
guint analyse;
gboolean dct8x8;
guint ref;
guint bframes;
gboolean b_adapt;
gboolean b_pyramid;
gboolean weightb;
guint sps_id;
gboolean trellis;
guint vbv_buf_capacity;
guint keyint_max;
gboolean cabac;
gfloat ip_factor;
gfloat pb_factor;
guint qp_min;
guint qp_max;
guint qp_step;
guint noise_reduction;
gboolean interlaced;
/* input description */
GstVideoFormat format;
gint width, height;
gint fps_num, fps_den;
gint par_num, par_den;
/* cache some format properties */
gint stride[4], offset[4];
gint image_size;
/* for b-frame delay handling */
GQueue *delay;
guint8 *buffer;
gulong buffer_size;
gint i_type;
};
struct _GstX264EncClass
{
GstElementClass parent_class;
};
G_END_DECLS
#endif /* __GST_X264_ENC_H__ */

View file

@ -31,7 +31,6 @@ BuildRequires: gcc-c++
@USE_GSM_TRUE@Provides: gstreamer-gsm = %{version}-%{release} @USE_GSM_TRUE@Provides: gstreamer-gsm = %{version}-%{release}
@USE_LIBMMS_TRUE@Requires: libmms >= 0.1 @USE_LIBMMS_TRUE@Requires: libmms >= 0.1
@USE_MYTHTV_TRUE@Requires: gmyth @USE_MYTHTV_TRUE@Requires: gmyth
@USE_X264_TRUE@Requires: x264
%description %description
GStreamer is a streaming media framework, based on graphs of filters which GStreamer is a streaming media framework, based on graphs of filters which
@ -133,7 +132,6 @@ rm -rf $RPM_BUILD_ROOT
%{_libdir}/gstreamer-%{majorminor}/libgstcamerabin.so %{_libdir}/gstreamer-%{majorminor}/libgstcamerabin.so
%{_libdir}/libgstphotography-%{majorminor}.so.0 %{_libdir}/libgstphotography-%{majorminor}.so.0
%{_libdir}/libgstphotography-%{majorminor}.so.0.0.0 %{_libdir}/libgstphotography-%{majorminor}.so.0.0.0
%{_datadir}/gstreamer-%{majorminor}/presets/GstX264Enc.prs
# %{_datadir}/gstreamer-%{majorminor}/presets/GstFAAC.prs # %{_datadir}/gstreamer-%{majorminor}/presets/GstFAAC.prs
# gstreamer-plugins with external dependencies but in the main package # gstreamer-plugins with external dependencies but in the main package
@USE_FAAD_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstfaad.so @USE_FAAD_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstfaad.so
@ -152,7 +150,6 @@ rm -rf $RPM_BUILD_ROOT
@USE_DTS_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstdtsdec.so @USE_DTS_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstdtsdec.so
@USE_LADSPA_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstladspa.so @USE_LADSPA_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstladspa.so
@USE_MYTHTV_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstmythtvsrc.so @USE_MYTHTV_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstmythtvsrc.so
@USE_X264_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstx264.so
@USE_DC1394_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstdc1394.so @USE_DC1394_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstdc1394.so
@USE_TIMIDITY_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgsttimidity.so @USE_TIMIDITY_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgsttimidity.so
@USE_WILDMIDI_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstwildmidi.so @USE_WILDMIDI_TRUE@%{_libdir}/gstreamer-%{majorminor}/libgstwildmidi.so

View file

@ -63,17 +63,9 @@ else
check_timidity= check_timidity=
endif endif
if USE_X264
check_x264enc=elements/x264enc
else
check_x264enc=
endif
VALGRIND_TO_FIX = \ VALGRIND_TO_FIX = \
elements/mpeg2enc \ elements/mpeg2enc \
elements/mplex \ elements/mplex
elements/x264enc
# valgrind testing # valgrind testing
VALGRIND_TESTS_DISABLE = \ VALGRIND_TESTS_DISABLE = \
@ -86,7 +78,6 @@ check_PROGRAMS = \
$(check_neon) \ $(check_neon) \
$(check_ofa) \ $(check_ofa) \
$(check_timidity) \ $(check_timidity) \
$(check_x264enc) \
elements/aacparse \ elements/aacparse \
elements/amrparse \ elements/amrparse \
elements/camerabin \ elements/camerabin \

View file

@ -26,5 +26,4 @@ videocrop
wavpackdec wavpackdec
wavpackenc wavpackenc
wavpackparse wavpackparse
x264enc
y4menc y4menc