/cts/tests/tests/media/extractor/src/android/media/extractor/cts/ |
D | MediaExtractorTest.java | 87 protected MediaExtractor mExtractor; field in MediaExtractorTest 91 mExtractor = new MediaExtractor(); in setUp() 96 mExtractor.release(); in tearDown() 119 mExtractor.setDataSource(ds); in setDataSource() 134 mExtractor.setDataSource(dataSource); in testExtractorFailsIfMediaDataSourceReturnsAnError() 166 0 < mExtractor.getTrackCount() && 3 > mExtractor.getTrackCount()); in testDolbyVisionMediaExtractorProfileDvheDtr() 168 MediaFormat trackFormat = mExtractor.getTrackFormat(0); in testDolbyVisionMediaExtractorProfileDvheDtr() 173 if (mExtractor.getTrackCount() == 2) { in testDolbyVisionMediaExtractorProfileDvheDtr() 176 trackFormat = mExtractor.getTrackFormat(1); in testDolbyVisionMediaExtractorProfileDvheDtr() 182 assertEquals("There must be 2 tracks", 2, mExtractor.getTrackCount()); in testDolbyVisionMediaExtractorProfileDvheDtr() [all …]
|
/cts/tests/tests/graphics/jni/ |
D | MediaTestHelpers.cpp | 44 if (mExtractor != nullptr) { in ~MediaHelper() 45 AMediaExtractor_delete(mExtractor); in ~MediaHelper() 46 mExtractor = nullptr; in ~MediaHelper() 77 ASSERT(nullptr == mExtractor); in createExtractor() 97 mExtractor = AMediaExtractor_new(); in createExtractor() 98 MEDIA_CALL(AMediaExtractor_setDataSourceFd(mExtractor, releaseFd.fd, in createExtractor() 105 ASSERT(mExtractor); in createMediaCodec() 109 int numTracks = AMediaExtractor_getTrackCount(mExtractor); in createMediaCodec() 113 format = AMediaExtractor_getTrackFormat(mExtractor, i); in createMediaCodec() 117 MEDIA_CALL(AMediaExtractor_selectTrack(mExtractor, i)); in createMediaCodec() [all …]
|
/cts/tests/media/common/src/android/mediav2/common/cts/ |
D | CodecDecoderBlockModelMultiAccessUnitDrmTestBase.java | 109 if (mExtractor.getSampleSize() < 0) { in enqueueInput() 116 int basePts = (int) mExtractor.getSampleTime(); in enqueueInput() 118 ((mExtractor.getSampleFlags() & MediaExtractor.SAMPLE_FLAG_ENCRYPTED) != 0); in enqueueInput() 120 int size = (int) mExtractor.getSampleSize(); in enqueueInput() 122 int deltaPts = (int) mExtractor.getSampleTime() - basePts; in enqueueInput() 124 + mExtractor.getSampleTime() + " should be greater than or equal " in enqueueInput() 130 mExtractor.readSampleData(mLinearInputBlock.getBuffer(), in enqueueInput() 140 int extractorFlags = mExtractor.getSampleFlags(); in enqueueInput() 141 long pts = mExtractor.getSampleTime(); in enqueueInput() 148 mExtractor.getSampleCryptoInfo(cryptoInfo); in enqueueInput() [all …]
|
D | CodecDecoderMultiAccessUnitDrmTestBase.java | 105 if (mExtractor.getSampleSize() < 0) { in enqueueInput() 113 int basePts = (int) mExtractor.getSampleTime(); in enqueueInput() 115 ((mExtractor.getSampleFlags() & MediaExtractor.SAMPLE_FLAG_ENCRYPTED) != 0); in enqueueInput() 118 int size = (int) mExtractor.getSampleSize(); in enqueueInput() 120 int deltaPts = (int) mExtractor.getSampleTime() - basePts; in enqueueInput() 122 + mExtractor.getSampleTime() + " should be greater than or equal " in enqueueInput() 128 mExtractor.readSampleData(inputBuffer, offset); in enqueueInput() 137 int extractorFlags = mExtractor.getSampleFlags(); in enqueueInput() 138 long pts = mExtractor.getSampleTime(); in enqueueInput() 146 mExtractor.getSampleCryptoInfo(cryptoInfo); in enqueueInput() [all …]
|
D | CodecDecoderTestBase.java | 63 protected MediaExtractor mExtractor; field in CodecDecoderTestBase 80 if (mExtractor != null) { in tearDownCodecDecoderTestBase() 81 mExtractor.release(); in tearDownCodecDecoderTestBase() 82 mExtractor = null; in tearDownCodecDecoderTestBase() 115 mExtractor = new MediaExtractor(); in setUpSource() 116 mExtractor.setDataSource(srcFile); in setUpSource() 117 for (int trackID = 0; trackID < mExtractor.getTrackCount(); trackID++) { in setUpSource() 118 MediaFormat format = mExtractor.getTrackFormat(trackID); in setUpSource() 127 mExtractor.selectTrack(trackID); in setUpSource() 204 if (mExtractor.getSampleSize() < 0) { in enqueueInput() [all …]
|
D | CodecDecoderBlockModelDrmTestBase.java | 104 int sampleSize = (int) mExtractor.getSampleSize(); in enqueueInput() 110 long pts = mExtractor.getSampleTime(); in enqueueInput() 111 mExtractor.readSampleData(mLinearInputBlock.getBuffer(), mLinearInputBlock.getOffset()); in enqueueInput() 112 int extractorFlags = mExtractor.getSampleFlags(); in enqueueInput() 116 mExtractor.getSampleCryptoInfo(cryptoInfo); in enqueueInput() 125 if (!mExtractor.advance() && mSignalEOSWithLastFrame) { in enqueueInput()
|
D | CodecDecoderMultiAccessUnitTestBase.java | 89 if (mExtractor.getSampleSize() < 0) { in enqueueInput() 97 int basePts = (int) mExtractor.getSampleTime(); in enqueueInput() 99 int size = (int) mExtractor.getSampleSize(); in enqueueInput() 101 int deltaPts = (int) mExtractor.getSampleTime() - basePts; in enqueueInput() 103 + mExtractor.getSampleTime() + " should be greater than or equal " in enqueueInput() 109 mExtractor.readSampleData(inputBuffer, offset); in enqueueInput() 118 int extractorFlags = mExtractor.getSampleFlags(); in enqueueInput() 119 long pts = mExtractor.getSampleTime(); in enqueueInput() 127 if (!mExtractor.advance() && mSignalEOSWithLastFrame) { in enqueueInput()
|
D | CodecEncoderSurfaceTestBase.java | 73 protected MediaExtractor mExtractor; field in CodecEncoderSurfaceTestBase 134 mExtractor.release(); in setUpCodecEncoderSurfaceTestBase() 187 if (mExtractor != null) { in tearDownCodecEncoderSurfaceTestBase() 188 mExtractor.release(); in tearDownCodecEncoderSurfaceTestBase() 189 mExtractor = null; in tearDownCodecEncoderSurfaceTestBase() 204 mExtractor = new MediaExtractor(); in setUpSource() 205 mExtractor.setDataSource(srcFile); in setUpSource() 206 for (int trackID = 0; trackID < mExtractor.getTrackCount(); trackID++) { in setUpSource() 207 MediaFormat format = mExtractor.getTrackFormat(trackID); in setUpSource() 210 mExtractor.selectTrack(trackID); in setUpSource() [all …]
|
D | CodecDecoderBlockModelMultiAccessUnitTestBase.java | 81 if (mExtractor.getSampleSize() < 0) { in enqueueInput() 87 int basePts = (int) mExtractor.getSampleTime(); in enqueueInput() 89 int size = (int) mExtractor.getSampleSize(); in enqueueInput() 91 int deltaPts = (int) mExtractor.getSampleTime() - basePts; in enqueueInput() 93 + mExtractor.getSampleTime() + " should be greater than or equal " in enqueueInput() 99 mExtractor.readSampleData(mLinearInputBlock.getBuffer(), in enqueueInput() 109 int extractorFlags = mExtractor.getSampleFlags(); in enqueueInput() 110 long pts = mExtractor.getSampleTime(); in enqueueInput() 118 if (!mExtractor.advance() && mSignalEOSWithLastFrame) { in enqueueInput()
|
D | CodecDecoderDrmTestBase.java | 203 if (mExtractor.getSampleSize() < 0) { in enqueueInput() 207 mExtractor.readSampleData(inputBuffer, 0); in enqueueInput() 208 int size = (int) mExtractor.getSampleSize(); in enqueueInput() 209 long pts = mExtractor.getSampleTime(); in enqueueInput() 210 int extractorFlags = mExtractor.getSampleFlags(); in enqueueInput() 214 mExtractor.getSampleCryptoInfo(cryptoInfo); in enqueueInput() 223 if (!mExtractor.advance() && mSignalEOSWithLastFrame) { in enqueueInput()
|
/cts/tests/mediapc/src/android/mediapc/cts/ |
D | AudioPlaybackLoad.java | 54 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in doDecodeAndPlayback() 62 mExtractor.release(); in doDecodeAndPlayback() 105 if (mExtractor.getSampleSize() < 0 || mLoadStatus.isLoadFinished()) { in enqueueInput() 109 int size = mExtractor.readSampleData(inputBuffer, 0); in enqueueInput() 110 long pts = mExtractor.getSampleTime(); in enqueueInput() 112 int extractorFlags = mExtractor.getSampleFlags(); in enqueueInput() 122 if (!mExtractor.advance()) { in enqueueInput() 123 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in enqueueInput()
|
D | CodecTranscoderTestBase.java | 52 MediaExtractor mExtractor; field in CodecTranscoderTestBase 93 mExtractor = new MediaExtractor(); in setUpSource() 94 mExtractor.setDataSource(mInpPrefix + srcFile); in setUpSource() 95 for (int trackID = 0; trackID < mExtractor.getTrackCount(); trackID++) { in setUpSource() 96 MediaFormat format = mExtractor.getTrackFormat(trackID); in setUpSource() 99 mExtractor.selectTrack(trackID); in setUpSource() 106 mExtractor.release(); in setUpSource() 155 if (mExtractor.getSampleSize() < 0) { in enqueueDecoderInput() 159 int size = mExtractor.readSampleData(inputBuffer, 0); in enqueueDecoderInput() 160 long pts = mExtractor.getSampleTime(); in enqueueDecoderInput() [all …]
|
/cts/tests/media/src/android/mediav2/cts/ |
D | CodecDecoderBlockModelMultiAccessUnitTest.java | 100 mExtractor.release(); in setUp() 153 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testSimpleDecode() 171 mExtractor.release(); in testSimpleDecode() 204 mExtractor.release(); in testFlush() 225 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 229 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 242 mExtractor.seekTo(pts, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 255 mExtractor.seekTo(pts, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 267 mExtractor.release(); in testFlush() 303 mExtractor.release(); in testReconfigure() [all …]
|
D | CodecDecoderSurfaceTest.java | 116 mExtractor.seekTo(pts, mode); in decodeAndSavePts() 122 mExtractor.release(); in decodeAndSavePts() 133 mExtractor.release(); in setUp() 245 mExtractor.seekTo(pts, mode); in testSimpleDecodeToSurface() 258 mExtractor.release(); in testSimpleDecodeToSurface() 294 mExtractor.seekTo(pts, mode); in testDetachAndReattachSurface() 356 mExtractor.release(); in testDetachAndReattachSurface() 388 mExtractor.release(); in testFlush() 409 mExtractor.seekTo(0, mode); in testFlush() 423 mExtractor.seekTo(0, mode); in testFlush() [all …]
|
D | CodecDecoderMultiAccessUnitTest.java | 178 mExtractor.release(); in setUp() 223 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testSimpleDecode() 241 mExtractor.release(); in testSimpleDecode() 276 mExtractor.release(); in testFlush() 304 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 318 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 331 mExtractor.seekTo(pts, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 344 mExtractor.seekTo(pts, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testFlush() 356 mExtractor.release(); in testFlush() 392 mExtractor.release(); in testReconfigure() [all …]
|
D | CodecDecoderTest.java | 136 int size = (int) mExtractor.getSampleSize(); in createSubFrames() 138 mExtractor.readSampleData(buffer, 0); in createSubFrames() 139 long pts = mExtractor.getSampleTime(); in createSubFrames() 140 int flags = mExtractor.getSampleFlags(); in createSubFrames() 342 mExtractor.release(); in setUp() 392 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_CLOSEST_SYNC); in testSimpleDecode() 418 mExtractor.release(); in testSimpleDecode() 473 mExtractor.release(); in testFlush() 493 mExtractor.seekTo(0, mode); in testFlush() 515 mExtractor.seekTo(0, mode); in testFlush() [all …]
|
/cts/tests/tests/media/decoder/src/android/media/decoder/cts/ |
D | HDRDecoderTest.java | 145 private MediaExtractor mExtractor = null; field in HDRDecoderTest 244 mExtractor = new MediaExtractor(); in setUp() 253 if (mExtractor != null) { in tearDown() 254 mExtractor.release(); in tearDown() 267 mExtractor.setDataSource(MEDIA_DIR + mInputFile); in testHdrMetadata() 271 for (int i = 0; i < mExtractor.getTrackCount(); i++) { in testHdrMetadata() 272 format = mExtractor.getTrackFormat(i); in testHdrMetadata() 286 mExtractor.selectTrack(trackIndex); in testHdrMetadata() 296 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_PREVIOUS_SYNC); in testHdrMetadata() 351 if (mExtractor.getSampleTrackIndex() == -1) { in testHdrMetadata() [all …]
|
D | DecoderConformanceTest.java | 85 private MediaExtractor mExtractor; field in DecoderConformanceTest 155 mExtractor.release(); in release() 161 mExtractor = null; in release() 177 mExtractor = new MediaExtractor(); in decodeTestVector() 178 mExtractor.setDataSource(testFd.getFileDescriptor(), testFd.getStartOffset(), in decodeTestVector() 180 mExtractor.selectTrack(0); in decodeTestVector() 185 if (!caps.isFormatSupported(mExtractor.getTrackFormat(0))) { in decodeTestVector() 198 if (MediaUtils.verifyDecoder(mDecoder, mExtractor, frameMD5Sums)) { in decodeTestVector()
|
/cts/tests/tests/media/drmframework/src/android/media/drmframework/cts/ |
D | MediaDrmExtractorTest.java | 47 private MediaExtractor mExtractor; field in MediaDrmExtractorTest 52 mExtractor = new MediaExtractor(); in setUp() 58 mExtractor.release(); in tearDown() 77 mExtractor.setDataSource(ds); in setDataSource() 85 DrmInitData drmInitData = mExtractor.getDrmInitData(); in testGetDrmInitData()
|
/cts/tests/media/jni/ |
D | NativeCodecDecoderTestCommon.cpp | 39 AMediaExtractor* mExtractor; member in CodecDecoderTest 76 mExtractor(nullptr), in CodecDecoderTest() 115 mExtractor = AMediaExtractor_new(); in setUpExtractor() 117 AMediaExtractor_setDataSourceFd(mExtractor, fileno(fp), 0, buf.st_size); in setUpExtractor() 125 for (size_t trackID = 0; trackID < AMediaExtractor_getTrackCount(mExtractor); in setUpExtractor() 127 AMediaFormat* currFormat = AMediaExtractor_getTrackFormat(mExtractor, trackID); in setUpExtractor() 131 AMediaExtractor_selectTrack(mExtractor, trackID); in setUpExtractor() 153 if (mExtractor) { in deleteExtractor() 154 AMediaExtractor_delete(mExtractor); in deleteExtractor() 155 mExtractor = nullptr; in deleteExtractor() [all …]
|
D | NativeCodecEncoderSurfaceTest.cpp | 34 AMediaExtractor* mExtractor; member in CodecEncoderSurfaceTest 95 mExtractor = nullptr; 152 mExtractor = AMediaExtractor_new(); in setUpExtractor() 154 AMediaExtractor_setDataSourceFd(mExtractor, fileno(fp), 0, buf.st_size); in setUpExtractor() 158 for (size_t trackID = 0; trackID < AMediaExtractor_getTrackCount(mExtractor); in setUpExtractor() 160 AMediaFormat* currFormat = AMediaExtractor_getTrackFormat(mExtractor, trackID); in setUpExtractor() 164 AMediaExtractor_selectTrack(mExtractor, trackID); in setUpExtractor() 178 if (mExtractor) { in deleteExtractor() 179 AMediaExtractor_delete(mExtractor); in deleteExtractor() 180 mExtractor = nullptr; in deleteExtractor() [all …]
|
/cts/tests/tests/media/misc/src/android/media/misc/cts/ |
D | MediaSyncTest.java | 601 private MediaExtractor mExtractor = null; field in MediaSyncTest.Decoder 645 mExtractor = MediaUtils.createMediaExtractorForMimeType( in setup() 650 mExtractor.getTrackFormat(mExtractor.getSampleTrackIndex()); in setup() 682 if (mExtractor != null) { in release() 683 mExtractor.release(); in release() 684 mExtractor = null; in release() 699 if (mExtractor == null) { in getAudioTrack() 705 mExtractor.getTrackFormat(mExtractor.getSampleTrackIndex()); in getAudioTrack() 751 if (mExtractor == null || mExtractor.getSampleTrackIndex() == -1 in onInputBufferAvailable() 757 int size = mExtractor.readSampleData(buffer, 0); in onInputBufferAvailable() [all …]
|
/cts/tests/tests/media/common/src/android/media/cts/ |
D | MediaCodecBlockModelHelper.java | 102 mExtractor = extractor; in setExtractor() 127 if (mExtractor == null) { in build() 131 mExtractor, mLastBufferTimestampUs, in build() 136 private MediaExtractor mExtractor = null; field in MediaCodecBlockModelHelper.ExtractorInputSlotListener.Builder 149 mExtractor = extractor; in ExtractorInputSlotListener() 159 if (mExtractor.getSampleTrackIndex() == -1 || mSignaledEos) { in onInputSlot() 162 long size = mExtractor.getSampleSize(); in onInputSlot() 193 long timestampUs = mExtractor.getSampleTime(); in onInputSlot() 194 int written = mExtractor.readSampleData(input.buffer, input.offset); in onInputSlot() 196 (mExtractor.getSampleFlags() & MediaExtractor.SAMPLE_FLAG_ENCRYPTED) != 0; in onInputSlot() [all …]
|
D | MediaCodecCryptoAsyncHelper.java | 69 mExtractor = extractor; in setExtractor() 83 if (mExtractor == null) { in build() 87 mExtractor, mLastBufferTimestampUs, in build() 90 private MediaExtractor mExtractor = null; field in MediaCodecCryptoAsyncHelper.ExtractorInputSlotListener.Builder 99 mExtractor = extractor; in ExtractorInputSlotListener() 109 final int sampleSize = mExtractor.readSampleData(inputBuffer, 0); in onInputSlot() 110 final long sampleTime = mExtractor.getSampleTime(); in onInputSlot() 111 mSignaledEos = mExtractor.getSampleTrackIndex() == -1 in onInputSlot() 114 boolean isSampleEncrypted = (mExtractor.getSampleFlags() & in onInputSlot() 125 mExtractor.getSampleCryptoInfo(info); in onInputSlot() [all …]
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/audio/ |
D | SoundPlayerObject.java | 66 private MediaExtractor mExtractor = null; field in SoundPlayerObject 156 mExtractor.readSampleData(encodedBuf, 0 /* offset */); in run() 163 presentationTimeUs = mExtractor.getSampleTime(); in run() 170 mExtractor.advance(); in run() 175 mExtractor.seekTo(0, MediaExtractor.SEEK_TO_PREVIOUS_SYNC); in run() 329 mExtractor = new MediaExtractor(); in setSoundWithResId() 330 mExtractor.setDataSource(mContext.getApplicationContext(), uri, null); in setSoundWithResId() 331 final int trackCount = mExtractor.getTrackCount(); in setSoundWithResId() 338 format = mExtractor.getTrackFormat(i); in setSoundWithResId() 341 mExtractor.selectTrack(i); in setSoundWithResId()
|