@Test public void testAdvanceToStartOfBuffer() { writeTestData(); int skipCount = sampleQueue.advanceTo(SAMPLE_TIMESTAMPS[0], true, false); assertThat(skipCount).isEqualTo(0); assertReadTestData(); assertNoSamplesToRead(FORMAT_2); }
public int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer) { return metadataQueue.advanceTo(timeUs, toKeyframe, allowTimeBeyondBuffer); }
SampleQueue implements TrackOutput { public int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer) { return metadataQueue.advanceTo(timeUs, toKeyframe, allowTimeBeyondBuffer); } }
SampleQueue implements TrackOutput { public int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer) { return metadataQueue.advanceTo(timeUs, toKeyframe, allowTimeBeyondBuffer); } SampleQueue(Allocator allocator); }
SampleQueue implements TrackOutput { public int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer) { return metadataQueue.advanceTo(timeUs, toKeyframe, allowTimeBeyondBuffer); } SampleQueue(Allocator allocator); void reset(); void reset(boolean resetUpstreamFormat); void sourceId(int sourceId); void splice(); int getWriteIndex(); void discardUpstreamSamples(int discardFromIndex); boolean hasNextSample(); int getFirstIndex(); int getReadIndex(); int peekSourceId(); Format getUpstreamFormat(); long getLargestQueuedTimestampUs(); boolean isLastSampleQueued(); long getFirstTimestampUs(); void rewind(); void discardTo(long timeUs, boolean toKeyframe, boolean stopAtReadPosition); void discardToRead(); void discardToEnd(); int advanceToEnd(); int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer); boolean setReadPosition(int sampleIndex); int read(
      FormatHolder formatHolder,
      DecoderInputBuffer buffer,
      boolean formatRequired,
      boolean loadingFinished,
      long decodeOnlyUntilUs); void setUpstreamFormatChangeListener(UpstreamFormatChangedListener listener); void setSampleOffsetUs(long sampleOffsetUs); @Override void format(Format format); @Override int sampleData(ExtractorInput input, int length, boolean allowEndOfInput); @Override void sampleData(ParsableByteArray buffer, int length); @Override void sampleMetadata(
      long timeUs,
      @C.BufferFlags int flags,
      int size,
      int offset,
      @Nullable CryptoData cryptoData); }
SampleQueue implements TrackOutput { public int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer) { return metadataQueue.advanceTo(timeUs, toKeyframe, allowTimeBeyondBuffer); } SampleQueue(Allocator allocator); void reset(); void reset(boolean resetUpstreamFormat); void sourceId(int sourceId); void splice(); int getWriteIndex(); void discardUpstreamSamples(int discardFromIndex); boolean hasNextSample(); int getFirstIndex(); int getReadIndex(); int peekSourceId(); Format getUpstreamFormat(); long getLargestQueuedTimestampUs(); boolean isLastSampleQueued(); long getFirstTimestampUs(); void rewind(); void discardTo(long timeUs, boolean toKeyframe, boolean stopAtReadPosition); void discardToRead(); void discardToEnd(); int advanceToEnd(); int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer); boolean setReadPosition(int sampleIndex); int read(
      FormatHolder formatHolder,
      DecoderInputBuffer buffer,
      boolean formatRequired,
      boolean loadingFinished,
      long decodeOnlyUntilUs); void setUpstreamFormatChangeListener(UpstreamFormatChangedListener listener); void setSampleOffsetUs(long sampleOffsetUs); @Override void format(Format format); @Override int sampleData(ExtractorInput input, int length, boolean allowEndOfInput); @Override void sampleData(ParsableByteArray buffer, int length); @Override void sampleMetadata(
      long timeUs,
      @C.BufferFlags int flags,
      int size,
      int offset,
      @Nullable CryptoData cryptoData); static final int ADVANCE_FAILED; }