Commit graph

69 commits

Author SHA1 Message Date
Tim-Philipp Müller
4d3311566c dvdread, sidplay, x264enc: fix unused-but-set-variable warnings with gcc 4.6 2011-04-14 15:03:56 +01:00
Sebastian Dröge
e8d00e7334 x264enc: Implement getcaps function
This allows to set width/height/etc restrictions downstream.
2011-04-13 20:32:50 +02:00
Olivier Crête
62e35a6b40 x264enc: Allow changing the bitrate and quantitizers dynamically
https://bugzilla.gnome.org/show_bug.cgi?id=621663
2011-03-29 20:08:40 -04:00
Olivier Crête
a4df8f9031 x264enc: Set max bitrate in quality mode
https://bugzilla.gnome.org/show_bug.cgi?id=621663
2011-03-29 20:08:40 -04:00
Olivier Crête
1370f3f161 x264enc: Make it clear that constant quantizer is for debugging only
https://bugzilla.gnome.org/show_bug.cgi?id=621663
2011-03-29 20:08:40 -04:00
Sjoerd Simons
0d20df6d2b x264enc: Don't register flags with a value of 0
Flags with a value of 0 aren't meaningful and will cause
g_value_transform to go into an endless loop when trying to
convert the flags to a string
2011-02-14 17:52:12 +00:00
Miguel Angel Cabrera Moya
ead8d56f5f x264enc: make tag event writable before modifying tag list in place
To modify an event tag is necessary to be sure that x264enc
has its own copy.

Also fix indentation.

https://bugzilla.gnome.org/show_bug.cgi?id=640272
2011-01-24 13:07:08 +00:00
Thiago Santos
7b97c2de6a x264enc: Handle codec/encoder tags
Make x264enc drop video-codec and codec tags and replace
encoder/encoder-version with x264 and its build number

Fixes #621465
2011-01-04 10:37:26 -03:00
Tristan Matthews
71567bb0f9 x264: vbv-buf-capacity should have a minimum of 0
x264 will clip this value internally, and users should be allowed to
specify a lower value than 300 ms.

https://bugzilla.gnome.org/show_bug.cgi?id=635291
2010-12-29 18:32:57 +00:00
Tim-Philipp Müller
09bffa4be1 x264enc: also accept YV12 input 2010-12-27 11:38:24 +00:00
Mark Nauwelaerts
9f27fc1eec x264enc: add a note to the docs about encoder latency and queues
https://bugzilla.gnome.org/show_bug.cgi?id=636107
2010-12-26 22:11:52 +00:00
Robert Swain
6f2db739ae x264enc: Work around a rate control issue in libx264
When variable framerate is disabled in libx264 (which occurs when using
the zerolatency tuning), libx264 ignores timestamps but still uses the
timebase leading to messed up rate control with our nanosecond timebase.

We work around this issue by setting the timebase to the reciprocal of
the framerate and we validate that the framerate is suitable.

This has been fixed upstream in libx264 but there are non-fixed versions
in the wild so this workaround is still needed.

Fixes bug #632861
2010-10-22 15:55:34 +02:00
Stefan Kost
3bb4b5069e various (ext): add a missing G_PARAM_STATIC_STRINGS flags 2010-10-19 10:06:33 +03:00
Robert Swain
f45ff93586 x264enc: Fix b-pyramid libx264 API boolean arg for non-boolean issue
In X264_BUILD >= 78, b-pyramid became a non-boolean so passing a boolean
argument to the option string value causes an error. For < 78 we pass the
boolean value, for >= 78 we use the x264_b_pyramid_names[] array which will
result in passing 'none' for false and 'strict' for true. Other modes can be
set through the option-string property for now.

