vlc.git
7 weeks agoopengl: merge prgm into vlc_gl_renderer
Romain Vimont [Thu, 23 Jan 2020 16:56:55 +0000 (17:56 +0100)]
opengl: merge prgm into vlc_gl_renderer

The struct prgm contains some locations of the program, the struct
vlc_gl_renderer contains some others.

There are no reason to keep two separate structures.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: rename renderer callbacks
Romain Vimont [Thu, 23 Jan 2020 15:07:44 +0000 (16:07 +0100)]
opengl: rename renderer callbacks

Rename renderer callbacks from tc_ to renderer_. There is no tex
converter (tc) anymore.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: rename tex converter to renderer
Romain Vimont [Thu, 23 Jan 2020 14:43:30 +0000 (15:43 +0100)]
opengl: rename tex converter to renderer

The opengl_tex_converter_t is not a converter anymore: it is only used
to communicate between the renderer (currently managed in vout_helper.c)
and the fragment shader generation code (fragment_shaders.c).

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: make supports_npot local
Romain Vimont [Thu, 23 Jan 2020 17:05:05 +0000 (18:05 +0100)]
opengl: make supports_npot local

The field was used only from vout_display_opengl_New().

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: simplify opengl_init_program()
Romain Vimont [Tue, 21 Jan 2020 15:09:41 +0000 (16:09 +0100)]
opengl: simplify opengl_init_program()

The vout_helper now only manages the rendering of the "main" pictures,
so it never renders subpictures anymore (this has been moved to
vlc_gl_sub_renderer).

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: apply subpictures alpha
Romain Vimont [Wed, 5 Feb 2020 13:52:14 +0000 (14:52 +0100)]
opengl: apply subpictures alpha

The new subpictures renderer did not apply the alpha value.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: implement subpictures renderer
Romain Vimont [Tue, 21 Jan 2020 15:04:39 +0000 (16:04 +0100)]
opengl: implement subpictures renderer

Extract the subpictures rendering into a separate component, using its
own simplified vertex and fragment shaders.

This simplifies vout_helper.c.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: move interop functions to interop.c
Romain Vimont [Mon, 27 Jan 2020 13:34:46 +0000 (14:34 +0100)]
opengl: move interop functions to interop.c

The functions GenerateTextures() and DeleteTextures() apply to interop,
move them to the relevant file.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: expose GenTextures() and DelTextures()
Romain Vimont [Tue, 21 Jan 2020 12:47:57 +0000 (13:47 +0100)]
opengl: expose GenTextures() and DelTextures()

These util functions will be called from other files.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: expose GetAlignedSize()
Romain Vimont [Tue, 21 Jan 2020 12:43:58 +0000 (13:43 +0100)]
opengl: expose GetAlignedSize()

Expose a function to align a value to the next power of 2.

It will be called from other files.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: extract subpictures rendering
Romain Vimont [Fri, 17 Jan 2020 15:16:16 +0000 (16:16 +0100)]
opengl: extract subpictures rendering

Move subpictures rendering to separate functions.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: move GL_ASSERT_NOERROR macro to header
Romain Vimont [Wed, 29 Jan 2020 10:09:00 +0000 (11:09 +0100)]
opengl: move GL_ASSERT_NOERROR macro to header

The macro will be used from several files.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: expose interop constructor and destructor
Romain Vimont [Tue, 21 Jan 2020 10:05:22 +0000 (11:05 +0100)]
opengl: expose interop constructor and destructor

Expose functions to create and delete a vlc_gl_interop.

This avoids the callers to handle internal details about interop
creation and destruction.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: extract interop creation
Romain Vimont [Mon, 20 Jan 2020 15:19:47 +0000 (16:19 +0100)]
opengl: extract interop creation

Extract interop creation into a separate function.

This will allow to create an interop without an opengl_tex_converter_t.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: simplify opengl_init_program() call
Romain Vimont [Mon, 27 Jan 2020 14:52:12 +0000 (15:52 +0100)]
opengl: simplify opengl_init_program() call

Do not pass extensions to opengl_init_program().

This was an optimization not to retrieve the extensions list twice.
However, since the initialization will be moved into a separate
component (the renderer), we don't want to expose this internal detail.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: fix indentation
Romain Vimont [Wed, 22 Jan 2020 17:58:29 +0000 (18:58 +0100)]
opengl: fix indentation

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: add interop close() callback
Romain Vimont [Wed, 22 Jan 2020 17:46:35 +0000 (18:46 +0100)]
opengl: add interop close() callback

Use a callback to close an interop instead of relying on closing the
module.

This allows to properly close interop_sw, which is not a module.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: make fragment shader local
Romain Vimont [Wed, 22 Jan 2020 16:19:19 +0000 (17:19 +0100)]
opengl: make fragment shader local

Since vlc_gl_interop has been introduced, the fragment shader is built
by vout_helper instead of the converter module.

Therefore, there is no need to keep it exposed in the
opengl_tex_converter_t instance.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: move compat definition to gl_common.h
Romain Vimont [Wed, 22 Jan 2020 14:18:40 +0000 (15:18 +0100)]
opengl: move compat definition to gl_common.h

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: fix typo
Romain Vimont [Wed, 29 Jan 2020 10:24:41 +0000 (11:24 +0100)]
opengl: fix typo

In the initial patchset, vlc_gl_interop was named vlc_gl_importer.

It had been incorrectly replaced.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoopengl: apply transform matrix on all planes
Romain Vimont [Wed, 29 Jan 2020 10:04:37 +0000 (11:04 +0100)]
opengl: apply transform matrix on all planes

The transform matrix provided by Android was applied only on the first
plane.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agodav1d: require 0.5.0 for ITU T.35
Jean-Baptiste Kempf [Thu, 13 Feb 2020 22:10:00 +0000 (23:10 +0100)]
dav1d: require 0.5.0 for ITU T.35

7 weeks agocodec: dav1d: extract captions
Francois Cartegnie [Thu, 13 Feb 2020 15:48:34 +0000 (16:48 +0100)]
codec: dav1d: extract captions

7 weeks agocodec: dav1d: always pull all available pictures
Francois Cartegnie [Thu, 13 Feb 2020 16:38:11 +0000 (17:38 +0100)]
codec: dav1d: always pull all available pictures

otherwise introduces latency due to pacing, and
potentially an offset in frame output sequence

7 weeks agocodec: dav1d: fix potential leak
Francois Cartegnie [Thu, 13 Feb 2020 16:23:40 +0000 (17:23 +0100)]
codec: dav1d: fix potential leak

7 weeks agocodec: dav1d: apply HDR CLL
Francois Cartegnie [Thu, 13 Feb 2020 13:19:59 +0000 (14:19 +0100)]
codec: dav1d: apply HDR CLL

7 weeks agocodec: dav1d: apply HDR MDCV
Francois Cartegnie [Thu, 13 Feb 2020 13:15:22 +0000 (14:15 +0100)]
codec: dav1d: apply HDR MDCV

7 weeks agotaglib: fix -Wdeprecated-copy warnings
Alexandre Janniaux [Fri, 7 Feb 2020 22:50:00 +0000 (23:50 +0100)]
taglib: fix -Wdeprecated-copy warnings

Warnings were happening because we were using copy operator= as the
assigned object was already initialized. This patch use the copy
constructor or move constructor instead if available.

Those warnings were:

../../modules/meta_engine/taglib.cpp: In function ‘void ReadMetaFromXiph(TagLib::Ogg::XiphComment*, demux_meta_t*, vlc_meta_t*)’:
../../modules/meta_engine/taglib.cpp:672:39: warning: implicitly-declared ‘TagLib::StringList& TagLib::StringList::operator=(const TagLib::StringList&)’ is deprecated [-Wdeprecated-copy]
  672 |     list = tag->fieldListMap()[keyName];                                       \
      |                                       ^
../../modules/meta_engine/taglib.cpp:681:5: note: in expansion of macro ‘SET’
  681 |     SET( "COPYRIGHT", Copyright );
      |     ^~~
In file included from /usr/include/taglib/fileref.h:30,
                 from ../../modules/meta_engine/taglib.cpp:58:
/usr/include/taglib/tstringlist.h:59:5: note: because ‘TagLib::StringList’ has user-provided ‘TagLib::StringList::StringList(const TagLib::StringList&)’
   59 |     StringList(const StringList &l);
      |     ^~~~~~~~~~

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoavformat: enable SPU_ES muxing
Alexandre Janniaux [Wed, 11 Dec 2019 15:23:14 +0000 (16:23 +0100)]
avformat: enable SPU_ES muxing

The codec support in avformat should be mapped by the GetFfmpegCodec
call at the beginning of the function. In particular, this patch will
allow muxing subrip/text SPU within Matroska files.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoavformat: mux: handle subtitle metadata
Alexandre Janniaux [Wed, 11 Dec 2019 15:23:13 +0000 (16:23 +0100)]
avformat: mux: handle subtitle metadata

Some information are added through the metadata dictionary attached
to the stream object. In these information, the following keys are
used by the avformat Matroska muxer:

+ title: correspond to the TrackName, we're putting it in
  psz_description field in the Matroska parser module.

+ language: correspond to the TrackLanguage, we're putting it in
  the psz_language field in the Matroska parser module.

Replicate the behaviour so that these metadata are not lost after
remuxing.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agocontrol: rc: avoid stringop-truncation warning
Alexandre Janniaux [Mon, 20 Jan 2020 15:44:44 +0000 (16:44 +0100)]
control: rc: avoid stringop-truncation warning

Fortify enabled implies a warning if we use strncpy with a length equal
to the buffer size. As we fill the last item with a null character, we
can use length-1 instead as well.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agocontrol: rc: avoid sun_path longer than expected
Alexandre Janniaux [Mon, 20 Jan 2020 15:44:43 +0000 (16:44 +0100)]
control: rc: avoid sun_path longer than expected

The path in the description of a UNIX domain socket address is limited
to a fixed size, so avoid truncating the provided path if it's longer
than the corresponding sockaddr_un field and return an error while
emitting the corresponding error message.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqt: audiodevicemodel: fix memory leak
Alexandre Janniaux [Tue, 28 Jan 2020 16:35:22 +0000 (17:35 +0100)]
qt: audiodevicemodel: fix memory leak

Simplify the release of devices list while ensuring the array are
correctly released even when there is no devices in the list.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoandroid: util: use ARRAY_SIZE if possible
Alexandre Janniaux [Fri, 7 Feb 2020 12:19:01 +0000 (13:19 +0100)]
android: util: use ARRAY_SIZE if possible

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoandroid: util: remove redundant strncmp
Alexandre Janniaux [Thu, 6 Feb 2020 14:19:42 +0000 (15:19 +0100)]
android: util: remove redundant strncmp

strcmp will already stop at the second string's length and the first
string is known to be null-terminated.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agotranscode: video: remove unused function
Alexandre Janniaux [Thu, 30 Jan 2020 12:25:51 +0000 (13:25 +0100)]
transcode: video: remove unused function

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agotranscode: video: append converter before encoder if needed
Alexandre Janniaux [Thu, 30 Jan 2020 12:25:51 +0000 (13:25 +0100)]
transcode: video: append converter before encoder if needed

The encoder is able to override its input format, especially to change
the input chroma. The semantic is that the encoder user should either
change the input format or refuse the module probing.

The transcode video pipeline had a dedicated filter_chain to handle such
conversion but it was never initialized.

Store encoder input format before it is initialized, and initialize the
final filter chain if the format is different from what the encoder
requested.

