|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.media.Format | +--javax.media.format.VideoFormat
Encapsulates format information for
video data.
The attributes of a VideoFormat
include
the encoding type, frame size,
frame rate, and the data type.
Field Summary | |
static java.lang.String |
CINEPAK
Cinepak format. |
protected float |
frameRate
|
static java.lang.String |
H261
H.261 format. |
static java.lang.String |
H261_RTP
H261 RTP format |
static java.lang.String |
H263
H.263 format. |
static java.lang.String |
H263_1998_RTP
H.263+ (RFC 2429 aka H263-1998) RTP format |
static java.lang.String |
H263_RTP
H.263 (RFC 2190) RTP format |
static java.lang.String |
INDEO32
Indeo Video 3.2 |
static java.lang.String |
INDEO41
Indeo Interactive 4.1 |
static java.lang.String |
INDEO50
Indeo Interactive 5.0 |
static java.lang.String |
IRGB
8-bit Indexed RGB format. |
static java.lang.String |
JPEG
JPEG format. |
static java.lang.String |
JPEG_RTP
JPEG RTP format |
protected int |
maxDataLength
|
static java.lang.String |
MJPEGA
Motion JPEG-A format. |
static java.lang.String |
MJPEGB
Motion JPEG-B format. |
static java.lang.String |
MJPG
Motion JPEG format. |
static java.lang.String |
MPEG
MPEG format. |
static java.lang.String |
MPEG_RTP
MPEG RTP format. |
static java.lang.String |
RGB
Raw RGB format. |
static java.lang.String |
RLE
Run Length Encoded video format. |
static java.lang.String |
RPZA
|
protected java.awt.Dimension |
size
|
static java.lang.String |
SMC
Sorensen format. |
static java.lang.String |
YUV
Raw YUV or YCrCb format. |
Fields inherited from class javax.media.Format |
byteArray,
clz,
dataType,
encoding,
FALSE,
formatArray,
intArray,
NOT_SPECIFIED,
shortArray,
TRUE |
Constructor Summary | |
VideoFormat(java.lang.String encoding)
Constructs a VideoFormat with the specified encoding type. |
|
VideoFormat(java.lang.String encoding,
java.awt.Dimension size,
int maxDataLength,
java.lang.Class dataType,
float frameRate)
Constructs a VideoFormat with the specified attributes. |
Method Summary | |
java.lang.Object |
clone()
Creates a clone of this VideoFormat by copying each field to
the clone. |
protected void |
copy(Format f)
Copies the attributes from the specified Format into this VideoFormat . |
boolean |
equals(java.lang.Object format)
Compares the specified Format with this VideoFormat . |
float |
getFrameRate()
Gets the frame rate associated with this VideoFormat . |
int |
getMaxDataLength()
Gets the length of the largest data chunk associated with this VideoFormat . |
java.awt.Dimension |
getSize()
Gets the dimensions of a video frame in this VideoFormat . |
Format |
intersects(Format format)
Finds the attributes shared by two matching Format objects. |
boolean |
matches(Format format)
Checks whether or not the specified Format matches
this VideoFormat . |
Format |
relax()
Generate a format that's less restrictive than this format but contains the basic attributes that will make this resulting format useful for format matching. |
java.lang.String |
toString()
Gets a String representation of the attributes of this
VideoFormat . |
Methods inherited from class javax.media.Format |
getDataType,
getEncoding,
isSameEncoding,
isSameEncoding |
Methods inherited from class java.lang.Object |
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
protected java.awt.Dimension size
protected int maxDataLength
protected float frameRate
public static final java.lang.String CINEPAK
public static final java.lang.String JPEG
public static final java.lang.String JPEG_RTP
public static final java.lang.String MPEG
public static final java.lang.String MPEG_RTP
public static final java.lang.String H261
public static final java.lang.String H261_RTP
public static final java.lang.String H263
public static final java.lang.String H263_RTP
public static final java.lang.String H263_1998_RTP
public static final java.lang.String RGB
public static final java.lang.String YUV
public static final java.lang.String IRGB
public static final java.lang.String SMC
public static final java.lang.String RLE
public static final java.lang.String RPZA
public static final java.lang.String MJPG
public static final java.lang.String MJPEGA
public static final java.lang.String MJPEGB
public static final java.lang.String INDEO32
public static final java.lang.String INDEO41
public static final java.lang.String INDEO50
Constructor Detail |
public VideoFormat(java.lang.String encoding)
VideoFormat
with the specified encoding type.encoding
- A String
that describes the encoding type
for this VideoFormat
.public VideoFormat(java.lang.String encoding, java.awt.Dimension size, int maxDataLength, java.lang.Class dataType, float frameRate)
VideoFormat
with the specified attributes.encoding
- A String
that describes the encoding
type for this VideoFormat
.size
- The size of a video frame.maxDataLength
- The maximum length of a data chunk.dataType
- The type of data. For example, byte array.frameRate
- The frame rate.Method Detail |
public java.awt.Dimension getSize()
VideoFormat
.Dimension
that specifies the frame size.public int getMaxDataLength()
VideoFormat
.VideoFormat
.public java.lang.Object clone()
VideoFormat
by copying each field to
the clone.VideoFormat
.public float getFrameRate()
VideoFormat
.protected void copy(Format f)
Format
into this VideoFormat
.f
- The Format
to copy the attributes from.public java.lang.String toString()
String
representation of the attributes of this
VideoFormat
. For example: "RGB, 352x240, ...".String
that describes the
VideoFormat
attributes.public boolean equals(java.lang.Object format)
Format
with this VideoFormat
.
Returns true
only if the specified Format
is a VideoFormat
object and all of
its attributes are identical to
the attributes in this VideoFormat
.format
- The Format
to compare.Format
is the same as this one.public boolean matches(Format format)
Format
matches
this VideoFormat
.
Matches only compares the attributes that are defined in the specified
Format
,
unspecified attributes are ignored.
The two Format
objects do not have to be of the same class
to match. For example, if "A" are "B" are being compared, a
match is possible if "A" is derived from "B"
or "B" is derived from "A". (The compared attributes must still match,
or matches
fails.)
format
- The Format
to compare with this one.true
if the specified Format
matches this one, false
if it does not.public Format intersects(Format format)
Format
objects.
If the specified Format
does not match this one, the result
is undefined.The
- matching Format
to intersect with this
VideoFormat
.Format
object
with its attributes set to those attributes common to both
Format
objects.matches(javax.media.Format)
public Format relax()
Format
that's less restrictive than the
this format.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |