Skip to content

Commit

Permalink
VAAPI: Don't test for support if we don't want it.
Browse files Browse the repository at this point in the history
Refs #8593
  • Loading branch information
Mark Kendall committed Jun 20, 2011
1 parent 5b046b4 commit 651b83b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions mythtv/libs/libmythtv/videoout_openglvaapi.cpp
Expand Up @@ -272,14 +272,14 @@ MythCodecID VideoOutputOpenGLVAAPI::GetBestSupportedCodec(
vdp.SetInput(size);
QString dec = vdp.GetDecoder();

PixelFormat fmt = PIX_FMT_YUV420P;
PixelFormat fmt = PIX_FMT_YUV420P;
MythCodecID test_cid = (MythCodecID)(kCodec_MPEG1_VAAPI + (stream_type - 1));
if (codec_is_vaapi(test_cid))
if (codec_is_vaapi(test_cid) && dec == "vaapi" && !getenv("NO_VAAPI"))
use_cpu |= !VAAPIContext::IsFormatAccelerated(size, test_cid, fmt);
else
use_cpu = true;

if ((dec != "vaapi") || getenv("NO_VAAPI") || use_cpu)
if (use_cpu)
return (MythCodecID)(kCodec_MPEG1 + (stream_type - 1));

pix_fmt = fmt;
Expand Down

0 comments on commit 651b83b

Please sign in to comment.