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

direct3d9: do not try to use the vout if the texture requested is too large

Signed-off-by: Jean-Baptiste Kempf's avatarJean-Baptiste Kempf <jb@videolan.org>
parent 245bbda7
......@@ -648,6 +648,16 @@ static int Direct3D9Create(vout_display_t *vd)
return VLC_EGENERIC;
}
if ( vd->fmt.i_width > sys->d3dcaps.MaxTextureWidth ||
vd->fmt.i_height > sys->d3dcaps.MaxTextureHeight )
{
msg_Err(vd, "Textures too large %ux%u max possible: %ux%u",
vd->fmt.i_width, vd->fmt.i_height,
(unsigned) sys->d3dcaps.MaxTextureWidth,
(unsigned) sys->d3dcaps.MaxTextureHeight);
return VLC_EGENERIC;
}
return VLC_SUCCESS;
}
......
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