[vlc-devel] [PATCH 00/42] Road to push video context (v5)
Thomas Guillem
thomas at gllm.fr
Wed Oct 2 09:31:43 CEST 2019
On Tue, Oct 1, 2019, at 13:12, Steve Lhomme wrote:
> Compared to the previous patchset:
> - more patches to send a real video context with useful data for D3D
> (external
> rendering requires that the video device is the same between the host
> app,
> the decoder and the display module)
> - VAAPI/VDPAU have not been updated with data in the video context, not
> sure
> they need extra data that are not in the video device
> - rework some vout calls not to rely on stored data that will not be
> stored
> anymore in push
> - fix a bug where the stored decoder device in the decoder was missing
> a reference
> (it's only breaking bisect because that storage is going away a few
> patches later)
> - only pass the vout thread and video format to get the decoder device,
> the rest
> of the display configuration data (like DPB size) are passed when
> getting the
> display module. So now there are 2 different configuration structure:
> one to
> get a decoder device (vout_device_configuration_t), one to get a
> display
> module (vout_configuration_t).
> - rename all "decoder device" hold functions to get functions, the
> values are
> returned directly rather than filling a pointer of pointer.
>
> Steve Lhomme (38):
> video_output: pass the video format to vout_SizeWindow()
> video_output: set the pose outside of VoutGetDisplayCfg
> opengl: pass the video context rather than the decoder device
> decoder: use a separate function to clean the display video format
> decoder: move the display creation in a separate function
> decoder: clean CreateVoutIfNeeded
> video_output: split vout_Request to have a function to enable the vout
> window
> video_output: add vout_GetDevice to get the vout decoder device on
> demand
> vout: request the display with a decoder device
> display: don't store the dummy context in the display anymore
> decoder: request decoder device when getting the vout
> input: resource: get the decoder device before calling vout_Request()
> decoder: split the decoder format update in 2 parts
> input: resource: split input_resource_GetVout()
> decoder: move the display creation in a separate function
> decoder: split the creation of the vout/decoder device and the display
> module
> video context: add a Create/Release function for the video context
> video context: make the video context structure private
> decoder: allow multiple calls to HoldDecoderDevice before calling
> UpdateFormat
> avcodec: get the decoder device before creating the VA
> avcodec: provide the vlc_decoder_device from the vout thread to the VA
> constructor
> d3d11va: use the decoder device to init the D3D11 device
> dxva2: use the decoder device to init the D3D9 device
> avcodec: vaapi: allocate output pictures locally
> vaapi: use the decoder device to get the VADisplay
> avcodec: do not use a picture from the display before creating the VA
> decoder: optionally pass a vlc_video_context in
> decoder_UpdateVideoOutput()
> decoder: remove locally stored decoder device
> nvdec: create a video context for the decoder
> avcodec: get the vlc_video_context created by the VA
> d3d11va: create a video context for the VA
> dxva2: create a video context for the VA
> vaapi: create a dummy video context
> vdpau: create a dummy video context
> video context: allow storing typed extra data in the video context
> dxva2: store the IDirect3DDevice9 in the video context
> d3d11va: store the ID3D11DeviceContext in the video context
> vout: request the vout with a video context
>
> include/vlc_codec.h | 39 +-
> include/vlc_picture.h | 40 ++-
> include/vlc_vout_display.h | 3 +-
> modules/codec/avcodec/d3d11va.c | 60 ++--
> modules/codec/avcodec/dxva2.c | 46 ++-
> modules/codec/avcodec/va.c | 9 +-
> modules/codec/avcodec/va.h | 6 +-
> modules/codec/avcodec/vaapi.c | 38 +-
> modules/codec/avcodec/video.c | 38 +-
> modules/hw/nvdec/nvdec.c | 26 +-
> modules/hw/nvdec/nvdec_gl.c | 3 +-
> modules/hw/vaapi/vlc_vaapi.c | 9 -
> modules/hw/vaapi/vlc_vaapi.h | 5 -
> modules/hw/vdpau/avcodec.c | 11 +-
> modules/stream_out/mosaic_bridge.c | 4 +-
> modules/stream_out/transcode/video.c | 2 +-
> modules/video_chroma/d3d11_fmt.c | 10 +
> modules/video_chroma/d3d11_fmt.h | 15 +-
> modules/video_chroma/d3d9_fmt.c | 10 +
> modules/video_chroma/d3d9_fmt.h | 15 +-
> modules/video_output/opengl/converter.h | 4 +-
> modules/video_output/opengl/converter_vaapi.c | 24 +-
> modules/video_output/opengl/converter_vdpau.c | 25 +-
> modules/video_output/opengl/vout_helper.c | 2 +-
> modules/video_output/splitter.c | 5 +-
> modules/video_output/win32/direct3d9.c | 8 +-
> src/audio_output/filters.c | 2 +-
> src/input/decoder.c | 334 +++++++++++-------
> src/input/decoder_helpers.c | 89 ++++-
> src/input/resource.c | 33 +-
> src/input/resource.h | 6 +-
> src/libvlccore.sym | 8 +
> src/misc/image.c | 3 +-
> src/video_output/display.c | 15 +-
> src/video_output/video_output.c | 87 +++--
> src/video_output/vout_internal.h | 14 +-
> src/video_output/vout_wrapper.c | 7 +-
> 37 files changed, 767 insertions(+), 288 deletions(-)
I'm OK with this set (except some small details I already mentioned). I tested it with VAAPI and sent you some fixes.
Good job!
>
> --
> 2.17.1
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
More information about the vlc-devel
mailing list