|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface IMediaFileReader
IMediaFileReader - media file reader interface.
| Nested Class Summary | |
|---|---|
static class |
IMediaFileReader.TrackSample
TrackSample - track sample. |
| Method Summary | |
|---|---|
void |
close()
Closes media file and releases acquired resources. |
AudioTrackInfo |
getAudioTrackInfo(MediaTrackInfo info)
Returns audio track info. |
MediaFileContainer |
getContainer()
Returns media file container. |
java.util.Iterator<IMediaFileReader.TrackSample> |
getTrackSamples(MediaTrackInfo track,
long timestamp)
Returns track samples. |
MediaTrackInfo[] |
getTracksInfo()
Returns tracks info. |
VideoTrackInfo |
getVideoTrackInfo(MediaTrackInfo info)
Returns video track info. |
ByteArray |
readTrackSample(IMediaFileReader.TrackSample sample,
byte[] buf,
int offset)
Reads sample from the media file. |
| Method Detail |
|---|
MediaFileContainer getContainer()
MediaTrackInfo[] getTracksInfo()
AudioTrackInfo getAudioTrackInfo(MediaTrackInfo info)
info -
VideoTrackInfo getVideoTrackInfo(MediaTrackInfo info)
info -
java.util.Iterator<IMediaFileReader.TrackSample> getTrackSamples(MediaTrackInfo track,
long timestamp)
track samples.
track - track info, if null then samples of all tracks are returned (interleaved)timestamp - start timestamp (in milliseconds), if container contains video then timestamp is aligned to the previous key frame
ByteArray readTrackSample(IMediaFileReader.TrackSample sample,
byte[] buf,
int offset)
throws java.io.IOException
sample from the media file.
Note:
- if buffer length is not enough a new buffer is created
sample - sample to usebuf - buffer to useoffset - buffer offset
java.io.IOException - if an I/O exception occurred
void close()
throws java.io.IOException
java.io.IOException - if an I/O exception occurred
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||