summaryrefslogtreecommitdiffstats
path: root/libvo
diff options
context:
space:
mode:
authorsiretart <siretart@b3059339-0415-0410-9bf9-f77b7e298cf2>2010-06-03 21:50:08 +0000
committersiretart <siretart@b3059339-0415-0410-9bf9-f77b7e298cf2>2010-06-03 21:50:08 +0000
commit9e2e3a1cb8daea51ea691b540c4b6feee074217b (patch)
treef5567b12e9e6fe44f1a4d4227d812ef8cb6204e8 /libvo
parent637edc7a27d5438c9c55be30f548b3fbf4543f05 (diff)
downloadmpv-9e2e3a1cb8daea51ea691b540c4b6feee074217b.tar.bz2
mpv-9e2e3a1cb8daea51ea691b540c4b6feee074217b.tar.xz
apply missing bits from http://repo.or.cz/w/mplayer.git/commitdiff/cd4e8dc1fa2863dcce62a44dd9ea105f9f9288f4
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31314 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo')
-rw-r--r--libvo/vo_yuv4mpeg.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libvo/vo_yuv4mpeg.c b/libvo/vo_yuv4mpeg.c
index d06e79903d..01bfa8164b 100644
--- a/libvo/vo_yuv4mpeg.c
+++ b/libvo/vo_yuv4mpeg.c
@@ -149,6 +149,7 @@ static int config(uint32_t width, uint32_t height, uint32_t d_width,
return -1;
}
+#ifdef CONFIG_LIBSWSCALE_A
if(using_format != IMGFMT_YV12)
{
sws_rgb2rgb_init(get_sws_cpuflags());
@@ -160,6 +161,7 @@ static int config(uint32_t width, uint32_t height, uint32_t d_width,
return -1;
}
}
+#endif
write_bytes = image_width * image_height * 3 / 2;
image = malloc(write_bytes);
@@ -464,9 +466,11 @@ static int query_format(uint32_t format)
{
case IMGFMT_YV12:
return VFCAP_CSP_SUPPORTED|VFCAP_OSD|VFCAP_ACCEPT_STRIDE;
+#ifdef CONFIG_LIBSWSCALE_A
case IMGFMT_BGR|24:
case IMGFMT_RGB|24:
return VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW|VFCAP_OSD|VFCAP_ACCEPT_STRIDE;
+#endif
}
}
else
@@ -476,9 +480,11 @@ static int query_format(uint32_t format)
{
case IMGFMT_YV12:
return VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW|VFCAP_OSD|VFCAP_ACCEPT_STRIDE;
+#ifdef CONFIG_LIBSWSCALE_A
case IMGFMT_BGR|24:
case IMGFMT_RGB|24:
return VFCAP_CSP_SUPPORTED|VFCAP_OSD|VFCAP_ACCEPT_STRIDE;
+#endif
}
}
return 0;