summaryrefslogtreecommitdiff
path: root/libavcodec/jpeg2000.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-06-26 00:14:01 +0200
committerMichael Niedermayer <michaelni@gmx.at>2015-06-26 01:00:17 +0200
commitf1e173049ecc9de03817385ba8962d14cba779db (patch)
tree3f7b64ee98dc6804b5124d0d414bf5255b0624a5 /libavcodec/jpeg2000.h
parent8c22143e7e006bb66bc380a874ceb609b62d8997 (diff)
avcodec/jpeg2000: Remove CBLK limit
This also reduces the amount of memory needed Fixes Ticket4672 The new code seems slightly faster as well, probably due to better cache usage Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/jpeg2000.h')
-rw-r--r--libavcodec/jpeg2000.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/libavcodec/jpeg2000.h b/libavcodec/jpeg2000.h
index 24395a24eb..0acad79eff 100644
--- a/libavcodec/jpeg2000.h
+++ b/libavcodec/jpeg2000.h
@@ -67,10 +67,6 @@ enum Jpeg2000Quantsty { // quantization style
JPEG2000_QSTY_SE // scalar expounded
};
-#define JPEG2000_MAX_CBLKW 128
-#define JPEG2000_MAX_CBLKH 128
-
-
#define JPEG2000_MAX_DECLEVELS 32
#define JPEG2000_MAX_RESLEVELS (JPEG2000_MAX_DECLEVELS + 1)
@@ -123,9 +119,10 @@ enum Jpeg2000Quantsty { // quantization style
#define JPEG2000_PGOD_CPRL 0x04 // Component-position-resolution level-layer progression
typedef struct Jpeg2000T1Context {
- int data[JPEG2000_MAX_CBLKW][JPEG2000_MAX_CBLKH];
- uint16_t flags[JPEG2000_MAX_CBLKW + 2][JPEG2000_MAX_CBLKH + 2];
+ int data[6144];
+ uint16_t flags[6156];
MqcState mqc;
+ int stride;
} Jpeg2000T1Context;
typedef struct Jpeg2000TgtNode {