Commit graph

1451 commits

Author SHA1 Message Date
Jan Alexander Steffens (heftig)
e4a9db6abe x264enc: Strip trailing whitespace from x264's log messages
x264 has linebreaks at the end of its log messages that we should
ignore.

Add G_GNUC_PRINTF to the callback to make sure GCC lets us forward the
format string to another function marked as printf (g_strdup_vprintf)
without triggering -Wformat-nonliteral.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/85>
2021-09-21 17:50:26 +02:00
Jan Alexander Steffens (heftig)
de87e0d381 x264enc: Add the func/line info to the log callback
It looks awkward when it's missing. At least point us at the callback
function.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/85>
2021-09-21 15:38:04 +02:00
Jan Alexander Steffens (heftig)
de465be3e4 x264enc: Reduce log spam about bit depth support
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/85>
2021-09-21 15:17:59 +02:00
Stéphane Cerveau
fbe2ea6e38 mpeg2dec: drop B-frame on open gop
Enhance open gop detection to drop B-frame which are invalid
before the first reference frame.

In stream such
gst-integration-testsuites/medias/defaults/mxf/op2b-mpeg2-wave_hd.mxf,
the two first frames must be dropped as we detect an open GOP situation
but in another media, such as http://col.la/1920X1080IXDCAMEX5MIN, the
first frames should not be dropped as we are in a closed GOP situation.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/84>
2021-07-29 17:03:24 +02:00
Tim-Philipp Müller
cc1a7e2c4d Use g_memdup2() where available and add fallback for older GLib versions
- x264 encoder bitrate profile manager: alloc size is based
  on existing allocation
- asfdemux: change length var to 64-bit and check for G_MAXUINT
- realmedia: opaque_data_len is read from 32 bits and then
  only subtracted upon.

g_memdup() is deprecated since GLib 2.68 and we want to avoid
deprecation warnings with recent versions of GLib.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/83>
2021-06-02 12:39:53 +00:00
David Fernandez
828d1d0d18 x264enc: Change accepted caps width and height from [16, MAX] to [1, MAX]
There are cases where the video size might be less than 16x16.
This change allows the x264 encoder to accept this cases.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/44>
2021-05-05 16:29:13 -04:00
Stéphane Cerveau
62d914b5b4 x264: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Stéphane Cerveau
e3a35c127f sidplay: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Stéphane Cerveau
1b9f99d19f mpeg2dec: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Stéphane Cerveau
afa744b218 dvdread: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Stéphane Cerveau
3a42409898 cdio: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Stéphane Cerveau
4873c01b4a amrwbdec: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Stéphane Cerveau
d6055ac6d4 amrnb: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Stéphane Cerveau
a423f23fc7 a52dec: allow per feature registration
Split plugin into features including
dynamic types which can be indiviually
registered during a static build.

More details here:

https://gitlab.freedesktop.org/gstreamer/gst-build/-/merge_requests/199
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/661

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/79>
2021-03-29 19:13:36 +00:00
Matthew Waters
6399179d7a gst: don't use volatile to mean atomic
volatile is not sufficient to provide atomic guarantees and real atomics
should be used instead.  GCC 11 has started warning about using volatile
with atomic operations.

https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1719

Discovered in https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/868

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/78>
2021-03-19 15:17:05 +11:00
Sebastian Dröge
951e2604e7 x264: Update for gst_video_transfer_function_*() function renaming
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/68>
2020-09-07 12:14:13 +03:00
Sebastian Dröge
60337ffed9 x264enc: Allow maximum quantizer value of 63 instead of 51
QP_MAX_SPEC in x264 is set to 63 nowadays and in theory it allows even
up to 81 (QP_MAX) but that seems to be outside the spec.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/67>
2020-08-24 23:23:43 +01:00
Thibault Saunier
ed0470e81b x264enc: Add a 'Zero Latency' profile
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/42>
2020-07-23 21:05:40 -04:00
Jan Alexander Steffens (heftig)
05bb87ea0f x264enc: Separate high-10 video formats from 8-bit formats
If downstream is constrained to an 8-bit profile, caps queries would
still allow I420_10LE as input. If upstream actually sends such a caps
event, downstream would fail to accept the high-10 profile.

