public class QuicktimeTextSampleEntry extends AbstractSampleEntry
Modifier and Type | Field and Description |
---|---|
static String |
TYPE |
largeBox, type
boxParser, dataSource
Constructor and Description |
---|
QuicktimeTextSampleEntry() |
Modifier and Type | Method and Description |
---|---|
void |
addBox(Box box)
Add
box to the container and sets the parent correctly. |
int |
getBackgroundB() |
int |
getBackgroundG() |
int |
getBackgroundR() |
void |
getBox(WritableByteChannel writableByteChannel)
Writes the complete box - size | 4-cc | content - to the given
writableByteChannel . |
long |
getDefaultTextBox() |
int |
getDisplayFlags() |
short |
getFontFace() |
String |
getFontName() |
short |
getFontNumber() |
int |
getForegroundB() |
int |
getForegroundG() |
int |
getForegroundR() |
long |
getReserved1() |
byte |
getReserved2() |
short |
getReserved3() |
long |
getSize() |
int |
getTextJustification() |
void |
parse(DataSource dataSource,
ByteBuffer header,
long contentSize,
BoxParser boxParser)
Parses the box excluding the already parsed header (size, 4cc, [long-size], [user-type]).
|
void |
setBackgroundB(int backgroundB) |
void |
setBackgroundG(int backgroundG) |
void |
setBackgroundR(int backgroundR) |
void |
setBoxes(List<Box> boxes)
Sets all boxes and removes all previous child boxes.
|
void |
setDefaultTextBox(long defaultTextBox) |
void |
setDisplayFlags(int displayFlags) |
void |
setFontFace(short fontFace) |
void |
setFontName(String fontName) |
void |
setFontNumber(short fontNumber) |
void |
setForegroundB(int foregroundB) |
void |
setForegroundG(int foregroundG) |
void |
setForegroundR(int foregroundR) |
void |
setReserved1(long reserved1) |
void |
setReserved2(byte reserved2) |
void |
setReserved3(short reserved3) |
void |
setTextJustification(int textJustification) |
getDataReferenceIndex, setDataReferenceIndex
getHeader, getOffset, getParent, getType, initContainer, setParent
close, getBoxes, getBoxes, getBoxes, getByteBuffer, getContainerSize, hasNext, next, remove, toString, writeContainer
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getOffset, getParent, getType, setParent
getBoxes, getBoxes, getBoxes, getByteBuffer, writeContainer
forEachRemaining
public static final String TYPE
public void parse(DataSource dataSource, ByteBuffer header, long contentSize, BoxParser boxParser) throws IOException
Box
contentSize
, contentSize
number of bytes should be read from the box source (readableByteChannel
).
If you need the header
buffer at a later stage you have to create a copy.parse
in interface Box
parse
in class AbstractSampleEntry
dataSource
- the source for this boxheader
- the box' already parsed header (create copy if you need it
later as it will be overwritten)contentSize
- remaining bytes of this boxboxParser
- use it to parse sub-boxes.IOException
- in case of an error during a read operationpublic void setBoxes(List<Box> boxes)
Container
setBoxes
in interface Container
setBoxes
in class BasicContainer
boxes
- the new list of childrenpublic void addBox(Box box)
BasicContainer
box
to the container and sets the parent correctly. If box
is null
nochange will be performed and no error thrown.addBox
in class BasicContainer
box
- will be added to the containerpublic void getBox(WritableByteChannel writableByteChannel) throws IOException
Box
writableByteChannel
.getBox
in interface Box
getBox
in class AbstractSampleEntry
writableByteChannel
- the box's sinkIOException
- in case of problems with the Channel
public long getSize()
getSize
in interface Box
getSize
in class AbstractContainerBox
public int getDisplayFlags()
public void setDisplayFlags(int displayFlags)
public int getTextJustification()
public void setTextJustification(int textJustification)
public int getBackgroundR()
public void setBackgroundR(int backgroundR)
public int getBackgroundG()
public void setBackgroundG(int backgroundG)
public int getBackgroundB()
public void setBackgroundB(int backgroundB)
public long getDefaultTextBox()
public void setDefaultTextBox(long defaultTextBox)
public long getReserved1()
public void setReserved1(long reserved1)
public short getFontNumber()
public void setFontNumber(short fontNumber)
public short getFontFace()
public void setFontFace(short fontFace)
public byte getReserved2()
public void setReserved2(byte reserved2)
public short getReserved3()
public void setReserved3(short reserved3)
public int getForegroundR()
public void setForegroundR(int foregroundR)
public int getForegroundG()
public void setForegroundG(int foregroundG)
public int getForegroundB()
public void setForegroundB(int foregroundB)
public String getFontName()
public void setFontName(String fontName)
Copyright © 2017. All rights reserved.