https://bugzilla.gnome.org/show_bug.cgi?id=626577
2010-08-11 16:47:12 +01:00
Tim-Philipp Müller
5225f5cc16 x264: fix printf format warning in debug message 2010-08-09 00:31:15 +01:00
Robert Swain
a441e5b6ef x264enc: Fix flushing of delayed frames
x264_encoder_encode() should be called with a NULL picture until at least
x264_encoder_delayed_frames() returns 0. This fixes what appeared to be a
regression in make check due to the recent change in defaults which enabled
b-frames and b-pyramid, both of which I believe increase the number of delayed
frames when encoding.
2010-07-30 09:59:08 +02:00
Robert Swain
60d647dcf5 x264enc: Improve x264enc defaults
- medium x264 speed/quality preset
- threads defaults to 0 which automatically uses 1.5x number of cpu cores

Addresses part of bug #607798
2010-07-26 14:29:02 +02:00
Robert Swain
30fff25b68 x264enc: Fix property description typos 2010-07-25 13:39:44 +02:00
Robert Swain
3554c95548 x264enc: Add some more debug info 2010-07-25 13:39:44 +02:00
Robert Swain
b27ce43ab8 x264enc: Add speed-preset and [psy-]tuning properties
Use of a rate control method (pass, bitrate, quantizer, etc properties), a
preset and possibly a profile and/or tuning are now the recommended way to
configure x264 through x264enc.

If a preset/tuning are specified then these will define the default values and
the property defaults will be ignored. After this the option-string property is
applied, followed by the user-set properties, fast first pass restrictions and
finally the profile restrictions.

Addresses part of bug #607798
2010-07-25 13:39:44 +02:00
Robert Swain
f269e0679f x264enc: Refactor code in preparation for presets/tunings
- Make defaults append the appropriate default value to a string. This is
  needed to differentiate between something user-set and the actual prop
  default.
- Add an internal option string to which _set_property () cases append for the
  majority of properties.
- Use gst_x264_enc_parse_options () to clean up application of settings. This
  will make order of application with respect to the presets and tunings quite
  simple.

Addresses part of bug #607798
2010-07-25 13:37:47 +02:00
Robert Swain
ac6b656ed3 x264enc: Update available me types
Use the x264_motion_est_names[] array to populate the enum of ME types. This is
now self-maintaining.
2010-07-25 13:37:47 +02:00
Robert Swain
d6f766d10f x264enc: Use new libx264 API to affect fast first pass
Uses new x264 API to apply reduced complexity values to the parameters to
increase encoding speed in the first pass of a multi-pass encode. This does
not impact on final quality.

Addresses part of bug #607798
2010-07-25 13:37:47 +02:00
Robert Swain
76cc4dbc07 x264enc: Add profile property
In X264_BUILD >= 86 there is a new API for applying restrictions to an H.264
Profile. This makes it easier to achieve Baseline Profile for example.

Addresses part of bug #607798
2010-07-25 13:37:45 +02:00
Robert Swain
f2be62695c x264enc: Add option-string property
Adds support for an x264 format option-string to specify advanced parameters

Addresses part of bug #607798
2010-07-23 09:35:48 +02:00
Mark Nauwelaerts
bd6d9402e0 x264enc: only set timebase on versions where it exists 2010-07-20 19:44:51 +02:00
David Hoyt
35f0e23a46 x264enc: set appropriate time base
Fixes #624786.
2010-07-20 16:44:46 +02:00
Mark Nauwelaerts
49f1373f1b x264enc: add new h264 caps attribute alignment
See #606662.
2010-06-22 11:42:18 +02:00
Mark Nauwelaerts
27025d0ebd x264enc: conditionally expose enhanced upstream capabilities
API: GstX264Enc:sliced-threads
API: GstX264Enc:sync-lookahead
API: GstX264Enc:intra-refresh
API: GstX264Enc:mb-tree
API: GstX264Enc:rc-lookahead

See #607798.
2010-06-18 18:47:49 +02:00
Olivier Crête
2339add6d5 x264enc: Only set i_weighted_pred on versions where it exists 2010-06-01 13:44:06 -04:00
Olivier Crête
d6df52f99a x264enc: disable I weighted pred
If it is enabled, then it will be main profile instead of baseline.
This ensures maximum compatibility of the output stream until the
encoder configuration interface gets an overhaul with explicit
output profile selection.

