From d6af6efbf9873906bd21000551fa0f284c441eff Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 28 Apr 2018 15:41:39 +0200 Subject: [PATCH] vd_lavc: enable dr by default I had this enabled for quite a while and experienced no issues. I'm not aware of other issues either. --- DOCS/man/options.rst | 11 ++++------- video/decode/vd_lavc.c | 1 + 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/DOCS/man/options.rst b/DOCS/man/options.rst index 2776bf7b10..069363dfd0 100644 --- a/DOCS/man/options.rst +++ b/DOCS/man/options.rst @@ -1134,22 +1134,19 @@ Video N frames fail to decode in a row. 1 is equivalent to ``yes``. ``--vd-lavc-dr=`` - Enable direct rendering (default: no). If this is set to ``yes``, the + Enable direct rendering (default: yes). If this is set to ``yes``, the video will be decoded directly to GPU video memory (or staging buffers). This can speed up video upload, and may help with large resolutions or slow hardware. This works only with the following VOs: - - ``gpu``: requires at least OpenGL 4.4. + - ``gpu``: requires at least OpenGL 4.4 or Vulkan. - (In particular, this can't be made work with ``opengl-cb``.) + (In particular, this can't be made work with ``opengl-cb``, but the libmpv + render API has optional support.) Using video filters of any kind that write to the image data (or output newly allocated frames) will silently disable the DR code path. - There are some corner cases that will result in undefined behavior (crashes - and other strange behavior) if this option is enabled. These are pending - towards being fixed properly at a later point. - ``--vd-lavc-bitexact`` Only use bit-exact algorithms in all decoding steps (for codec testing). diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c index 5a8c2d53c5..a2f1d7d494 100644 --- a/video/decode/vd_lavc.c +++ b/video/decode/vd_lavc.c @@ -126,6 +126,7 @@ const struct m_sub_options vd_lavc_conf = { .skip_idct = AVDISCARD_DEFAULT, .skip_frame = AVDISCARD_DEFAULT, .framedrop = AVDISCARD_NONREF, + .dr = 1, }, };