summaryrefslogtreecommitdiff
path: root/libavcodec/jpeg2000.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2015-11-15 22:05:04 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2015-11-15 22:11:05 +0100
commit0eb7de19736891a9386ab66549f780e904a3b6a7 (patch)
tree7005b8d9ba682290248544bc9ca590ec25ea6210 /libavcodec/jpeg2000.h
parent65d3359fb366ea265a8468d76a111cb7352f0b55 (diff)
avcodec/jpeg2000: Change coord to 32bit to support larger than 32k width or height
Fixes: 03e0abe721b1174856d41a1eb5d6a896/signal_sigabrt_7ffff6ae7cc9_3813_e71bf3541abed3ccba031cd5ba0269a4.avi Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/jpeg2000.h')
-rw-r--r--libavcodec/jpeg2000.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/libavcodec/jpeg2000.h b/libavcodec/jpeg2000.h
index 7a21c4e45f..ed3b421ad8 100644
--- a/libavcodec/jpeg2000.h
+++ b/libavcodec/jpeg2000.h
@@ -174,21 +174,21 @@ typedef struct Jpeg2000Cblk {
int nb_terminationsinc;
int data_start[JPEG2000_MAX_PASSES];
Jpeg2000Pass passes[JPEG2000_MAX_PASSES];
- uint16_t coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
+ int coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
} Jpeg2000Cblk; // code block
typedef struct Jpeg2000Prec {
- uint16_t nb_codeblocks_width;
- uint16_t nb_codeblocks_height;
+ int nb_codeblocks_width;
+ int nb_codeblocks_height;
Jpeg2000TgtNode *zerobits;
Jpeg2000TgtNode *cblkincl;
Jpeg2000Cblk *cblk;
int decoded_layers;
- uint16_t coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
+ int coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
} Jpeg2000Prec; // precinct
typedef struct Jpeg2000Band {
- uint16_t coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
+ int coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
uint16_t log2_cblk_width, log2_cblk_height;
int i_stepsize; // quantization stepsize
float f_stepsize; // quantization stepsize
@@ -197,8 +197,8 @@ typedef struct Jpeg2000Band {
typedef struct Jpeg2000ResLevel {
uint8_t nbands;
- uint16_t coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
- uint16_t num_precincts_x, num_precincts_y; // number of precincts in x/y direction
+ int coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}}
+ int num_precincts_x, num_precincts_y; // number of precincts in x/y direction
uint8_t log2_prec_width, log2_prec_height; // exponent of precinct size
Jpeg2000Band *band;
} Jpeg2000ResLevel; // resolution level
@@ -208,8 +208,8 @@ typedef struct Jpeg2000Component {
DWTContext dwt;
float *f_data;
int *i_data;
- uint16_t coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}} -- can be reduced with lowres option
- uint16_t coord_o[2][2]; // border coordinates {{x0, x1}, {y0, y1}} -- original values from jpeg2000 headers
+ int coord[2][2]; // border coordinates {{x0, x1}, {y0, y1}} -- can be reduced with lowres option
+ int coord_o[2][2]; // border coordinates {{x0, x1}, {y0, y1}} -- original values from jpeg2000 headers
} Jpeg2000Component;
/* misc tools */