summaryrefslogtreecommitdiffstats
path: root/contrib/a52dec/A01-thread-safe.patch
diff options
context:
space:
mode:
authorRodeo <[email protected]>2012-08-02 21:43:22 +0000
committerRodeo <[email protected]>2012-08-02 21:43:22 +0000
commitb3717d369763d620d548f224daeba5a7503fa972 (patch)
tree4742e9b49e03db2b1c558e10f40c2c821528e8f5 /contrib/a52dec/A01-thread-safe.patch
parentad257c9dac38fe3f7502b1058247b4458465c0a8 (diff)
Use hb_audio_resample for downmixing AC3 sources. DRC is still applied by liba52.
Add support for center & surround mix levels to hb_audio_resample. This allows us to support upmixing all audio sources. For sources that have at least 2 front and one back or side channel(s), allow upmixing to 5.1: 3.0/3.1 (2 front and 1 back channels) 4.0/4.1 (3 front and 1 back channels) 4.0/4.1 (2 front and 2 side channels) 5.0 (3 front and 2 side channels) git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4885 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'contrib/a52dec/A01-thread-safe.patch')
-rw-r--r--contrib/a52dec/A01-thread-safe.patch41
1 files changed, 22 insertions, 19 deletions
diff --git a/contrib/a52dec/A01-thread-safe.patch b/contrib/a52dec/A01-thread-safe.patch
index 0fa7f0a53..4ca2d1a08 100644
--- a/contrib/a52dec/A01-thread-safe.patch
+++ b/contrib/a52dec/A01-thread-safe.patch
@@ -1,19 +1,19 @@
-diff -Naur -x '*.o' -x '*.lo' -x '*.a' -x '*.la' a52dec/liba52/a52_internal.h ../a52dec.new/liba52/a52_internal.h
---- a52dec/liba52/a52_internal.h 2011-04-28 07:54:05.499052327 -0700
-+++ ../a52dec.new/liba52/a52_internal.h 2011-04-28 07:50:30.998845068 -0700
-@@ -32,6 +32,11 @@
- int8_t bap[256]; /* derived channel bit allocation */
+diff -Naur a52dec.old/include/a52.h a52dec.new/include/a52.h
+--- a52dec.old/include/a52.h 2012-07-16 14:24:14.000000000 +0200
++++ a52dec.new/include/a52.h 2012-07-16 14:31:37.000000000 +0200
+@@ -42,6 +42,11 @@
} expbap_t;
-+typedef struct complex_s {
+ typedef struct {
+ sample_t real;
+ sample_t imag;
+} complex_t;
+
- struct a52_state_s {
- uint8_t fscod; /* sample rate */
- uint8_t halfrate; /* halfrate factor */
-@@ -85,6 +90,20 @@
++typedef struct {
+ uint8_t fscod; /* sample rate */
+ uint8_t halfrate; /* halfrate factor */
+ uint8_t acmod; /* coded channels */
+@@ -94,6 +99,20 @@
sample_t * samples;
int downmixed;
@@ -31,10 +31,13 @@ diff -Naur -x '*.o' -x '*.lo' -x '*.a' -x '*.la' a52dec/liba52/a52_internal.h ..
+ complex_t * post2; // size 32
+
+ sample_t * a52_imdct_window; // size 256
- };
+ } a52_state_t;
- #define LEVEL_PLUS6DB 2.0
-@@ -119,6 +138,6 @@
+ #define A52_CHANNEL 0
+diff -Naur a52dec.old/liba52/a52_internal.h a52dec.new/liba52/a52_internal.h
+--- a52dec.old/liba52/a52_internal.h 2012-07-16 14:24:14.000000000 +0200
++++ a52dec.new/liba52/a52_internal.h 2012-07-16 14:28:33.000000000 +0200
+@@ -49,6 +49,6 @@
sample_t clev, sample_t slev);
void a52_upmix (sample_t * samples, int acmod, int output);
@@ -44,9 +47,9 @@ diff -Naur -x '*.o' -x '*.lo' -x '*.a' -x '*.la' a52dec/liba52/a52_internal.h ..
+void a52_imdct_init (a52_state_t * state, uint32_t mm_accel);
+void a52_imdct_256 (a52_state_t * state, sample_t * data, sample_t * delay, sample_t bias);
+void a52_imdct_512 (a52_state_t * state, sample_t * data, sample_t * delay, sample_t bias);
-diff -Naur -x '*.o' -x '*.lo' -x '*.a' -x '*.la' a52dec/liba52/imdct.c ../a52dec.new/liba52/imdct.c
---- a52dec/liba52/imdct.c 2002-07-27 18:52:07.000000000 -0700
-+++ ../a52dec.new/liba52/imdct.c 2011-04-28 07:51:00.398624376 -0700
+diff -Naur a52dec.old/liba52/imdct.c a52dec.new/liba52/imdct.c
+--- a52dec.old/liba52/imdct.c 2012-07-16 14:24:14.000000000 +0200
++++ a52dec.new/liba52/imdct.c 2012-07-16 14:33:00.000000000 +0200
@@ -40,11 +40,6 @@
#include "a52_internal.h"
#include "mm_accel.h"
@@ -316,9 +319,9 @@ diff -Naur -x '*.o' -x '*.lo' -x '*.a' -x '*.la' a52dec/liba52/imdct.c ../a52dec
}
#ifdef LIBA52_DJBFFT
-diff -Naur -x '*.o' -x '*.lo' -x '*.a' -x '*.la' a52dec/liba52/parse.c ../a52dec.new/liba52/parse.c
---- a52dec/liba52/parse.c 2002-07-27 18:52:07.000000000 -0700
-+++ ../a52dec.new/liba52/parse.c 2011-04-28 07:40:48.030435061 -0700
+diff -Naur a52dec.old/liba52/parse.c a52dec.new/liba52/parse.c
+--- a52dec.old/liba52/parse.c 2012-07-16 14:24:14.000000000 +0200
++++ a52dec.new/liba52/parse.c 2012-07-16 14:33:00.000000000 +0200
@@ -56,16 +56,53 @@
a52_state_t * state;
int i;