Skip to content
Snippets Groups Projects
Commit 75c37c5a authored by Martin Storsjö's avatar Martin Storsjö
Browse files

swscale: Provide the right alignment for external mmx asm


This reverts parts of e0c6cce4. There is external mmx asm that
requires this alignment.

This fixes crashes when using swscale in builds with external mmx,
without inline assembly.

Signed-off-by: default avatarMartin Storsjö <martin@martin.st>
parent e0c6cce4
No related branches found
No related tags found
No related merge requests found
...@@ -1050,7 +1050,8 @@ av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter, ...@@ -1050,7 +1050,8 @@ av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter,
} else } else
#endif /* HAVE_MMXEXT_INLINE */ #endif /* HAVE_MMXEXT_INLINE */
{ {
const int filterAlign = INLINE_MMX(cpu_flags) ? 4 : const int filterAlign =
(HAVE_MMX && cpu_flags & AV_CPU_FLAG_MMX) ? 4 :
(HAVE_ALTIVEC && cpu_flags & AV_CPU_FLAG_ALTIVEC) ? 8 : (HAVE_ALTIVEC && cpu_flags & AV_CPU_FLAG_ALTIVEC) ? 8 :
1; 1;
...@@ -1073,7 +1074,8 @@ av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter, ...@@ -1073,7 +1074,8 @@ av_cold int sws_init_context(SwsContext *c, SwsFilter *srcFilter,
/* precalculate vertical scaler filter coefficients */ /* precalculate vertical scaler filter coefficients */
{ {
const int filterAlign = INLINE_MMX(cpu_flags) ? 2 : const int filterAlign =
(HAVE_MMX && cpu_flags & AV_CPU_FLAG_MMX) ? 2 :
(HAVE_ALTIVEC && cpu_flags & AV_CPU_FLAG_ALTIVEC) ? 8 : (HAVE_ALTIVEC && cpu_flags & AV_CPU_FLAG_ALTIVEC) ? 8 :
1; 1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment