diff options
authorwm4 <wm4@nowhere>2018-04-28 15:41:39 +0200
committerJan Ekström <>2018-04-29 02:21:32 +0300
commitd6af6efbf9873906bd21000551fa0f284c441eff (patch)
parent63441d36ef29e13edbba770093f582b2a455160a (diff)
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.
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``.
- 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.
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_frame = AVDISCARD_DEFAULT,
.framedrop = AVDISCARD_NONREF,
+ .dr = 1,