mirror of https://github.com/mpv-player/mpv
update local diff after r20779
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21507 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
c9ef884026
commit
ad29a1dd81
|
@ -2389,9 +2389,9 @@
|
||||||
|
|
||||||
uint32_t mm_accel (void);
|
uint32_t mm_accel (void);
|
||||||
|
|
||||||
--- liba52/parse.c 2006-06-12 15:05:07.000000000 +0200
|
--- liba52/parse.c 2006-12-05 08:08:01.000000000 +0100
|
||||||
+++ liba52/parse.c 2006-06-12 14:51:33.000000000 +0200
|
+++ liba52/parse.c 2006-12-05 08:08:44.000000000 +0100
|
||||||
@@ -24,6 +28,7 @@
|
@@ -28,6 +28,7 @@
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
@ -2399,11 +2399,12 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
|
|
||||||
@@ -31,13 +36,11 @@
|
@@ -35,13 +36,12 @@
|
||||||
#include "a52_internal.h"
|
#include "a52_internal.h"
|
||||||
#include "bitstream.h"
|
#include "bitstream.h"
|
||||||
#include "tables.h"
|
#include "tables.h"
|
||||||
+#include "mm_accel.h"
|
+#include "mm_accel.h"
|
||||||
|
+#include "libavutil/avutil.h"
|
||||||
|
|
||||||
#ifdef HAVE_MEMALIGN
|
#ifdef HAVE_MEMALIGN
|
||||||
/* some systems have memalign() but no declaration for it */
|
/* some systems have memalign() but no declaration for it */
|
||||||
|
@ -2414,19 +2415,14 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
@@ -61,6 +64,21 @@
|
@@ -64,7 +64,16 @@
|
||||||
|
if (state == NULL)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
state->samples = memalign (16, 256 * 12 * sizeof (sample_t));
|
|
||||||
+#if defined(__MINGW32__) && defined(HAVE_SSE)
|
+#if defined(__MINGW32__) && defined(HAVE_SSE)
|
||||||
+ for(i=0;i<10;i++){
|
+ state->samples = av_malloc(256 * 12 * sizeof (sample_t));
|
||||||
+ if((int)state->samples%16){
|
+#else
|
||||||
+ sample_t* samplestmp=malloc(256 * 12 * sizeof (sample_t));
|
state->samples = memalign (16, 256 * 12 * sizeof (sample_t));
|
||||||
+ free(state->samples);
|
|
||||||
+ state->samples = samplestmp;
|
|
||||||
+ }
|
|
||||||
+ else break;
|
|
||||||
+ }
|
|
||||||
+#endif
|
+#endif
|
||||||
+ if(((int)state->samples%16) && (mm_accel&MM_ACCEL_X86_SSE)){
|
+ if(((int)state->samples%16) && (mm_accel&MM_ACCEL_X86_SSE)){
|
||||||
+ mm_accel &=~MM_ACCEL_X86_SSE;
|
+ mm_accel &=~MM_ACCEL_X86_SSE;
|
||||||
|
@ -2436,7 +2432,7 @@
|
||||||
if (state->samples == NULL) {
|
if (state->samples == NULL) {
|
||||||
free (state);
|
free (state);
|
||||||
return NULL;
|
return NULL;
|
||||||
@@ -74,6 +92,7 @@
|
@@ -78,6 +87,7 @@
|
||||||
state->lfsr_state = 1;
|
state->lfsr_state = 1;
|
||||||
|
|
||||||
a52_imdct_init (mm_accel);
|
a52_imdct_init (mm_accel);
|
||||||
|
@ -2444,7 +2440,7 @@
|
||||||
|
|
||||||
return state;
|
return state;
|
||||||
}
|
}
|
||||||
@@ -141,7 +160,7 @@
|
@@ -145,7 +155,7 @@
|
||||||
state->acmod = acmod = buf[6] >> 5;
|
state->acmod = acmod = buf[6] >> 5;
|
||||||
|
|
||||||
a52_bitstream_set_ptr (state, buf + 6);
|
a52_bitstream_set_ptr (state, buf + 6);
|
||||||
|
@ -2453,7 +2449,7 @@
|
||||||
|
|
||||||
if ((acmod == 2) && (bitstream_get (state, 2) == 2)) /* dsurmod */
|
if ((acmod == 2) && (bitstream_get (state, 2) == 2)) /* dsurmod */
|
||||||
acmod = A52_DOLBY;
|
acmod = A52_DOLBY;
|
||||||
@@ -172,28 +191,28 @@
|
@@ -176,28 +186,28 @@
|
||||||
|
|
||||||
chaninfo = !acmod;
|
chaninfo = !acmod;
|
||||||
do {
|
do {
|
||||||
|
@ -2490,7 +2486,7 @@
|
||||||
} while (addbsil--);
|
} while (addbsil--);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -680,7 +699,7 @@
|
@@ -684,7 +694,7 @@
|
||||||
state->fbw_expbap[i].exp[0],
|
state->fbw_expbap[i].exp[0],
|
||||||
state->fbw_expbap[i].exp + 1))
|
state->fbw_expbap[i].exp + 1))
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -2499,7 +2495,7 @@
|
||||||
}
|
}
|
||||||
if (lfeexpstr != EXP_REUSE) {
|
if (lfeexpstr != EXP_REUSE) {
|
||||||
do_bit_alloc |= 32;
|
do_bit_alloc |= 32;
|
||||||
@@ -755,7 +774,7 @@
|
@@ -759,7 +769,7 @@
|
||||||
if (bitstream_get (state, 1)) { /* skiple */
|
if (bitstream_get (state, 1)) { /* skiple */
|
||||||
i = bitstream_get (state, 9); /* skipl */
|
i = bitstream_get (state, 9); /* skipl */
|
||||||
while (i--)
|
while (i--)
|
||||||
|
@ -2508,3 +2504,15 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
samples = state->samples;
|
samples = state->samples;
|
||||||
|
@@ -900,6 +910,10 @@
|
||||||
|
|
||||||
|
void a52_free (a52_state_t * state)
|
||||||
|
{
|
||||||
|
- free (state->samples);
|
||||||
|
+#if defined(__MINGW32__) && defined(HAVE_SSE)
|
||||||
|
+ av_free (state->samples);
|
||||||
|
+#else
|
||||||
|
+ free (state->samples);
|
||||||
|
+#endif
|
||||||
|
free (state);
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue