diff options
| author | Antonin Descampe <antonin@gmail.com> | 2014-11-03 14:12:01 +0000 |
|---|---|---|
| committer | Antonin Descampe <antonin@gmail.com> | 2014-11-03 14:12:01 +0000 |
| commit | cf5153c518045027f286e08af36809237a76a7df (patch) | |
| tree | b099fbd31bf15f254addb20036e78c3e0bdd12bd /src/bin/jp2/convert.c | |
| parent | 3b7dced8e66418ab90c1f7398fc36453e834f4dc (diff) | |
[trunk] add a cdef box when alpha component is present (fixes issue 416)
Diffstat (limited to 'src/bin/jp2/convert.c')
| -rw-r--r-- | src/bin/jp2/convert.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/bin/jp2/convert.c b/src/bin/jp2/convert.c index 606238d1..6af7b7ab 100644 --- a/src/bin/jp2/convert.c +++ b/src/bin/jp2/convert.c @@ -3364,7 +3364,10 @@ opj_image_t *pngtoimage(const char *read_idf, opj_cparameters_t * params) r = image->comps[0].data; g = image->comps[1].data; b = image->comps[2].data; - if(has_alpha) a = image->comps[3].data; + if(has_alpha) { + a = image->comps[3].data; + image->comps[3].alpha = 1; + } for(i = 0; i < height; ++i) { |
