Merge pull request #193 from bogdanni/patch-1
'cmap' - correct stride interpreting CMP,MTYP,PCOL
This commit is contained in:
commit
847d121972
1 changed files with 3 additions and 3 deletions
|
|
@ -879,9 +879,9 @@ class ComponentMappingBox(Jp2kBox):
|
|||
read_buffer = fptr.read(num_bytes)
|
||||
data = struct.unpack('>' + 'HBB' * num_components, read_buffer)
|
||||
|
||||
component_index = data[0:num_bytes:num_components]
|
||||
mapping_type = data[1:num_bytes:num_components]
|
||||
palette_index = data[2:num_bytes:num_components]
|
||||
component_index = data[0:num_bytes:3]
|
||||
mapping_type = data[1:num_bytes:3]
|
||||
palette_index = data[2:num_bytes:3]
|
||||
|
||||
box = ComponentMappingBox(component_index, mapping_type, palette_index,
|
||||
length=length, offset=offset)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue