Commit 66635182 authored by Steve Lhomme's avatar Steve Lhomme Committed by Jean-Baptiste Kempf

d3d9_fmt: add a helper function to find the actual picture_sys_t to use

the decoder and filters fill context but the vout uses picture_sys_t by default
Signed-off-by: Jean-Baptiste Kempf's avatarJean-Baptiste Kempf <>
parent 85fd3054
......@@ -33,6 +33,12 @@ struct picture_sys_t
#include "../codec/avcodec/va_surface.h"
static inline picture_sys_t *ActivePictureSys(picture_t *p_pic)
struct va_pic_context *pic_ctx = (struct va_pic_context*)p_pic->context;
return pic_ctx ? &pic_ctx->picsys : p_pic->p_sys;
static inline void AcquirePictureSys(picture_sys_t *p_sys)
......@@ -56,7 +56,7 @@ struct filter_sys_t {
static bool GetLock(filter_t *p_filter, LPDIRECT3DSURFACE9 d3d,
if (FAILED( IDirect3DSurface9_GetDesc(d3d, p_desc)))
if (unlikely(FAILED( IDirect3DSurface9_GetDesc(d3d, p_desc))))
return false;
/* */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment