[FFmpeg-cvslog] x86: mpegvideoenc: fix linking with --disable-mmx
Diego Biurrun
git at videolan.org
Wed Aug 29 18:16:19 CEST 2012
ffmpeg | branch: master | Diego Biurrun <diego at biurrun.de> | Tue Aug 28 17:45:24 2012 +0200| [2f2aa2e5426d89762b3c156275d903419e9cf570] | committer: Diego Biurrun
x86: mpegvideoenc: fix linking with --disable-mmx
The optimized dct_quantize template functions reference optimized
fdct symbols, so these functions must only be enabled if the relevant
optimizations have been enabled by configure.
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=2f2aa2e5426d89762b3c156275d903419e9cf570
---
libavcodec/x86/mpegvideoenc.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/libavcodec/x86/mpegvideoenc.c b/libavcodec/x86/mpegvideoenc.c
index 184912d..946240d 100644
--- a/libavcodec/x86/mpegvideoenc.c
+++ b/libavcodec/x86/mpegvideoenc.c
@@ -89,11 +89,11 @@ void ff_MPV_encode_init_x86(MpegEncContext *s)
s->dct_quantize = dct_quantize_SSSE3;
} else
#endif
- if (mm_flags & AV_CPU_FLAG_SSE2) {
+ if (mm_flags & AV_CPU_FLAG_SSE2 && HAVE_SSE) {
s->dct_quantize = dct_quantize_SSE2;
- } else if (mm_flags & AV_CPU_FLAG_MMXEXT) {
+ } else if (mm_flags & AV_CPU_FLAG_MMXEXT && HAVE_MMXEXT) {
s->dct_quantize = dct_quantize_MMX2;
- } else {
+ } else if (mm_flags & AV_CPU_FLAG_MMX && HAVE_MMX) {
s->dct_quantize = dct_quantize_MMX;
}
}
More information about the ffmpeg-cvslog
mailing list