a52dec: Allow liba52 to use djbfft based IMDCT transform

liba52 in a52dec-0.7.4 does not have any MMX, MMXEXT or 3DNOW based
IMDCT transform acceleration. It does however have a software based
acceleration using the djbfft library (D.J. Bernstein's library for
fourier transforms - Extremely fast library for floating-point
convolution). So allow liba52 to use it through the MM_ACCEL_DJBFFT
flag.
The liba52 copy in MPlayer sources does have SSE, 3dnowext, 3dnow
and AltiVec implementations, but those are checked for first, and
djbfft is chosen only if none of those is available - good in the
case of some distributions including a port of the MPlayer changes
in their system a52dec library.

The down and upmix code in liba52 doesn't seem to be disturbed by
this additional MM_ACCEL flag and will still use MMX, SSE or 3DNOW
versions if passed from oil_cpu_get_flags (SSE currently is not).

Fixes bug #592787.
This commit is contained in:
Mart Raudsepp 2009-08-23 13:34:32 +02:00 committed by Sebastian Dröge
parent bd8df13ab0
commit ebfe6c0746

View file

@ -192,7 +192,9 @@ gst_a52dec_class_init (GstA52DecClass * klass)
oil_init ();
klass->a52_cpuflags = 0;
/* If no CPU instruction based acceleration is available, end up using the
* generic software djbfft based one when available in the used liba52 */
klass->a52_cpuflags = MM_ACCEL_DJBFFT;
cpuflags = oil_cpu_get_flags ();
if (cpuflags & OIL_IMPL_FLAG_MMX)
klass->a52_cpuflags |= MM_ACCEL_X86_MMX;