|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.media.util.ImageToBuffer
Utility class to convert an AWT Image
object to a JMF
Buffer
object. The output buffer will contain the image
data in an array of ints in the default ColorModel of the AWT toolkit.
The getFormat
method on the returned buffer will contain
the exact format that the data is in, including the RGB mask values.
Constructor Summary | |
ImageToBuffer()
|
Method Summary | |
static Buffer |
createBuffer(java.awt.Image image,
float frameRate)
Creates a JMF Buffer object for the given AWT Image
and frameRate. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public ImageToBuffer()
Method Detail |
public static Buffer createBuffer(java.awt.Image image, float frameRate)
Buffer
object for the given AWT Image
and frameRate. If the frameRate parameter of the output format is
not relevant to your needs, then any value can be specified as the
frameRate. If you are generating live video data that is to be
presented by JMF, then you should specify a reasonable value between
1 and 60 for the frameRate.The output buffer will have unspecified
values for the flags, sequenceNumber, header and timeStamp
fields. Only the format, data, offset and length
will
contain valid values.
image
- an AWT Image that is fully prepared and has a known size.frameRate
- the frameRate at which these buffer objects are being
generated.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |