vlc.git
4 years agomacosx: Add helper to set rd item demux filter
Marvin Scholz [Wed, 12 Jul 2017 21:03:37 +0000 (23:03 +0200)]
macosx: Add helper to set rd item demux filter

4 years agochannel_mixer: headphone: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:05:27 +0000 (19:05 +0200)]
channel_mixer: headphone: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agochannel_mixer: mono: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:05:18 +0000 (19:05 +0200)]
channel_mixer: mono: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agochorus_flanger: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:05:05 +0000 (19:05 +0200)]
chorus_flanger: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agocompressor: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:04:57 +0000 (19:04 +0200)]
compressor: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agoequalizer: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:04:48 +0000 (19:04 +0200)]
equalizer: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agokaraoke: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:04:39 +0000 (19:04 +0200)]
karaoke: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agonormvol: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:04:32 +0000 (19:04 +0200)]
normvol: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agoscaletempo: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:04:22 +0000 (19:04 +0200)]
scaletempo: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agoaudiobargraph: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 17:03:36 +0000 (19:03 +0200)]
audiobargraph: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agospatializer: prepare format on success
Thomas Guillem [Wed, 12 Jul 2017 16:59:34 +0000 (18:59 +0200)]
spatializer: prepare format on success

This fixes a i_bytes_per_frame/i_frame_length inconsistency when chaining more
than one audio filters.

4 years agoaout: filters: assert that audio converter/resamplers are const
Thomas Guillem [Wed, 12 Jul 2017 16:57:38 +0000 (18:57 +0200)]
aout: filters: assert that audio converter/resamplers are const

4 years agochannel_mixer: remap: don't modify fmt on error
Thomas Guillem [Wed, 12 Jul 2017 16:51:51 +0000 (18:51 +0200)]
channel_mixer: remap: don't modify fmt on error

4 years agochannel_mixer: mono: don't modify fmt on error
Thomas Guillem [Wed, 12 Jul 2017 16:36:12 +0000 (18:36 +0200)]
channel_mixer: mono: don't modify fmt on error

4 years agogl: vaapi: favor display backend
Thomas Guillem [Wed, 12 Jul 2017 15:36:16 +0000 (17:36 +0200)]
gl: vaapi: favor display backend

Mainly to assure that we use the same card as the display.

4 years agogl: don't do direct rendering below OpenGL 3.0
Thomas Guillem [Wed, 12 Jul 2017 13:50:34 +0000 (15:50 +0200)]
gl: don't do direct rendering below OpenGL 3.0

See comments.

4 years agoaout: hide aout_ChannelsRestart callback
Thomas Guillem [Tue, 11 Jul 2017 10:58:24 +0000 (12:58 +0200)]
aout: hide aout_ChannelsRestart callback

4 years agovlc_fourcc: add a define for "XAJ\00" (EA ADPCM)
Steve Lhomme [Thu, 6 Jul 2017 14:28:34 +0000 (16:28 +0200)]
vlc_fourcc: add a define for "XAJ\00" (EA ADPCM)

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agorawvideo: only copy the input es_format_t on output for the decoder
Steve Lhomme [Tue, 11 Jul 2017 09:19:49 +0000 (11:19 +0200)]
rawvideo: only copy the input es_format_t on output for the decoder

It's automatically done for packetizers.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agopacketizer:copy: set the codec id on fmt_out when everything is correct
Steve Lhomme [Mon, 10 Jul 2017 14:36:22 +0000 (16:36 +0200)]
packetizer:copy: set the codec id on fmt_out when everything is correct

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomodules:decoders: only set the codec ID rather than init the whole ES format
Steve Lhomme [Mon, 10 Jul 2017 14:14:03 +0000 (16:14 +0200)]
modules:decoders: only set the codec ID rather than init the whole ES format

It's already initialized when the decoder is created.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomodules:decoders: fill the fmt_out only when everything is OK
Steve Lhomme [Mon, 10 Jul 2017 14:07:41 +0000 (16:07 +0200)]
modules:decoders: fill the fmt_out only when everything is OK

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agocvdsub: fix the codec ID on the packetizer output
Steve Lhomme [Mon, 10 Jul 2017 14:20:13 +0000 (16:20 +0200)]
cvdsub: fix the codec ID on the packetizer output

All other decoders that also double as a packetizer do this.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agopacketizer:dts: code cleaning
Steve Lhomme [Mon, 10 Jul 2017 14:23:13 +0000 (16:23 +0200)]
packetizer:dts: code cleaning

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agocodec:aom: code cleaning
Steve Lhomme [Mon, 10 Jul 2017 14:06:26 +0000 (16:06 +0200)]
codec:aom: code cleaning

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomux:asf: make use of the local variable
Steve Lhomme [Mon, 10 Jul 2017 11:52:02 +0000 (13:52 +0200)]
mux:asf: make use of the local variable

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomux:mpeg:ts: use the read-only input format
Steve Lhomme [Mon, 10 Jul 2017 11:45:32 +0000 (13:45 +0200)]
mux:mpeg:ts: use the read-only input format

only the core can touch it

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomux:ogg: the sout input format is read-only
Steve Lhomme [Mon, 10 Jul 2017 11:44:50 +0000 (13:44 +0200)]
mux:ogg: the sout input format is read-only

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomux:avformat: the sout input format is read-only
Steve Lhomme [Mon, 10 Jul 2017 11:43:49 +0000 (13:43 +0200)]
mux:avformat: the sout input format is read-only

4 years agopacketizer:copy: fix unchecked memory allocation
Steve Lhomme [Mon, 10 Jul 2017 14:21:27 +0000 (16:21 +0200)]
packetizer:copy: fix unchecked memory allocation

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomux:mpeg:ps: fix unchecked memory allocation
Steve Lhomme [Mon, 10 Jul 2017 11:41:21 +0000 (13:41 +0200)]
mux:mpeg:ps: fix unchecked memory allocation

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomux:asf: fix unchecked memory allocation
Steve Lhomme [Mon, 10 Jul 2017 11:40:50 +0000 (13:40 +0200)]
mux:asf: fix unchecked memory allocation

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:aiff: init the ES to "twos" directly
Steve Lhomme [Mon, 10 Jul 2017 09:30:50 +0000 (11:30 +0200)]
demux:aiff: init the ES to "twos" directly

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:mjpeg: init the ES to VLC_CODEC_MJPG directly
Steve Lhomme [Mon, 10 Jul 2017 09:29:50 +0000 (11:29 +0200)]
demux:mjpeg: init the ES to VLC_CODEC_MJPG directly

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux: mpegv: no need to initialize the es_format_t twice
Steve Lhomme [Mon, 10 Jul 2017 08:13:24 +0000 (10:13 +0200)]
demux: mpegv: no need to initialize the es_format_t twice

It won't be modified during the demux_PacketizerNew() call.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agots_sl: remove no-op
Steve Lhomme [Mon, 10 Jul 2017 08:10:21 +0000 (10:10 +0200)]
ts_sl: remove no-op

The string is already freed and reset in es_format_Clean().

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agorawaud: initialize the ES directly with the known codec
Steve Lhomme [Mon, 10 Jul 2017 08:07:01 +0000 (10:07 +0200)]
rawaud: initialize the ES directly with the known codec

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agovlm: don't use a variable outside of its scope
Steve Lhomme [Mon, 10 Jul 2017 07:59:01 +0000 (09:59 +0200)]
vlm: don't use a variable outside of its scope

item.es is set to the address holding the address of es and use outside of the
code where es was declared.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomft: use video_format_Copy() instead of plain structure copy
Steve Lhomme [Mon, 10 Jul 2017 14:15:55 +0000 (16:15 +0200)]
mft: use video_format_Copy() instead of plain structure copy

If there is a palette we don't want to use the same pointer otherwise there
will be a double free.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agoimage: use es_format_Copy() instead of plain structure copy
Steve Lhomme [Mon, 10 Jul 2017 07:54:27 +0000 (09:54 +0200)]
image: use es_format_Copy() instead of plain structure copy

There's potentially double free when calling es_format_Clean() on the copied
structure.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:avformat: strip libavformat always matching tests
Steve Lhomme [Fri, 7 Jul 2017 07:24:09 +0000 (09:24 +0200)]
demux:avformat: strip libavformat always matching tests

We require libavformat >= 57 now.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agoextract: make the get_custom_from_yuv declaration match the definition
Steve Lhomme [Wed, 12 Jul 2017 09:20:48 +0000 (11:20 +0200)]
extract: make the get_custom_from_yuv declaration match the definition

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agovlc_services_discovery: don't return void
Steve Lhomme [Wed, 12 Jul 2017 09:20:47 +0000 (11:20 +0200)]
vlc_services_discovery: don't return void

Even though the compiler is OK with it.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agocontrib:gcrypt: update gcrypt to 1.7.8
Steve Lhomme [Wed, 12 Jul 2017 06:06:24 +0000 (08:06 +0200)]
contrib:gcrypt: update gcrypt to 1.7.8

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agomacosx: Fix image tinting
Marvin Scholz [Wed, 12 Jul 2017 00:53:09 +0000 (02:53 +0200)]
macosx: Fix image tinting

This fixes the image tinting used in VLCTintedImageButtonCell, images
are now tinted correctly.

4 years agovout: opengl: resize fmt to the max size the HW can handle
Victorien Le Couviour--Tuffet [Fri, 7 Jul 2017 15:19:30 +0000 (17:19 +0200)]
vout: opengl: resize fmt to the max size the HW can handle

This fixes the issue #18215 for Linux, MacOS and Windows when using OpenGL
vout, as well as the issue #18214.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodirect3d11: handle the source orientation in flat projection
Steve Lhomme [Tue, 11 Jul 2017 14:24:18 +0000 (16:24 +0200)]
direct3d11: handle the source orientation in flat projection

Fixes #18477

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodirect3d11: fix the non-RGB texture creation with odd dimensions
Steve Lhomme [Tue, 11 Jul 2017 14:24:17 +0000 (16:24 +0200)]
direct3d11: fix the non-RGB texture creation with odd dimensions

This case happens when decoding when decoding in software. For example a JPEG.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agommdevice: handle AUDCLNT_E_ALREADY_INITIALIZED
Thomas Guillem [Wed, 5 Jul 2017 16:38:03 +0000 (18:38 +0200)]
mmdevice: handle AUDCLNT_E_ALREADY_INITIALIZED

Sadly, this error can happen even if the "aout stream" was well stopped. See
MSDN comments in the commit.

Add DeviceRestartLocked() that fetch a new instance of the current IMMDevice.

4 years agommdevice: rename variables
Thomas Guillem [Wed, 5 Jul 2017 16:36:17 +0000 (18:36 +0200)]
mmdevice: rename variables

Add a requested prefix.

4 years agodemux: adaptive: inflate streamUrl streams
Francois Cartegnie [Tue, 11 Jul 2017 10:19:38 +0000 (12:19 +0200)]
demux: adaptive: inflate streamUrl streams

4 years agospdif: don't reset fmt_out on error
Thomas Guillem [Mon, 10 Jul 2017 17:14:20 +0000 (19:14 +0200)]
spdif: don't reset fmt_out on error

4 years agomad: don't reset fmt_out on error
Thomas Guillem [Mon, 10 Jul 2017 17:14:14 +0000 (19:14 +0200)]
mad: don't reset fmt_out on error

4 years agodca: don't reset fmt_out on error
Thomas Guillem [Mon, 10 Jul 2017 17:14:10 +0000 (19:14 +0200)]
dca: don't reset fmt_out on error

4 years agoa52: don't reset fmt_out on error
Thomas Guillem [Mon, 10 Jul 2017 17:14:06 +0000 (19:14 +0200)]
a52: don't reset fmt_out on error

4 years agochromecast: Rename b_has_video -> b_supports_video
Hugo Beauzée-Luyssen [Mon, 10 Jul 2017 16:19:21 +0000 (18:19 +0200)]
chromecast: Rename b_has_video -> b_supports_video

4 years agovout: win32: CommonControl: Allow some controls on UWP/WinRT
Hugo Beauzée-Luyssen [Mon, 10 Jul 2017 16:02:01 +0000 (18:02 +0200)]
vout: win32: CommonControl: Allow some controls on UWP/WinRT

4 years agocodec: avcodec: supports output with channels > AOUT_CHAN_MAX
Thomas Guillem [Fri, 7 Jul 2017 10:59:24 +0000 (12:59 +0200)]
codec: avcodec: supports output with channels > AOUT_CHAN_MAX

If the channel number is higher than AOUT_CHAN_MAX, don't set the physical
mask, and just set the number of channels. A filter will take of dropping extra
channels or doing an ambisonics conversion.

4 years agocodec: araw: supports output with channels > AOUT_CHAN_MAX
Thomas Guillem [Fri, 7 Jul 2017 09:46:16 +0000 (11:46 +0200)]
codec: araw: supports output with channels > AOUT_CHAN_MAX

If the channel number is higher than AOUT_CHAN_MAX, don't set the physical
mask, and just set the number of channels. A filter will take of dropping extra
channels or doing an ambisonics conversion.

4 years agodemux: wav: supports inputs with channels > AOUT_CHAN_MAX
Thomas Guillem [Fri, 7 Jul 2017 09:45:38 +0000 (11:45 +0200)]
demux: wav: supports inputs with channels > AOUT_CHAN_MAX

If the channel number is higher than AOUT_CHAN_MAX, don't set the physical
mask, and just set the number of channels. A filter will take of dropping
extra channels or doing an ambisonics conversion.

4 years agoaout: add an extra assert
Thomas Guillem [Sat, 1 Jul 2017 15:48:50 +0000 (17:48 +0200)]
aout: add an extra assert

An aout module need to set up valid physical channels.

4 years agoaout: an unknown chan mask is not an error
Thomas Guillem [Mon, 10 Jul 2017 14:46:34 +0000 (16:46 +0200)]
aout: an unknown chan mask is not an error

4 years agoaout: add support for unknown channel layout
Thomas Guillem [Fri, 7 Jul 2017 09:30:43 +0000 (11:30 +0200)]
aout: add support for unknown channel layout

If the input doesn't have a valid channel layout, use the wave one and drop
extra channels via the trivial mixer.

4 years agoes: add INPUT_CHAN_MAX
Thomas Guillem [Mon, 10 Jul 2017 11:30:18 +0000 (13:30 +0200)]
es: add INPUT_CHAN_MAX

4 years agotrivial: add support for unknown channel layout
Thomas Guillem [Fri, 7 Jul 2017 09:41:48 +0000 (11:41 +0200)]
trivial: add support for unknown channel layout

This is trivial, we just extract/drop channels in the wg4 order.

4 years agosrc: don't require a valid channel layout
Thomas Guillem [Fri, 7 Jul 2017 09:40:58 +0000 (11:40 +0200)]
src: don't require a valid channel layout

4 years agougly: don't require a valid channel layout
Thomas Guillem [Fri, 7 Jul 2017 09:40:18 +0000 (11:40 +0200)]
ugly: don't require a valid channel layout

4 years agospeex: don't require a valid channel layout
Thomas Guillem [Fri, 7 Jul 2017 09:40:07 +0000 (11:40 +0200)]
speex: don't require a valid channel layout

4 years agosoxr: don't require a valid channel layout
Thomas Guillem [Fri, 7 Jul 2017 09:39:58 +0000 (11:39 +0200)]
soxr: don't require a valid channel layout

4 years agobandlimited: don't require a valid channel layout
Thomas Guillem [Fri, 7 Jul 2017 09:39:44 +0000 (11:39 +0200)]
bandlimited: don't require a valid channel layout

4 years agohw: vaapi: chroma: don't keep fallback image
Thomas Guillem [Mon, 10 Jul 2017 13:53:02 +0000 (15:53 +0200)]
hw: vaapi: chroma: don't keep fallback image

Fix vlc_vaapi_DestroyImage() called on an invalid vadpy. Keep it simpler as
this case is the worst case scenario and shouldn't happen unless if forced by
the user.

PS: contrary to other vaapi filters, the download filter doesn't keep a ref on the
vadpy (except during pf_filter via src_pic).

4 years agochromecast: Move Control implementation in the class.
Hugo Beauzée-Luyssen [Mon, 10 Jul 2017 12:10:39 +0000 (14:10 +0200)]
chromecast: Move Control implementation in the class.

This avoids prefexing everything with p_sys-> and allows one to used the
private members

4 years agocodec: videotoolbox: restart from pps/sps change only on iframes
Francois Cartegnie [Mon, 10 Jul 2017 11:57:41 +0000 (13:57 +0200)]
codec: videotoolbox: restart from pps/sps change only on iframes

4 years agohw: vaapi-deint: replace struct memcpy by direct copy
Victorien Le Couviour--Tuffet [Mon, 10 Jul 2017 09:47:00 +0000 (11:47 +0200)]
hw: vaapi-deint: replace struct memcpy by direct copy

Signed-off-by: Thomas Guillem <thomas@gllm.fr>
4 years agoomxil: fix compilation
Jean-Baptiste Kempf [Mon, 10 Jul 2017 08:08:00 +0000 (10:08 +0200)]
omxil: fix compilation

4 years agomacosx: Correctly remove FSPanel.xib from build system
David Fuhrmann [Sun, 9 Jul 2017 18:07:16 +0000 (20:07 +0200)]
macosx: Correctly remove FSPanel.xib from build system

This fixes compilation as FSPanel.xib was not correctly removed
from buildsystem before. Also removes file from xcode project.

4 years agodvdnav: remove semi-broken seek on failure, fix warning
Rémi Denis-Courmont [Sun, 9 Jul 2017 13:43:40 +0000 (16:43 +0300)]
dvdnav: remove semi-broken seek on failure, fix warning

This was not handling the case of error when seeking due to a previous
error (hence the warning, in fact).

4 years agodemux: restore stream offset before probing (fixes #18502)
Rémi Denis-Courmont [Sun, 9 Jul 2017 13:29:58 +0000 (16:29 +0300)]
demux: restore stream offset before probing (fixes #18502)

There are (roughly) three ways that a demux probe function can fail:
- file type does not match,
- file type matches but corruption is detected early,
- unexpected I/O error.

In the first case, the demuxer will typically not move the "virtual"
file offset - mostly using vlc_stream_Peek(). But in the later two
cases, the demuxer will typically have moved the file offset forward.

There are no generic ways to fix it. Seeking back might fail (leading
to ingored result warning). So we try to fix it in generic way before
trying the next demuxer. If it fails, such as due to unrecoverable I/O
error, we just skip it completely.

4 years agoxa: remove struct member
Rémi Denis-Courmont [Sun, 9 Jul 2017 13:22:04 +0000 (16:22 +0300)]
xa: remove struct member

4 years agodemux: ps: missing es_format_Init
Francois Cartegnie [Sun, 9 Jul 2017 10:26:31 +0000 (12:26 +0200)]
demux: ps: missing es_format_Init

4 years agodemux: ps: remove define
Francois Cartegnie [Sun, 9 Jul 2017 12:21:51 +0000 (14:21 +0200)]
demux: ps: remove define

4 years agodemux: ps: always shift 0xbd es id
Francois Cartegnie [Sun, 9 Jul 2017 11:54:41 +0000 (13:54 +0200)]
demux: ps: always shift 0xbd es id

4 years agodecoder: don't init an es_format_t before calling es_format_Copy()
Steve Lhomme [Sun, 9 Jul 2017 08:27:47 +0000 (10:27 +0200)]
decoder: don't init an es_format_t before calling es_format_Copy()

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
4 years agotranscode: don't init an es_format_t before calling es_format_Copy()
Steve Lhomme [Sun, 9 Jul 2017 08:27:46 +0000 (10:27 +0200)]
transcode: don't init an es_format_t before calling es_format_Copy()

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
4 years agodemux:mp4: don't init an es_format_t before calling es_format_Copy()
Steve Lhomme [Sun, 9 Jul 2017 08:27:45 +0000 (10:27 +0200)]
demux:mp4: don't init an es_format_t before calling es_format_Copy()

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
4 years agoaccess:bluray: don't init an es_format_t before calling es_format_Copy()
Steve Lhomme [Sun, 9 Jul 2017 08:27:44 +0000 (10:27 +0200)]
access:bluray: don't init an es_format_t before calling es_format_Copy()

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
4 years agodemux: remove old tag-skipping kludge
Rémi Denis-Courmont [Sat, 8 Jul 2017 10:16:08 +0000 (13:16 +0300)]
demux: remove old tag-skipping kludge

This becomes redundant with the skiptags stream filter.

4 years agoskiptags: properly conceal ID3/APE tags (fixes #18501)
Rémi Denis-Courmont [Sat, 8 Jul 2017 09:24:27 +0000 (12:24 +0300)]
skiptags: properly conceal ID3/APE tags (fixes #18501)

As most demuxers cannot handle tags at the beginning of their input
streams, the demuxer code has automatically skipped them for a long
time.

Unfortunately, a number of demuxers also assume that the initial stream
byte offset is zero (while some others seem to assume zero in some paths
and not in others). This seems like a reasonable assumption. And even if
it were not, fixing all affected stream filters and demuxers to perform
only relative seeking seems impractical and unpalatable.

This stream filter shifts the stream byte offset so that the tags are
entirely invisible, and the demuxer can assume the start is at offset 0.

Of couse, the tags must still be accessible to the meta extraction
engine(s). The TagLib plugin uses "low-level" vlc_access_NewMRL() so it
is not subject to stream filters, and not affected by this change.
(This change does however remove tags from "demuxdump".)

NOTE: On the one hand, this also enables demuxing a file format with
embedded absolute file offsets, if the tags were prepended after muxing.
On the other hand, it conversely breaks demuxing such a file format if
the tags are added during muxing. As far as I know, tags are normally
appended rather than prepended to avoid this ambiguity.

4 years agoadaptive:fakeES: no need to initialize before es_format_Copy
Steve Lhomme [Sun, 9 Jul 2017 08:20:03 +0000 (10:20 +0200)]
adaptive:fakeES: no need to initialize before es_format_Copy

--
replaces https://patches.videolan.org/patch/17293/

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
4 years agoavodec: call es_format_Change() where possible
Steve Lhomme [Wed, 5 Jul 2017 11:36:25 +0000 (13:36 +0200)]
avodec: call es_format_Change() where possible

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agoaccess:avio: remove dead code
Steve Lhomme [Fri, 7 Jul 2017 07:20:37 +0000 (09:20 +0200)]
access:avio: remove dead code

We require libavformat >= 57

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodecklink: code cleaning
Steve Lhomme [Fri, 7 Jul 2017 10:11:13 +0000 (12:11 +0200)]
decklink: code cleaning

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodecklink: use the proper FourCC for VLC_CODEC_EIA608_1
Steve Lhomme [Fri, 7 Jul 2017 06:55:39 +0000 (08:55 +0200)]
decklink: use the proper FourCC for VLC_CODEC_EIA608_1

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agolinsys_hdsdi: use the proper FourCC for I420
Steve Lhomme [Fri, 7 Jul 2017 10:10:56 +0000 (12:10 +0200)]
linsys_hdsdi: use the proper FourCC for I420

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agolinsys_hdsdi: the audio output format is VLC_CODEC_S16L
Steve Lhomme [Fri, 7 Jul 2017 06:51:16 +0000 (08:51 +0200)]
linsys_hdsdi: the audio output format is VLC_CODEC_S16L

VLC_CODEC_RAW_PCM + 16 bits = VLC_CODEC_S16L

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:au: map raw PCM directly to the right format
Steve Lhomme [Thu, 6 Jul 2017 15:10:44 +0000 (17:10 +0200)]
demux:au: map raw PCM directly to the right format

Rather than the interim raw signed big-endian.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:mp4: make sure we don't touch spu data on non SPU tracks
Steve Lhomme [Thu, 6 Jul 2017 12:51:05 +0000 (14:51 +0200)]
demux:mp4: make sure we don't touch spu data on non SPU tracks

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:mkv: do not write in subs if it's not a SPU_ES track
Steve Lhomme [Thu, 6 Jul 2017 13:09:49 +0000 (15:09 +0200)]
demux:mkv: do not write in subs if it's not a SPU_ES track

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:mkv: map "A_PCM/FLOAT/IEEE" to ('a','f','l','t')
Steve Lhomme [Thu, 6 Jul 2017 14:56:33 +0000 (16:56 +0200)]
demux:mkv: map "A_PCM/FLOAT/IEEE" to ('a','f','l','t')

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
4 years agodemux:mkv: do not write audio/video elements in a mismatched track
Steve Lhomme [Thu, 6 Jul 2017 12:32:33 +0000 (14:32 +0200)]
demux:mkv: do not write audio/video elements in a mismatched track

It will overwrite values in the es_format_t union incorrectly.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>