The following pipeline now fails earlier, during the negotiation phase
instead of the stream start:

    gst-launch-1.0 videotestsrc ! video/x-raw,format=I420_10LE \
        ! x264enc ! video/x-h264,profile=constrained-baseline \
        ! fakesink

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/59>
2020-07-21 15:41:52 +02:00
Thibault Saunier
de77207bfa x264enc: Forward downstream colorimetry and chroma-site upstream
So that the value can be used by upstream converters when necessary.

This whole logic has been copied from `__gst_video_element_proxy_caps`
but those 2 fields were missing.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/60>
2020-07-10 08:47:29 -04:00
Philippe Normand
84cebf9fab siddec: update gst_type_mark_as_plugin_api() calls
This was left behind in commit bc1ab5e8e0.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/55>
2020-06-06 10:15:25 +01:00
Mathieu Duponchelle
bc1ab5e8e0 plugins: uddate gst_type_mark_as_plugin_api() calls 2020-06-06 00:41:38 +02:00
Sebastian Dröge
dddf71b18d plugins: Use gst_type_mark_as_plugin_api() for all non-element plugin types 2020-06-03 22:44:20 -04:00
Guillaume Desmottes
887416db4b dvdreadsrc: fix uninitialized warning
Variable is always set in actual code paths but let's keep gcc happy.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/51>
2020-05-27 09:13:17 +02:00
Nirbheek Chauhan
8562bb304d meson: Pass native: false to add_languages()
This is needed for cross-compiling without a build machine compiler
available. The option was added in 0.54, but we only need this in
Cerbero and it doesn't affect older versions so it should be ok.
Will just cause a spurious warning.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/-/merge_requests/50>
2020-05-12 05:07:47 +05:30
Nicolas Dufresne
15440f2ddc x264enc: Fix 'ref' property range and default
The --ref option indicate the size of the DPB, hence should be in the range of
0 to 16. This patch also fix the default to match x264enc default 3. This
change isn't a behaviour change since we don't enforce the reported default.
2020-04-02 20:26:07 +00:00
Thibault Saunier
9b1e183256 a52dec: Mark as converter
It is able to do channel downminxing, so technically it is also a
converter

This is also important so validate knows about that when doing its
checks
2020-03-19 18:09:50 -03:00
Thibault Saunier
9273903286 x264enc: Respect Youtube bitrate recommandation
Properly follow google recommendations[0] concerning bitrate when the
user wants to use the youtube profile.

[0]: https://support.google.com/youtube/answer/1722171?hl=en
2020-01-07 21:21:42 +00:00
Stéphane Cerveau
a47b6b5f3c ugly: use of g_value_dup_string
Use helper method to get string from GValue.
2019-12-18 16:09:42 +01:00
Dmitry Shusharin
0dd89a1dd2 x264enc: fixed codestyle 2019-12-14 18:49:54 +07:00
Dmitry Shusharin
9d3b96e5f7 x264enc: corrected em_data value in CEA-708 CC SEI message (fixes #28)
Section 4.4 of CEA-708-D specification (table 2) requires all bits to be
set inside em_data field. h264parse element (and possible third-party
decoders such as libav) also follows this requirement.

https://gitlab.freedesktop.org/gstreamer/gst-plugins-ugly/issues/28
2019-12-14 17:24:33 +07:00
Tim-Philipp Müller
3cd445a490 Remove autotools build system 2019-10-13 14:19:11 +01:00
Aaron Boxer
3f24460e37 documentation: fix some typos 2019-09-02 09:33:15 -04:00
Mathieu Duponchelle
b3f0008b34 docstrings: port ulinks to markdown links 2019-08-23 19:06:59 +02:00
Seungha Yang
f31f085e7b x264enc: Port to color_{primaries,transfer,matrix}_to_iso
... with more color value mapping
2019-07-15 17:06:23 +00:00
Mathieu Duponchelle
dd96c2a989 doc: remove xml from comments 2019-05-29 23:00:48 +02:00
Thibault Saunier
21ac37c61a docs: Port documentation to hotdoc 2019-05-13 17:00:00 -04:00
Thibault Saunier
2df9f6e5ce docs: Port all docstring to gtk-doc markdown 2019-04-26 20:32:26 -04:00
Tim-Philipp Müller
e778c5594f meson: sidplay: use library() instead of shared_module()
Like we do for other plugins, and also install a .pc file
if we build the plugin statically.
2019-04-26 18:28:04 +01:00
Sebastian Dröge
8c994a632b meson: Always require the gmodule dependency
It's needed by the dvdread plugin but also by the x264 plugin in certain
circumstances. As it's part of GLib and always available, simply move it
as a hard dependency to the top-level meson.build.
2019-04-22 12:51:33 +03:00
Nirbheek Chauhan
647ef1b2af meson: Add a subproject fallback for x264 2019-03-27 21:59:45 +05:30
Mathieu Duponchelle
c4456d574f x264enc: inject CEA708 closed captions 2019-02-28 16:24:39 +01:00
Tim-Philipp Müller
ba08aa1c2f sidplay: fix indentation 2019-02-22 23:54:56 +00:00
Sebastian Dröge
aebb6bd9f3 dvdreadsrc: Work around GCC9 compiler warning
It's technically true but not for this specific type.

dvdreadsrc.c:394:65: error: taking address of packed member of ‘struct <anonymous>’ may result in an unaligned pointer value [-Werror=address-of-packed-member]
  394 |       gst_dvd_read_src_make_clut_change_event (src, src->cur_pgc->palette);
      |                                                     ~~~~~~~~~~~~^~~~~~~~~
2019-02-12 18:08:59 +02:00
Sebastian Dröge
2942f7d931 x264: Only enable dynamic loading code for x264 < 253
Otherwise we get some compiler warnings:

../subprojects/gst-plugins-ugly/ext/x264/gstx264enc.c:200:1: warning: ‘unload_x264’ defined but not used [-Wunused-function]
 unload_x264 (GstX264EncVTable * vtable)
 ^~~~~~~~~~~
../subprojects/gst-plugins-ugly/ext/x264/gstx264enc.c:154:1: warning: ‘load_x264’ defined but not used [-Wunused-function]
 load_x264 (const gchar * filename)
 ^~~~~~~~~
2019-01-25 14:38:05 +02:00
Sebastian Dröge
7ac2f7fec5 x264: Link to gmodule in the meson build if extra x264 libraries are provided
We would dynamically load additional x264 libraries then.
2019-01-25 14:36:55 +02:00
Seungha Yang
7e63943361 x264enc: Avoid format decision per frame
Avoid switch/case per frame for format decision and detect the format
only if where it could be changed. Note that, whenever encoder->input_state
is changed, gst_x264_enc_init_encoder() is called.

https://bugzilla.gnome.org/show_bug.cgi?id=797164
2018-09-22 12:42:34 +01:00
Jan Alexander Steffens (heftig)
cf385f20cf x264enc: Set bit depth for x264 ≥ 153
https://bugzilla.gnome.org/show_bug.cgi?id=796975
2018-08-16 16:43:01 +03:00
Jan Alexander Steffens (heftig)
484ee3e032 x264enc: Remove superfluous x264_param_default
https://bugzilla.gnome.org/show_bug.cgi?id=796973
2018-08-16 16:42:51 +03:00
Nirbheek Chauhan
c5cddfcec4 Add feature options for all plugins
The only automagic dependency left is C++ availability detection.

https://bugzilla.gnome.org/show_bug.cgi?id=795107
2018-07-27 19:34:01 +05:30