Lines Matching refs:positionUs
157 void seekTo(long positionUs);
167 boolean continueBuffering(long positionUs);
212 public final long positionUs;
226 * @param positionUs
229 public PositionHolder(long positionUs, long basePositionUs, int offset) {
230 this.positionUs = positionUs;
373 private static String getFileName(String id, long positionUs) {
374 return String.format(Locale.ENGLISH, "%s_%016x.chunk", id, positionUs);
381 * @param positionUs current position to write a sample in micro seconds.
389 public SampleChunk createNewWriteFileIfNeeded(String id, long positionUs, SamplePool samplePool,
398 mStartPositionMap.put(id, positionUs);
402 File file = new File(mStorageManager.getBufferDir(), getFileName(id, positionUs));
404 .createSampleChunk(samplePool, file, positionUs, mChunkCallback);
405 map.put(positionUs, new Pair(sampleChunk, 0));
408 map.put(positionUs, new Pair(currentChunk, currentOffset));
422 long startPositionUs = keyPositions.size() > 0 ? keyPositions.get(0).positionUs : 0;
436 mStorageManager.getBufferDir(), getFileName(trackId, position.positionUs),
437 position.positionUs, mChunkCallback, chunk);
440 map.put(position.positionUs, new Pair(chunk, position.offset));
448 * @param positionUs the position.
451 public Pair<SampleChunk, Integer> getReadFile(String id, long positionUs) {
457 SortedMap<Long, Pair<SampleChunk, Integer>> headMap = map.headMap(positionUs + 1);