diff --git a/video/decode/hw_d3d11va.c b/video/decode/hw_d3d11va.c index a69a3890bd..1eab4b5e0b 100644 --- a/video/decode/hw_d3d11va.c +++ b/video/decode/hw_d3d11va.c @@ -27,7 +27,7 @@ #include "d3d.h" -#define ADDITIONAL_SURFACES (HWDEC_EXTRA_SURFACES + HWDEC_DELAY_QUEUE_COUNT) +#define ADDITIONAL_SURFACES HWDEC_EXTRA_SURFACES struct d3d11va_decoder { ID3D11VideoDecoder *decoder; diff --git a/video/decode/hw_dxva2.c b/video/decode/hw_dxva2.c index 7b1a6b4bc7..7be0d9b9fa 100644 --- a/video/decode/hw_dxva2.c +++ b/video/decode/hw_dxva2.c @@ -32,7 +32,7 @@ #include "d3d.h" -#define ADDITIONAL_SURFACES (HWDEC_EXTRA_SURFACES + HWDEC_DELAY_QUEUE_COUNT) +#define ADDITIONAL_SURFACES HWDEC_EXTRA_SURFACES struct priv { struct mp_log *log; diff --git a/video/decode/hw_vaapi_old.c b/video/decode/hw_vaapi_old.c index fb0fc40110..8ba4d444bf 100644 --- a/video/decode/hw_vaapi_old.c +++ b/video/decode/hw_vaapi_old.c @@ -44,7 +44,7 @@ * Note that redundant additional surfaces also might allow for some * buffering (i.e. not trying to reuse a surface while it's busy). */ -#define ADDTIONAL_SURFACES MPMAX(6, HWDEC_DELAY_QUEUE_COUNT) +#define ADDTIONAL_SURFACES HWDEC_EXTRA_SURFACES // Some upper bound. #define MAX_SURFACES 25 diff --git a/video/decode/lavc.h b/video/decode/lavc.h index dfce9c3bfd..4df92e40a6 100644 --- a/video/decode/lavc.h +++ b/video/decode/lavc.h @@ -16,8 +16,7 @@ // This number might require adjustment depending on whatever the player does; // for example, if vo_opengl increases the number of reference surfaces for // interpolation, this value has to be increased too. -// This value does not yet include HWDEC_DELAY_QUEUE_COUNT. -#define HWDEC_EXTRA_SURFACES 4 +#define HWDEC_EXTRA_SURFACES 6 struct mpv_global;