Interface FakeMediaPeriod.TrackDataFactory
-
- Enclosing class:
- FakeMediaPeriod
public static interface FakeMediaPeriod.TrackDataFactoryA factory to create the test data for a particular track.
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description List<FakeSampleStream.FakeSampleStreamItem>create(Format format, MediaSource.MediaPeriodId mediaPeriodId)Returns the list ofFakeSampleStream.FakeSampleStreamItems that will be written the sample queue during playback.static FakeMediaPeriod.TrackDataFactorysingleSampleWithTimeUs(long sampleTimeUs)Returns a factory that always provides a single keyframe sample withtime=sampleTimeUsand then end-of-stream.
-
-
-
Method Detail
-
create
List<FakeSampleStream.FakeSampleStreamItem> create(Format format, MediaSource.MediaPeriodId mediaPeriodId)
Returns the list ofFakeSampleStream.FakeSampleStreamItems that will be written the sample queue during playback.- Parameters:
format- The format of the track to provide data for.mediaPeriodId- TheMediaSource.MediaPeriodIdto provide data for.- Returns:
- The track data in the form of
FakeSampleStream.FakeSampleStreamItems.
-
singleSampleWithTimeUs
static FakeMediaPeriod.TrackDataFactory singleSampleWithTimeUs(long sampleTimeUs)
Returns a factory that always provides a single keyframe sample withtime=sampleTimeUsand then end-of-stream.
-
-