Skip to content

Commit

Permalink
Fix the problem that a tile with TNsot = 0 for all the tile-parts is …
Browse files Browse the repository at this point in the history
…never decoded

Why: If a tile has multiple tile-parts and all the tile-parts have the TNsot (a parameter in the tile-part header) = 0, such a tile is never decoded.
How: Modified the condition whether jpc_dec_tiledecode() shall be invoked or not in jpc_dec_process_eoc()
  • Loading branch information
osamu620 committed Jul 30, 2020
1 parent 1c220a1 commit cc814c9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/libjasper/jpc/jpc_dec.c
Original file line number Diff line number Diff line change
Expand Up @@ -1232,7 +1232,8 @@ static int jpc_dec_process_eoc(jpc_dec_t *dec, jpc_ms_t *ms)

for (tileno = 0, tile = dec->tiles; tileno < dec->numtiles; ++tileno,
++tile) {
if (tile->state == JPC_TILE_ACTIVE) {
if (tile->state == JPC_TILE_ACTIVE ||
tile->state == JPC_TILE_ACTIVELAST) {
if (jpc_dec_tiledecode(dec, tile)) {
return -1;
}
Expand Down

0 comments on commit cc814c9

Please sign in to comment.