Fix #22703

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: add margins around Dialogs buttons
Pierre Lamot [Tue, 4 Feb 2020 12:48:30 +0000 (13:48 +0100)]
qml: add margins around Dialogs buttons

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: fix focus background not visible in TextToolButton
Pierre Lamot [Tue, 4 Feb 2020 12:33:22 +0000 (13:33 +0100)]
qml: fix focus background not visible in TextToolButton

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: fix binding loop on width in modal dialogs
Pierre Lamot [Tue, 4 Feb 2020 12:44:12 +0000 (13:44 +0100)]
qml: fix binding loop on width in modal dialogs

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: avoid crash at exit when dismissing dialog
Pierre Lamot [Tue, 4 Feb 2020 14:44:15 +0000 (15:44 +0100)]
qml: avoid crash at exit when dismissing dialog

  loginDialog.dialogId stayed defined (hence dissmissed at exit) when
  accepting/dismissing the dialog without clicking on a button

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: remove debug messages
Pierre Lamot [Tue, 28 Jan 2020 09:26:03 +0000 (10:26 +0100)]
qml: remove debug messages

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: remove uri below the file name while browsing network
Pierre Lamot [Mon, 27 Jan 2020 11:51:00 +0000 (12:51 +0100)]
qml: remove uri below the file name while browsing network

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: don't focus the 'add to medialibrary' button when invisible
Pierre Lamot [Tue, 4 Feb 2020 10:07:57 +0000 (11:07 +0100)]
qml: don't focus the 'add to medialibrary' button when invisible

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: recursively traverse disabled NavigableFocusScope
Pierre Lamot [Tue, 4 Feb 2020 09:15:55 +0000 (10:15 +0100)]
qml: recursively traverse disabled NavigableFocusScope

  The previous behavior was to traverse sibiling until we find one a focusable
  one. This caused problem when the last sibiling in chain wasn't focusable as
  it was unable to continue with the parent sibiling.

  This allows to handle the case where a disabled focusable item is last
  in chain. It assumes items would behabe sanely when non focusable (have a
  sibiling or parent defined)

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: set the initial focus when the delegate model of NetworkBrowseDisplay is populated
Pierre Lamot [Tue, 28 Jan 2020 09:12:56 +0000 (10:12 +0100)]
qml: set the initial focus when the delegate model of NetworkBrowseDisplay is populated

  Reseting the focus on active focus wasn't suffisant because the
  view (hence the focus) no longer reloaded when navigating.

  We now set the initial focus when the delegate model is populated.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: set the focus on the first section in list in NetworkHomeDisplay
Pierre Lamot [Mon, 27 Jan 2020 16:54:47 +0000 (17:54 +0100)]
qml: set the focus on the first section in list in NetworkHomeDisplay

  This used to set the focus on the first section loaded which may not be
  natural

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: fix initial focus not being set to the first item in NetworkHomeDisplay
Pierre Lamot [Mon, 27 Jan 2020 12:44:41 +0000 (13:44 +0100)]
qml: fix initial focus not being set to the first item in NetworkHomeDisplay

  When the model of the Listview is being updated multiple times, the focus
  remains on the last focused item, so when we prepend items to our model, this
  moved the initial focused item, even if we never had the focus on the list.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: avoid binding loop in KeyNavigableListView
Pierre Lamot [Thu, 6 Feb 2020 12:40:37 +0000 (13:40 +0100)]
qml: avoid binding loop in KeyNavigableListView

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: set differentiated highlight zone in KeyNavigableListView when the layout is...
Pierre Lamot [Mon, 27 Jan 2020 16:57:52 +0000 (17:57 +0100)]
qml: set differentiated highlight zone in KeyNavigableListView when the layout is Horizontal

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqml: display the associated artwork when available in network views
Pierre Lamot [Mon, 3 Feb 2020 13:57:05 +0000 (14:57 +0100)]
qml: display the associated artwork when available in network views

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqt: retrieve the artwork when available in network models
Pierre Lamot [Mon, 3 Feb 2020 13:55:21 +0000 (14:55 +0100)]
qt: retrieve the artwork when available in network models

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqt: refcount children passed to onItemAdded in NetworkMediaModel
Pierre Lamot [Wed, 5 Feb 2020 10:33:16 +0000 (11:33 +0100)]
qt: refcount children passed to onItemAdded in NetworkMediaModel

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agoqt: cancel preparse requests before destroying/changing model of NetworkMediaModel
Pierre Lamot [Thu, 6 Feb 2020 08:52:39 +0000 (09:52 +0100)]
qt: cancel preparse requests before destroying/changing model of NetworkMediaModel

  this caused a crash if the UI was destroyed when a request was pending

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agomedia_tree: allow preparse tasks to be canceled
Pierre Lamot [Wed, 5 Feb 2020 16:49:28 +0000 (17:49 +0100)]
media_tree: allow preparse tasks to be canceled

  If we need to release the media tree before the preparse ends
  the preparse callback will likely crash.

  This allows to pass an optional task id to vlc_media_tree_Preparse and to
  cancel it afterwards

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
7 weeks agod3d11_fmt: make D3D11_CreateDeviceExternal private
Steve Lhomme [Wed, 12 Feb 2020 14:50:45 +0000 (15:50 +0100)]
d3d11_fmt: make D3D11_CreateDeviceExternal private

7 weeks agod3d11_fmt: make the d3d11_handle_t private
Steve Lhomme [Wed, 12 Feb 2020 14:20:55 +0000 (15:20 +0100)]
d3d11_fmt: make the d3d11_handle_t private

It's not used outside and doesn't need to be shared.

7 weeks agod3d11_fmt: make D3D11_LogResources more generic
Steve Lhomme [Wed, 12 Feb 2020 14:24:17 +0000 (15:24 +0100)]
d3d11_fmt: make D3D11_LogResources more generic

We don't need to shared the internals of how it's done for the
d3d11_decoder_device_t.

7 weeks agodirect3d11: remove the local d3d11_handle_t instances
Steve Lhomme [Wed, 12 Feb 2020 14:17:48 +0000 (15:17 +0100)]
direct3d11: remove the local d3d11_handle_t instances

As long as the decoder device/d3d11_decoder_device_t is alive we hold the DLLs.

7 weeks agodirect3d9: make d3d9_handle_t functions private
Steve Lhomme [Wed, 12 Feb 2020 12:15:09 +0000 (13:15 +0100)]
direct3d9: make d3d9_handle_t functions private

They are only called locally.

No functional change.

7 weeks agodirect3d9: request the presentation parameters with a d3d9_decoder_device_t
Steve Lhomme [Wed, 12 Feb 2020 11:23:19 +0000 (12:23 +0100)]
direct3d9: request the presentation parameters with a d3d9_decoder_device_t

7 weeks agodirect3d9: store the device capabilities in the device handle
Steve Lhomme [Wed, 12 Feb 2020 10:23:50 +0000 (11:23 +0100)]
direct3d9: store the device capabilities in the device handle

Don't store it in the device that will be created.

7 weeks agocodec: dav1d: treat decode errors as non fatal
Francois Cartegnie [Wed, 12 Feb 2020 17:27:59 +0000 (18:27 +0100)]
codec: dav1d: treat decode errors as non fatal

since it doesn't make the difference and EGENERIC
is now seen as ECRITICAL...

7 weeks agodemux: dash: debug using stream ID instead of mime type
Francois Cartegnie [Wed, 12 Feb 2020 17:14:57 +0000 (18:14 +0100)]
demux: dash: debug using stream ID instead of mime type

7 weeks agocodec: dav1d: use provided error value macro
Francois Cartegnie [Wed, 12 Feb 2020 17:12:12 +0000 (18:12 +0100)]
codec: dav1d: use provided error value macro

7 weeks agodirect3d9: move the external device handling in the common code
Steve Lhomme [Wed, 12 Feb 2020 09:12:03 +0000 (10:12 +0100)]
direct3d9: move the external device handling in the common code

The D3D9 display module may be used without a decoder device (software decoding)
and we still need to use the device from the host app.

The allocated d3d9_decoder_device_t structure is freed with the object that
created it. But D3D9_ReleaseDevice() still need to be called.

7 weeks agodirect3d11: move the external device handling in the common code
Steve Lhomme [Wed, 12 Feb 2020 12:55:26 +0000 (13:55 +0100)]
direct3d11: move the external device handling in the common code

The D3D11 display module may be used without a decoder device (software decoding)
and we still need to use the device from the host app.

The allocated d3d11_decoder_device_t structure is freed with the object that
created it. But D3D11_ReleaseDevice() still need to be called.

7 weeks agod3d11_fmt: move the forced check in D3D11_CreateDevice
Steve Lhomme [Wed, 12 Feb 2020 12:41:12 +0000 (13:41 +0100)]
d3d11_fmt: move the forced check in D3D11_CreateDevice

7 weeks agodirect3d9: fix rendering of software sources
Steve Lhomme [Wed, 12 Feb 2020 16:00:48 +0000 (17:00 +0100)]
direct3d9: fix rendering of software sources

