Debian Codegraph @

src/com/drew/metadata/heif/boxes/PixelInformationBox.java

raw symbols SCIP
1 package com.drew.metadata.heif.boxes;
2
3 import com.drew.lang.SequentialReader;
4 import com.drew.metadata.heif.HeifDirectory;
5
6 import java.io.IOException;
7
8 /**
9 * ISO/IEC 23008-12:2017 pg.13
10 */
11 public class PixelInformationBox extends FullBox
12 {
13 int numChannels;
14 int[] channels;
15
16 public PixelInformationBox(SequentialReader reader, Box box) throws IOException
17 {
18 super(reader, box);
19
20 numChannels = reader.getUInt8();
21 channels = new int[numChannels];
22 for (int i = 0; i < channels.length; i++) {
23 channels[i] = reader.getUInt8();
24 }
25 }
26
27 public void addMetadata(HeifDirectory directory)
28 {
29 if (!directory.containsTag(HeifDirectory.TAG_BITS_PER_CHANNEL)) {
30 directory.setIntArray(HeifDirectory.TAG_BITS_PER_CHANNEL, channels);
31 }
32 }
33 }