|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectfi.helsinki.cs.ohtu.mpeg2.video.IntraBlock
public class IntraBlock
Represents a block in an intra type macroblock.
| Nested Class Summary | |
|---|---|
static class |
IntraBlock.ColourComponent
The possible types of intra blocks. |
static class |
IntraBlock.Predictors
Encapsulates the predictors used in the encoding of intra blocks. |
| Field Summary | |
|---|---|
private IntraBlock.ColourComponent |
cc
|
private int[] |
coefficients
|
private IntraBlock.Predictors |
predictors
|
private VLC.IntraVLCFormat |
vlcFormat
|
| Constructor Summary | |
|---|---|
IntraBlock(IntraBlock.ColourComponent cc,
IntraBlock.Predictors predictors,
int[] coefficients,
VLC.IntraVLCFormat vlcFormat)
Constructs a new IntraBlock with the given colour component,
predictors, coefficients and intra VLC format. |
|
| Method Summary | |
|---|---|
int[] |
getCoefficients()
Returns the coefficients of this block. |
IntraBlock.ColourComponent |
getColourComponent()
Returns the colour component selected for this block. |
IntraBlock.Predictors |
getPredictors()
Returns the IntraBlock.Predictors instance this block uses. |
VLC.IntraVLCFormat |
getVLCFormat()
Returns the intra VLC format of this block. |
private int |
selectDCSize(int differential)
|
void |
setCoefficients(int[] coefficients)
Sets the coefficients for this block. |
void |
setColourComponent(IntraBlock.ColourComponent cc)
Sets this blocks colour component. |
void |
setPredictors(IntraBlock.Predictors predictors)
Sets the IntraBlock.Predictors instance this block should use. |
void |
setVLCFormat(VLC.IntraVLCFormat vlcFormat)
Sets this blocks intra VLC format. |
void |
writeTo(BitOutputStream stream)
Writes the block to a stream. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private IntraBlock.ColourComponent cc
private IntraBlock.Predictors predictors
private int[] coefficients
private VLC.IntraVLCFormat vlcFormat
| Constructor Detail |
|---|
public IntraBlock(IntraBlock.ColourComponent cc,
IntraBlock.Predictors predictors,
int[] coefficients,
VLC.IntraVLCFormat vlcFormat)
IntraBlock with the given colour component,
predictors, coefficients and intra VLC format.
cc - The colour component to use.predictors - The IntraBlock.Predictors to use. The instance should be the same
for atleast all intra blocks to be written without a predictor
reset.coefficients - The coefficients to use. Must be an array of 64 elements.vlcFormat - The intra VLC format for this block.| Method Detail |
|---|
public IntraBlock.ColourComponent getColourComponent()
public void setColourComponent(IntraBlock.ColourComponent cc)
cc - The new colour component to use.public IntraBlock.Predictors getPredictors()
IntraBlock.Predictors instance this block uses.
public void setPredictors(IntraBlock.Predictors predictors)
IntraBlock.Predictors instance this block should use.
predictors - The new predictors to use.public int[] getCoefficients()
public void setCoefficients(int[] coefficients)
coefficients - The new coefficients. Must be 64 elements long.public VLC.IntraVLCFormat getVLCFormat()
public void setVLCFormat(VLC.IntraVLCFormat vlcFormat)
vlcFormat - The intra VLC format to use.
public void writeTo(BitOutputStream stream)
throws java.io.IOException
Block
writeTo in interface Blockstream - The stream to write to.
java.io.IOException - Exception from the stream.private int selectDCSize(int differential)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||