Package com.jogamp.common.av
Class AudioSink.AudioFrame
- java.lang.Object
-
- com.jogamp.common.av.TimeFrameI
-
- com.jogamp.common.av.AudioSink.AudioFrame
-
- Direct Known Subclasses:
AudioSink.AudioDataFrame
- Enclosing interface:
- AudioSink
public abstract static class AudioSink.AudioFrame extends TimeFrameI
Abstract audio frame containing multiple audio samples per channel, trackingTimeFrameI
pts and size in bytes.One
AudioSink.AudioFrame
may contain multiple pairs of samples per channel, i.e. thisAudioSink.AudioFrame
does not limit a frame to be one sample per channel. See its application inAudioSink.enqueueData(int, ByteBuffer, int)
.Implementations may assign actual data to queue frames from streaming, see
AudioSink.AudioDataFrame
.
-
-
Field Summary
Fields Modifier and Type Field Description protected int
byteSize
-
Fields inherited from class com.jogamp.common.av.TimeFrameI
duration, END_OF_STREAM_PTS, INVALID_PTS, pts
-
-
Constructor Summary
Constructors Constructor Description AudioFrame()
Ctor w/ zero duration,TimeFrameI.INVALID_PTS
and zero byte sizeAudioFrame(int pts, int duration, int byteCount)
Create a new instance
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getByteSize()
Get this frame's size in bytes.void
setByteSize(int size)
Set this frame's size in bytes.String
toString()
-
Methods inherited from class com.jogamp.common.av.TimeFrameI
getDuration, getPTS, setDuration, setPTS
-
-
-
-
Constructor Detail
-
AudioFrame
public AudioFrame()
Ctor w/ zero duration,TimeFrameI.INVALID_PTS
and zero byte size
-
AudioFrame
public AudioFrame(int pts, int duration, int byteCount)
Create a new instance- Parameters:
pts
- frame pts in millisecondsduration
- frame duration in millisecondsbyteCount
- size in bytes
-
-
Method Detail
-
getByteSize
public final int getByteSize()
Get this frame's size in bytes.
-
setByteSize
public final void setByteSize(int size)
Set this frame's size in bytes.
-
toString
public String toString()
- Overrides:
toString
in classTimeFrameI
-
-