Home
last modified time | relevance | path

Searched refs:extractor (Results 1 – 16 of 16) sorted by relevance

/cts/tests/tests/media/src/android/media/cts/
DDecoderTestAacDrc.java408 MediaExtractor extractor; in decodeToMemory() local
413 extractor = new MediaExtractor(); in decodeToMemory()
414 extractor.setDataSource(testFd.getFileDescriptor(), testFd.getStartOffset(), in decodeToMemory()
418 assertEquals("wrong number of tracks", 1, extractor.getTrackCount()); in decodeToMemory()
419 MediaFormat format = extractor.getTrackFormat(0); in decodeToMemory()
447 extractor.selectTrack(0); in decodeToMemory()
465 extractor.readSampleData(dstBuf, 0 /* offset */); in decodeToMemory()
481 presentationTimeUs = extractor.getSampleTime(); in decodeToMemory()
491 extractor.advance(); in decodeToMemory()
DMediaMuxerTest.java267 MediaExtractor extractor = new MediaExtractor(); in cloneMediaUsingMuxer() local
268 extractor.setDataSource(srcFd.getFileDescriptor(), srcFd.getStartOffset(), in cloneMediaUsingMuxer()
271 int trackCount = extractor.getTrackCount(); in cloneMediaUsingMuxer()
281 extractor.selectTrack(i); in cloneMediaUsingMuxer()
282 MediaFormat format = extractor.getTrackFormat(i); in cloneMediaUsingMuxer()
324 bufferInfo.size = extractor.readSampleData(dstBuf, offset); in cloneMediaUsingMuxer()
333 bufferInfo.presentationTimeUs = extractor.getSampleTime(); in cloneMediaUsingMuxer()
334 bufferInfo.flags = extractor.getSampleFlags(); in cloneMediaUsingMuxer()
335 int trackIndex = extractor.getSampleTrackIndex(); in cloneMediaUsingMuxer()
339 extractor.advance(); in cloneMediaUsingMuxer()
DMediaCodecClearKeyPlayer.java278 private void setDataSource(MediaExtractor extractor, Uri uri, Map<String, String> headers) in setDataSource() argument
282 extractor.setDataSource(uri.toString(), headers); in setDataSource()
286 extractor.setDataSource(fd.getFileDescriptor(), fd.getStartOffset(), fd.getLength()); in setDataSource()
292 private void initCasAndDescrambler(MediaExtractor extractor) throws MediaCasException { in initCasAndDescrambler() argument
293 int trackCount = extractor.getTrackCount(); in initCasAndDescrambler()
295 android.media.MediaFormat format = extractor.getTrackFormat(trackId); in initCasAndDescrambler()
299 MediaExtractor.CasInfo casInfo = extractor.getCasInfo(trackId); in initCasAndDescrambler()
304 extractor.setMediaCas(mMediaCas); in initCasAndDescrambler()
DImageReaderDecoderTest.java256 MediaExtractor extractor = null; in videoDecode() local
262 extractor = new MediaExtractor(); in videoDecode()
266 extractor.setDataSource( in videoDecode()
282 extractor.setDataSource(tmpFile.getAbsolutePath()); in videoDecode()
285 mediaFormat = extractor.getTrackFormat(0); in videoDecode()
293 decoder, extractor, mediaFormat, in videoDecode()
307 if (extractor != null) { in videoDecode()
308 extractor.release(); in videoDecode()
465 MediaCodec decoder, MediaExtractor extractor, MediaFormat mediaFormat, in decodeFramesToImage() argument
484 extractor.selectTrack(0); in decodeFramesToImage()
[all …]
DExtractDecodeEditEncodeMuxTest.java585 MediaExtractor extractor; in createExtractor() local
588 extractor = new MediaExtractor(); in createExtractor()
589 extractor.setDataSource(srcFd.getFileDescriptor(), srcFd.getStartOffset(), in createExtractor()
591 return extractor; in createExtractor()
667 private int getAndSelectVideoTrackIndex(MediaExtractor extractor) { in getAndSelectVideoTrackIndex() argument
668 for (int index = 0; index < extractor.getTrackCount(); ++index) { in getAndSelectVideoTrackIndex()
671 + getMimeTypeFor(extractor.getTrackFormat(index))); in getAndSelectVideoTrackIndex()
673 if (isVideoFormat(extractor.getTrackFormat(index))) { in getAndSelectVideoTrackIndex()
674 extractor.selectTrack(index); in getAndSelectVideoTrackIndex()
681 private int getAndSelectAudioTrackIndex(MediaExtractor extractor) { in getAndSelectAudioTrackIndex() argument
[all …]
DDecoderTestXheAac.java802 MediaExtractor extractor;
807 extractor = new MediaExtractor();
808 extractor.setDataSource(testFd.getFileDescriptor(), testFd.getStartOffset(),
812 assertEquals("wrong number of tracks", 1, extractor.getTrackCount());
813 MediaFormat format = extractor.getTrackFormat(0);
846 extractor.selectTrack(0);
866 extractor.readSampleData(dstBuf, 0 /* offset */);
883 presentationTimeUs = extractor.getSampleTime();
894 extractor.advance();
DVideoDecoderPerfTest.java117 MediaExtractor extractor = new MediaExtractor(); in doDecode() local
118 extractor.setDataSource(testFd.getFileDescriptor(), testFd.getStartOffset(), in doDecode()
120 extractor.selectTrack(0); in doDecode()
121 int trackIndex = extractor.getSampleTrackIndex(); in doDecode()
122 MediaFormat format = extractor.getTrackFormat(trackIndex); in doDecode()
144 while ((sampleSize = extractor.readSampleData(tmpBuf, 0 /* offset */)) > 0) { in doDecode()
149 firstPTS = extractor.getSampleTime(); in doDecode()
156 (extractor.getSampleTime() - firstPTS) * frameRate / 1e6 - index; in doDecode()
161 extractor.advance(); in doDecode()
172 extractor.release(); in doDecode()
DMediaMetadataRetrieverTest.java639 MediaExtractor extractor = null; in testGetImage() local
714 extractor = new MediaExtractor(); in testGetImage()
715 extractor.setDataSource( in testGetImage()
717 MediaFormat format = extractor.getTrackFormat(0); in testGetImage()
733 if (extractor != null) { in testGetImage()
734 extractor.release(); in testGetImage()
DDecodeAccuracyTestBase.java151 private final MediaExtractor extractor; field in DecodeAccuracyTestBase.SimplePlayer
166 this.extractor = new MediaExtractor(); in SimplePlayer()
232 extractor.selectTrack(trackNum); in prepareExtractor()
233 return extractor.getTrackFormat(trackNum); in prepareExtractor()
312 final int sampleSize = extractor.readSampleData(inputBuffer, 0); in queueDecoderInputBuffer()
315 inputBufferIndex, 0, sampleSize, extractor.getSampleTime(), 0); in queueDecoderInputBuffer()
316 extractor.advance(); in queueDecoderInputBuffer()
369 extractor.setDataSource( in setExtractorDataSource()
467 if (extractor == null) { in extractorRelease()
471 extractor.release(); in extractorRelease()
[all …]
DCodecState.java59 MediaExtractor extractor, in CodecState() argument
67 mExtractor = extractor; in CodecState()
DAdaptivePlaybackTest.java1289 MediaExtractor extractor = new MediaExtractor();
1291 extractor.setDataSource(testFd.getFileDescriptor(), testFd.getStartOffset(),
1295 extractor.getTrackFormat(0), extractor.getTrackFormat(0), numFrames);
1296 extractor.selectTrack(0);
1310 int sampleSize = extractor.readSampleData(readBuf, 0 /* offset */);
1330 extractor.getSampleTime(),
1331 extractor.getSampleFlags(),
1333 extractor.advance();
1336 extractor.release();
DHeifWriterTest.java601 MediaExtractor extractor = new MediaExtractor(); in verifyResult() local
602 extractor.setDataSource(filename); in verifyResult()
603 MediaFormat format = extractor.getTrackFormat(0); in verifyResult()
612 extractor.release(); in verifyResult()
/cts/common/device-side/util/src/com/android/compatibility/common/util/
DMediaUtils.java616 MediaExtractor extractor = new MediaExtractor(); in getTrackFormatForResource() local
619 extractor.setDataSource(afd.getFileDescriptor(), afd.getStartOffset(), afd.getLength()); in getTrackFormatForResource()
623 return getTrackFormatForExtractor(extractor, mimeTypePrefix); in getTrackFormatForResource()
629 MediaExtractor extractor = getExtractorForPath(context, path); in getTrackFormatForPath() local
630 return getTrackFormatForExtractor(extractor, mimeTypePrefix); in getTrackFormatForPath()
634 MediaExtractor extractor, in getTrackFormatForExtractor() argument
638 for (trackIndex = 0; trackIndex < extractor.getTrackCount(); trackIndex++) { in getTrackFormatForExtractor()
639 MediaFormat trackMediaFormat = extractor.getTrackFormat(trackIndex); in getTrackFormatForExtractor()
645 extractor.release(); in getTrackFormatForExtractor()
656 MediaExtractor extractor = new MediaExtractor(); in createMediaExtractorForMimeType() local
[all …]
/cts/tests/tests/media/libmediandkjni/
Dnative-mediadrm-jni.cpp287 static void addTracks(const AMediaExtractor* extractor, in addTracks() argument
291 const_cast<AMediaExtractor*>(extractor)); in addTracks()
296 const_cast<AMediaExtractor*>(extractor), i); in addTracks()
310 const_cast<AMediaExtractor*>(extractor), i); in addTracks()
318 const_cast<AMediaExtractor*>(extractor), 0, in addTracks()
332 static void fillDecoder(AMediaCodec* codec, AMediaExtractor* extractor, in fillDecoder() argument
341 int sampleSize = AMediaExtractor_readSampleData(extractor, buf, bufsize); in fillDecoder()
347 *presentationTimeUs = AMediaExtractor_getSampleTime(extractor); in fillDecoder()
350 AMediaExtractor_getSampleCryptoInfo(extractor); in fillDecoder()
364 AMediaExtractor_advance(extractor); in fillDecoder()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/sensors/
DRVCVXCheckAnalyzer.java934 private MediaExtractor extractor=null; field in RVCVXCheckAnalyzer.VideoDecoderForOpenCV
1016 if (extractor!=null) { in teardown()
1017 extractor.release(); in teardown()
1018 extractor = null; in teardown()
1025 extractor = new MediaExtractor(); in setup()
1028 extractor.setDataSource(mVideoFile.getPath()); in setup()
1033 for (int i = 0; i < extractor.getTrackCount(); i++) { in setup()
1034 MediaFormat format = extractor.getTrackFormat(i); in setup()
1040 extractor.selectTrack(i); in setup()
1095 int sampleSize = extractor.readSampleData(buffer, 0); in run()
[all …]
/cts/tests/camera/src/android/hardware/camera2/cts/
DRecordingTest.java1656 MediaExtractor extractor = new MediaExtractor(); in validateRecording() local
1658 extractor.setDataSource(mOutMediaFileName); in validateRecording()
1661 int numTracks = extractor.getTrackCount(); in validateRecording()
1665 MediaFormat format = extractor.getTrackFormat(i); in validateRecording()
1673 extractor.selectTrack(i); in validateRecording()
1707 timestamps.add(extractor.getSampleTime()); in validateRecording()
1708 if (!extractor.advance()) { in validateRecording()
1737 extractor.release(); in validateRecording()