7 weeks agolibvlc: fix union in output callback device config
Steve Lhomme [Wed, 12 Feb 2020 09:05:38 +0000 (10:05 +0100)]
libvlc: fix union in output callback device config

For Direct3D9 we actually need both fields

7 weeks agodoc: libvlc: get the OpenGL functions properly
Steve Lhomme [Tue, 11 Feb 2020 14:21:08 +0000 (15:21 +0100)]
doc: libvlc: get the OpenGL functions properly

The context has its own functions we already access.

7 weeks agolibvlc: fix remaining OpenGL comment
Steve Lhomme [Wed, 12 Feb 2020 11:17:02 +0000 (12:17 +0100)]
libvlc: fix remaining OpenGL comment

The callback is now more generic than OpenGL context managing.

7 weeks agodirect3d9: fix missing verb in comments
Steve Lhomme [Wed, 12 Feb 2020 09:12:26 +0000 (10:12 +0100)]
direct3d9: fix missing verb in comments

7 weeks agod3d11_swapchain: fix double d3d11_decoder_device_t free
Steve Lhomme [Wed, 12 Feb 2020 15:30:29 +0000 (16:30 +0100)]
d3d11_swapchain: fix double d3d11_decoder_device_t free

We don't create it here. There's no reason to release it here.

7 weeks agod3d11_fmt: avoid forcing COBJMACROS on files including the header
Steve Lhomme [Wed, 12 Feb 2020 15:09:56 +0000 (16:09 +0100)]
d3d11_fmt: avoid forcing COBJMACROS on files including the header

7 weeks agod3d11_shaders: initialize the shaders loader separately
Steve Lhomme [Wed, 12 Feb 2020 13:42:14 +0000 (14:42 +0100)]
d3d11_shaders: initialize the shaders loader separately

Only the display module actually needs to get it for now.

7 weeks agod3d11_shaders: pass the shader function with the dedicated structure
Steve Lhomme [Wed, 12 Feb 2020 13:21:49 +0000 (14:21 +0100)]
d3d11_shaders: pass the shader function with the dedicated structure

7 weeks agod3d11: move the shader function in a separate structure
Steve Lhomme [Wed, 12 Feb 2020 13:19:05 +0000 (14:19 +0100)]
d3d11: move the shader function in a separate structure

7 weeks agocodec: cc: remove leftoff debug
Francois Cartegnie [Wed, 12 Feb 2020 13:51:49 +0000 (14:51 +0100)]
codec: cc: remove leftoff debug

ref ff7bc36dd6ce6dcbda8c3484f5e545584a317001

7 weeks agopacketizer: mpegvideo: fix prev dts check
Francois Cartegnie [Wed, 12 Feb 2020 13:49:21 +0000 (14:49 +0100)]
packetizer: mpegvideo: fix prev dts check

spurious timestamps resets and breaks captions reordering
ref dd1f506f409ab14ab579f08e077fd0fcd53ee1d4

7 weeks agopacketizer: mpegvideo: debug picture type
Francois Cartegnie [Wed, 12 Feb 2020 13:20:40 +0000 (14:20 +0100)]
packetizer: mpegvideo: debug picture type

7 weeks agocodec: cc: decode provided CEA708 channel
Francois Cartegnie [Tue, 11 Feb 2020 19:00:02 +0000 (20:00 +0100)]
codec: cc: decode provided CEA708 channel

refs #23691

7 weeks agocodec: cc: extract CEA708 service ids
Francois Cartegnie [Tue, 11 Feb 2020 13:42:55 +0000 (14:42 +0100)]
codec: cc: extract CEA708 service ids

refs #23691

7 weeks agod3d11_device: cleanup exit on error
Steve Lhomme [Tue, 11 Feb 2020 14:31:32 +0000 (15:31 +0100)]
d3d11_device: cleanup exit on error

7 weeks agodoc: add the OpenGL callbacks libvlc player sources
Steve Lhomme [Tue, 11 Feb 2020 11:10:56 +0000 (12:10 +0100)]
doc: add the OpenGL callbacks libvlc player sources

7 weeks agodoc: libvlc: fix line endings of OpenGL callback sample
Steve Lhomme [Tue, 11 Feb 2020 11:09:15 +0000 (12:09 +0100)]
doc: libvlc: fix line endings of OpenGL callback sample

7 weeks agodoc: add the d3d11/d3d9 libvlc player sources
Steve Lhomme [Tue, 11 Feb 2020 10:26:50 +0000 (11:26 +0100)]
doc: add the d3d11/d3d9 libvlc player sources

7 weeks agodoc: libvlc: fix the Qt OpenGL sample compilation
Steve Lhomme [Tue, 11 Feb 2020 10:53:19 +0000 (11:53 +0100)]
doc: libvlc: fix the Qt OpenGL sample compilation

7 weeks agobackground_worker: Fix potential use after free
Hugo Beauzée-Luyssen [Thu, 6 Feb 2020 15:48:36 +0000 (16:48 +0100)]
background_worker: Fix potential use after free

Since we free the task and only then lock the worker mutex to reset the
task pointer, there's a window during which another thread could probe
the dangling task pointer.

Such a case can be seen here: https://code.videolan.org/videolan/medialibrary/-/jobs/351960

7 weeks agothreads: forbid the use of vlc_cleanup_push/pop in portable C++ code
Steve Lhomme [Tue, 11 Feb 2020 07:44:44 +0000 (08:44 +0100)]
threads: forbid the use of vlc_cleanup_push/pop in portable C++ code

It may work for some C++ code only used on Linux. But if the module is compiled
on other platforms it will assert.

7 weeks agoDisable the libvgl plugin if OpenGL isn't available
Martin Storsjö [Tue, 11 Feb 2020 09:59:11 +0000 (11:59 +0200)]
Disable the libvgl plugin if OpenGL isn't available

This fixes building for Windows/ARM(64), which lacks OpenGL.

Previously, this plugin has compiled just fine without OpenGL available,
but since b6a47686dfe2f789780f902b776e864e5c386ac5, OpenGL headers
were included here. Just skip the plugin in those cases.

7 weeks agopacketizer: mpegvideo: fix dts repeats regression (#24072)
Francois Cartegnie [Mon, 10 Feb 2020 13:01:57 +0000 (14:01 +0100)]
packetizer: mpegvideo: fix dts repeats regression (#24072)

7 weeks agolibvlc: avoid including OpenGL headers in the host bridge
Steve Lhomme [Tue, 11 Feb 2020 07:21:30 +0000 (08:21 +0100)]
libvlc: avoid including OpenGL headers in the host bridge

7 weeks agodemux: adaptive: use a signaled boolean to test if the thread should stop
Steve Lhomme [Mon, 10 Feb 2020 15:23:41 +0000 (16:23 +0100)]
demux: adaptive: use a signaled boolean to test if the thread should stop

Rather than using a cancelation point that may not work on some platforms.

Ref #23591

7 weeks agosap: simplify not using cancellation
Rémi Denis-Courmont [Sun, 9 Feb 2020 13:30:43 +0000 (15:30 +0200)]
sap: simplify not using cancellation

7 weeks agosap: create the thread after the first session is ready
Rémi Denis-Courmont [Sun, 9 Feb 2020 13:26:08 +0000 (15:26 +0200)]
sap: create the thread after the first session is ready

This ensures that the thread will not be leaked doing nothing if
session creation fails.

7 weeks agosap: merge both locks
Rémi Denis-Courmont [Sun, 9 Feb 2020 13:22:41 +0000 (15:22 +0200)]
sap: merge both locks

This is simpler and even necessary for the following fix.

7 weeks agosap: use vlc_list for SAP sessions
Rémi Denis-Courmont [Sun, 9 Feb 2020 12:32:59 +0000 (14:32 +0200)]
sap: use vlc_list for SAP sessions

7 weeks agosap: use vlc_list for SAP addresses
Rémi Denis-Courmont [Sun, 9 Feb 2020 12:32:59 +0000 (14:32 +0200)]
sap: use vlc_list for SAP addresses

7 weeks agotimer: do not use vlc_cancel()
Rémi Denis-Courmont [Sun, 9 Feb 2020 12:17:19 +0000 (14:17 +0200)]
timer: do not use vlc_cancel()