Fixes #619776.
2010-05-28 12:15:42 +01:00
Olivier Crête
7f685c4a21 x264enc: Re-send the received upstream event as-is downstream
https://bugzilla.gnome.org/show_bug.cgi?id=606689
2010-05-10 15:07:29 +02:00
Mark Nauwelaerts
d17388afa9 x264enc: adaptive x264 header NAL layout handling
Fixes #615410.
2010-04-19 10:39:34 +02:00
Mark Nauwelaerts
61643c7d89 x264enc: fix up avcC header construction
Fix off-by-one introduced by commit 35dd89951d
for BUILD_X264 < 76.

Also fixes #610089.
2010-04-13 16:55:58 +02:00
Mark Nauwelaerts
5fd1796fda x264enc: parameterize libx264 provided NAL layout in codec-data creation 2010-04-13 14:21:43 +02:00
Sebastian Dröge
c88c88de0d build: Add all kinds of compiler warning flags and fix the resulting warnings 2010-03-24 11:27:40 +01:00
Sebastian Dröge
43b366ce52 x264enc: Put pixel-aspect-ratio from input into the src pad caps
Fixes bug #612995.
2010-03-16 15:05:06 +01:00
Thiago Santos
96ee17e7b6 x264enc: Replace 'avc-sample' with 'avc' in caps
In the element and in its tests

Fixes #606662
2010-03-01 17:48:18 -03:00
Vittorio Palmisano
35dd89951d x264enc: fix up avcC header construction and playback by flash players
Fix off-by-one bug when constructing the avcC header chunk: we
wrote wrong profile info into the header. The first byte in the
SPS NAL we get from x264 is the nal type, not the profile_idc.

Also add some debug logging.

Fixes #610089.
2010-02-16 13:33:10 +00:00
Mark Nauwelaerts
8a1414694d x264enc: make use of Access Unit delimiters configurable
API: GstX264Enc:aud
2010-01-29 19:47:03 +01:00
Thiago Santos
c77dfa7b9f x264enc: Add stream-format to output caps
Adds stream-format to output caps of x264enc that
informs if the stream is in bytestream of avc format.

Fixes #606662
2010-01-13 10:17:44 -03:00
Olivier Crête
b7f37f9afb x264enc: Make upstream GstForceKeyUnit thread-safe
Also send the GstForceKeyUnit event downstream when an upstream on is received,
allowing muxers or payloaders to take appropriate actions.

https://bugzilla.gnome.org/show_bug.cgi?id=602556
2009-11-20 22:15:22 -05:00
Robert Swain
0a36965808 x264enc: Adapt to slightly modified x264 API
Fixes #599095.
2009-10-26 21:52:36 +01:00
Mark Nauwelaerts
8ef48af93b x264enc: conditionally adjust to new upstream API
Fixes #596517.
2009-10-01 19:01:27 +02:00
Tim-Philipp Müller
0e285b3d29 x264enc, rdtmanager: fix compilation with debugging disabled 2009-06-19 15:01:46 +01:00
Wim Taymans
0823e9fa14 [MOVED FROM BAD 28/28] x264enc: add multipass-cache-file property
Fixes #583627
2009-06-05 18:48:27 +01:00
Christian Schaller
bc8f9f9a8b [MOVED FROM BAD 25/28] Add ranks to various muxers and encoders in -bad 2009-06-05 18:48:26 +01:00
Stefan Kost
811ddb9cdc [MOVED FROM BAD 24/28] x264enc: add preset support
Add preset iface and a (dummy) preset file as a starting point.
2009-06-05 18:48:26 +01:00
Mark Nauwelaerts
cd86b39a94 [MOVED FROM BAD 23/28] x264enc: add some documentation on profile 2009-06-05 18:48:26 +01:00
Janin Kolenc
5a45501fc9 [MOVED FROM BAD 22/28] x264enc: add force keyframe event handling
Use the GstForceKeyUnit event to force a keyframe.
Fixes #578112.
2009-06-05 18:48:26 +01:00