Home
last modified time | relevance | path

Searched refs:track (Results 1 – 25 of 28) sorted by relevance

12

/cts/tests/tests/media/src/android/media/cts/
DAudioTrackLatencyTest.java83 AudioTrack track = new AudioTrack(TEST_STREAM_TYPE, TEST_SR, TEST_CONF, TEST_FORMAT, in testSetBufferSize() local
88 int bufferCapacity = track.getBufferCapacityInFrames(); in testSetBufferSize()
89 int initialBufferSize = track.getBufferSizeInFrames(); in testSetBufferSize()
95 int resultNegative = track.setBufferSizeInFrames(-1); in testSetBufferSize()
98 initialBufferSize, track.getBufferSizeInFrames()); in testSetBufferSize()
100 int resultZero = track.setBufferSizeInFrames(0); in testSetBufferSize()
105 resultZero, track.getBufferSizeInFrames()); in testSetBufferSize()
107 int resultMax = track.setBufferSizeInFrames(Integer.MAX_VALUE); in testSetBufferSize()
111 resultMax, track.getBufferSizeInFrames()); in testSetBufferSize()
113 int resultMiddle = track.setBufferSizeInFrames(bufferCapacity / 2); in testSetBufferSize()
[all …]
DAudioTrackTest.java104 AudioTrack track = null; in constructorTestMultiSampleRate() local
106 track = new AudioTrack(_inTest_streamType, testSampleRates[i], _inTest_config, in constructorTestMultiSampleRate()
114 if (track != null) { in constructorTestMultiSampleRate()
115 localRes = (track.getState() == _expected_stateForMode); in constructorTestMultiSampleRate()
116 track.release(); in constructorTestMultiSampleRate()
271 AudioTrack track = null; in testConstructorStreamType() local
276 track = new AudioTrack(STREAM_TYPES[i], TYPE_TEST_SR, TYPE_TEST_CONF, in testConstructorStreamType()
285 if (track != null) { in testConstructorStreamType()
286 if (track.getState() != AudioTrack.STATE_INITIALIZED) { in testConstructorStreamType()
293 track.release(); in testConstructorStreamType()
[all …]
DAudioTrackOffloadTest.java127 AudioTrack track = new AudioTrack.Builder() in getOffloadAudioTrack() local
134 assertNotNull("Couldn't create offloaded AudioTrack", track); in getOffloadAudioTrack()
136 track.getSampleRate()); in getOffloadAudioTrack()
138 track.getChannelConfiguration()); in getOffloadAudioTrack()
139 return track; in getOffloadAudioTrack()
147 AudioTrack track = null; in testAudioTrackOffload() local
152 track = getOffloadAudioTrack(audioRes, bitRateInkbps, audioFormat); in testAudioTrackOffload()
153 if (track == null) { in testAudioTrackOffload()
158 track.registerStreamEventCallback(mExec, null); in testAudioTrackOffload()
162 track.registerStreamEventCallback(mExec, mCallback); in testAudioTrackOffload()
[all …]
DAudioTrack_ListenerTest.java97 final AudioTrack track; in doTest() local
101 track = new AudioTrack(TEST_STREAM_TYPE, TEST_SR, TEST_CONF, in doTest()
115 track = makeSomething.make(); in doTest()
119 listener = new MockOnPlaybackPositionUpdateListener(track, mHandler); in doTest()
121 listener = new MockOnPlaybackPositionUpdateListener(track); in doTest()
132 assertEquals(0, track.getNotificationMarkerPosition()); in doTest()
134 track.setNotificationMarkerPosition(mMarkerPosition)); in doTest()
135 assertEquals(mMarkerPosition, track.getNotificationMarkerPosition()); in doTest()
143 assertEquals(0, track.getPositionNotificationPeriod()); in doTest()
145 track.setPositionNotificationPeriod(updatePeriodInFrames)); in doTest()
[all …]
DAudioTrackNative.java151 private static native void nativeDestroyTrack(long track); in nativeDestroyTrack() argument
153 long track, int numChannels, int channelMask, in nativeOpen() argument
155 private static native void nativeClose(long track); in nativeClose() argument
156 private static native int nativeStart(long track); in nativeStart() argument
157 private static native int nativeStop(long track); in nativeStop() argument
158 private static native int nativePause(long track); in nativePause() argument
159 private static native int nativeFlush(long track); in nativeFlush() argument
160 private static native int nativeGetPositionInMsec(long track, @NonNull long[] position); in nativeGetPositionInMsec() argument
161 private static native int nativeGetBuffersPending(long track); in nativeGetBuffersPending() argument
162 private static native int nativeWriteByteArray(long track, @NonNull byte[] byteArray, in nativeWriteByteArray() argument
[all …]
DAudioNativeTest.java109 AudioTrackNative track = new AudioTrackNative(); in testPlayStreamData() local
111 track.open(TEST_CHANNELS, TEST_SR, TEST_FLOAT, 1 /* numBuffers */)); in testPlayStreamData()
112 assertTrue(TEST_NAME, track.start()); in testPlayStreamData()
122 track.write(data, 0 /* offset */, sourceSamples, in testPlayStreamData()
129 track.write(data, 0 /* offset */, sourceSamples, in testPlayStreamData()
136 long position = track.getPositionInMsec(); in testPlayStreamData()
143 if (track.getBuffersPending() == 0) { in testPlayStreamData()
148 track.stop(); in testPlayStreamData()
150 track.close(); in testPlayStreamData()
221 AudioTrackNative track = new AudioTrackNative(); in testOutputChannelMasks() local
[all …]
DMediaSyncEventTest.java51 AudioTrack track = null; in testSynchronizedRecord() local
65 track = new AudioTrack.Builder() in testSynchronizedRecord()
75 track.write(vab, 0 /* offsetInBytes */, vab.length, in testSynchronizedRecord()
77 final int trackSessionId = track.getAudioSessionId(); in testSynchronizedRecord()
113 track.play(); in testSynchronizedRecord()
177 if (track != null) { in testSynchronizedRecord()
178 track.release(); in testSynchronizedRecord()
179 track = null; in testSynchronizedRecord()
DAudioEffectTest.java248 AudioTrack track = null; in test1_7AuxiliaryOnAudioTrack() local
251 track = new AudioTrack( in test1_7AuxiliaryOnAudioTrack()
260 assertNotNull("could not create AudioTrack", track); in test1_7AuxiliaryOnAudioTrack()
262 int status = track.attachAuxEffect(mEffect.getId()); in test1_7AuxiliaryOnAudioTrack()
266 status = track.setAuxEffectSendLevel(1.0f); in test1_7AuxiliaryOnAudioTrack()
275 if (track != null) { in test1_7AuxiliaryOnAudioTrack()
276 track.release(); in test1_7AuxiliaryOnAudioTrack()
DAudioTrackSurroundTest.java215 AudioTrack track = new AudioTrack(AudioManager.STREAM_MUSIC, in createAudioTrack() local
219 return track; in createAudioTrack()
233 void addTimestamp(AudioTrack track) { in addTimestamp() argument
235 boolean gotTimestamp = track.getTimestamp(timestamp); in addTimestamp()
DJetPlayerTest.java204 public void onJetEvent(JetPlayer player, short segment, byte track, byte channel, in onJetEvent() argument
/cts/tests/tests/media/libaudiojni/
Daudio-track-native.cpp349 AudioTrackNative *track = (AudioTrackNative *)pContext; in BufferQueueCallback() local
350 track->bufferQueueCallback(queueItf); in BufferQueueCallback()
382 AudioTrackNative track; in Java_android_media_cts_AudioTrackNative_nativeTest() local
389 res = track.open(numChannels, channelMask, sampleRate, useFloat, numBuffers); in Java_android_media_cts_AudioTrackNative_nativeTest()
393 track.write((char *)buffer + i * (framesPerBuffer * frameSize), in Java_android_media_cts_AudioTrackNative_nativeTest()
397 track.logBufferState(); in Java_android_media_cts_AudioTrackNative_nativeTest()
398 res = track.start(); in Java_android_media_cts_AudioTrackNative_nativeTest()
402 while ((buffers = track.getBuffersPending()) > 0) { in Java_android_media_cts_AudioTrackNative_nativeTest()
406 res = track.stop(); in Java_android_media_cts_AudioTrackNative_nativeTest()
409 track.close(); in Java_android_media_cts_AudioTrackNative_nativeTest()
[all …]
DAndroid.bp27 "audio-track-native.cpp",
/cts/tests/tests/tv/src/android/media/tv/cts/
DTvViewTest.java287 private void selectTrackAndVerify(final int type, final TvTrackInfo track, in selectTrackAndVerify() argument
292 mTvView.selectTrack(type, track == null ? null : track.getId()); in selectTrackAndVerify()
294 if ((track == null && selectedTrackId != null) in selectTrackAndVerify()
295 || (track != null && !track.getId().equals(selectedTrackId))) { in selectTrackAndVerify()
307 assertEquals(selectedTrackId, track == null ? null : track.getId()); in selectTrackAndVerify()
317 assertEquals(track.getType(), selectedTrack.getType()); in selectTrackAndVerify()
318 assertEquals(track.getExtra(), selectedTrack.getExtra()); in selectTrackAndVerify()
319 switch (track.getType()) { in selectTrackAndVerify()
321 assertEquals(track.getVideoHeight(), selectedTrack.getVideoHeight()); in selectTrackAndVerify()
322 assertEquals(track.getVideoWidth(), selectedTrack.getVideoWidth()); in selectTrackAndVerify()
[all …]
DStubTunerTvInputService.java146 for (TvTrackInfo track : mTrackList) { in onTune()
147 if (track.getType() == TvTrackInfo.TYPE_VIDEO) { in onTune()
148 notifyTrackSelected(TvTrackInfo.TYPE_VIDEO, track.getId()); in onTune()
152 for (TvTrackInfo track : mTrackList) { in onTune()
153 if (track.getType() == TvTrackInfo.TYPE_AUDIO) { in onTune()
154 notifyTrackSelected(TvTrackInfo.TYPE_AUDIO, track.getId()); in onTune()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/audio/
DSoundRecorderObject.java147 public void markerReached(AudioRecord track) {} in markerReached() argument
158 public void onMarkerReached(AudioRecord track) { in onMarkerReached() argument
159 markerReached(track); in onMarkerReached()
DSoundPlayerObject.java617 public void periodicNotification(AudioTrack track) { in periodicNotification() argument
620 public void markerReached(AudioTrack track) { in markerReached() argument
624 public void onMarkerReached(AudioTrack track) { in onMarkerReached() argument
625 markerReached(track); in onMarkerReached()
629 public void onPeriodicNotification(AudioTrack track) { in onPeriodicNotification() argument
630 periodicNotification(track); in onPeriodicNotification()
DAudioAEC.java218 public void periodicNotification(AudioTrack track) { in onCreate()
DAudioFrequencyLineActivity.java659 public void onMarkerReached(AudioRecord track) { in onMarkerReached() argument
DAudioFrequencySpeakerActivity.java687 public void onMarkerReached(AudioRecord track) { in onMarkerReached() argument
/cts/tests/tests/widget/src/android/widget/cts/
DSwitchTest.java340 GradientDrawable track = (GradientDrawable) mSwitch.getTrackDrawable(); in testSetTrackIcon() local
341 assertEquals(GradientDrawable.RECTANGLE, track.getShape()); in testSetTrackIcon()
342 assertEquals(ColorStateList.valueOf(Color.BLUE), track.getColor()); in testSetTrackIcon()
360 GradientDrawable track = (GradientDrawable) mSwitch.getTrackDrawable(); in testSetTrackIconAsync() local
361 assertEquals(GradientDrawable.RECTANGLE, track.getShape()); in testSetTrackIconAsync()
362 assertEquals(ColorStateList.valueOf(Color.BLUE), track.getColor()); in testSetTrackIconAsync()
379 GradientDrawable track = (GradientDrawable) mSwitch.getTrackDrawable(); in testSetTrackResourceAsync() local
380 assertEquals(GradientDrawable.RECTANGLE, track.getShape()); in testSetTrackResourceAsync()
381 assertEquals(ColorStateList.valueOf(Color.BLUE), track.getColor()); in testSetTrackResourceAsync()
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/
DMediaUtils.java426 public static boolean hasCodecForTrack(MediaExtractor ex, int track) { in hasCodecForTrack() argument
428 if (track < 0 || track >= count) { in hasCodecForTrack()
429 throw new IndexOutOfBoundsException(track + " not in [0.." + (count - 1) + "]"); in hasCodecForTrack()
431 return canDecode(ex.getTrackFormat(track)); in hasCodecForTrack()
470 private static boolean hasCodecsForResourceCombo(final String resource, int track, in hasCodecsForResourceCombo() argument
480 } else if (track == ALL_AV_TRACKS) { in hasCodecsForResourceCombo()
483 return hasCodecForTrack(ex, track); in hasCodecsForResourceCombo()
500 Context context, int resourceId, int track, String mimePrefix) { in hasCodecsForResourceCombo() argument
510 } else if (track == ALL_AV_TRACKS) { in hasCodecsForResourceCombo()
513 return hasCodecForTrack(ex, track); in hasCodecsForResourceCombo()
[all …]
/cts/tests/framework/base/windowmanager/util/src/android/server/wm/
DObjectTracker.java82 public void track(@NonNull Consumable consumable) { in track() method in ObjectTracker
/cts/suite/audio_quality/client/src/com/android/cts/audiotest/
DAudioProtocol.java113 public void onMarkerReached(AudioTrack track) { in onMarkerReached() argument
115 track.stop(); in onMarkerReached()
116 track.flush(); in onMarkerReached()
117 track.release(); in onMarkerReached()
/cts/tests/tests/mediaparser/src/android/media/mediaparser/cts/
DMockMediaParserOutputConsumer.java107 mTrackOutputs.add(mFakeExtractorOutput.track(trackIndex, C.TRACK_TYPE_UNKNOWN)); in onTrackDataFound()
116 .track(trackIndex, C.TRACK_TYPE_UNKNOWN) in onSampleDataFound()
/cts/tests/framework/base/windowmanager/src/android/server/wm/lifecycle/
DActivityLifecycleClientTestBase.java153 mObjectTracker.track(this); in Launcher()

12