• Home
  • History
  • Annotate
  • only in /frameworks/wilhelm/tests/
History log of /frameworks/wilhelm/tests/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
fdef5de17abc6c30b293861ca276259a7dd93837 05-Jun-2014 Glenn Kasten <gkasten@google.com> Squashed commit of the following:

commit 4f3540e6953ad28cbb743cfe9f480bc4b3e979a9
Author: Glenn Kasten <gkasten@google.com>
Date: Wed May 14 07:30:02 2014 -0700

Updates to slesTest_feedback

Configure for 48 kHz, 240 frames per buffer
Use Pipe
This smaller pipe still works with -t1 -r1

Change-Id: Ib1c40905017f3ebfedb70df145ef3018538ea0c2

commit b4b546279693f23733e8b803fdd1eb559b8db04b
Author: Andy Hung <hunga@google.com>
Date: Fri May 23 16:40:16 2014 -0700

Add float playback capability to OpenSL ES

Add SLAndroidDataFormat_PCM_EX to match OpenSLES 1.1 header file,
together with related SL_ANDROID_PCM_REPRESENTATION_* constants.
Use slesTest_playbq as the test application.

Change-Id: I04bcd170f5c517051a799bacf8f52da5f1353ad6

commit f0642023f9660c2fdec9c48cef76e35570abe177
Author: Glenn Kasten <gkasten@google.com>
Date: Tue May 27 17:17:26 2014 -0700

Fix regression in AudioRecorder

Interfaces were out of order

Change-Id: I027dc9d8ed93514d93a5b05063a8711b9841aaf4

commit 8c83595b784559f146e08b2d5500215e76cf5ba9
Author: Andy Hung <hunga@google.com>
Date: Fri May 23 16:24:25 2014 -0700

Add 24 bit and 32 bit playback capability to OpenSL ES

slesTest_playbq is the test application.

Change-Id: Iaa453471d2e9ff4e6b11ac5c68690993179fea2b

Change-Id: I07515d0d3cae65c0e0d9a600527a90d64c5241d7
xamples/Android.mk
xamples/slesTestFeedback.cpp
andbox/playbq.c
7d8a31e340ae4dea8913ce60e046fad72bff9051 15-May-2014 Glenn Kasten <gkasten@google.com> Merge "Make slesTest_object work again"
ecccdd9e99a753d3a9e105ec4b9b02e7afe60ebe 15-May-2014 Glenn Kasten <gkasten@google.com> Document how to use sox with slesTest_recBuffQueue

Change-Id: I6bb80e9a3785cb57e9b3d0c1d8787e6d208b970e
xamples/slesTestRecBuffQueue.cpp
e047d27324083628b51bad0661a184f6cb96c56d 15-May-2014 Glenn Kasten <gkasten@google.com> Make slesTest_object work again

Change-Id: I92f125c700002fb0f705eade5ccc63445a878991
andbox/object.c
e1af2db0b4c3406bf6190615116947cdc27adea5 12-May-2014 Glenn Kasten <gkasten@google.com> Change default buffer size in frames for feedback

Change-Id: Ifa3456ac1a7e8623f3fef7021a7a7907f21489ff
xamples/slesTestFeedback.cpp
f1a8dbbda361ce5e4ce96cc1586964d9e18a2a2f 20-Mar-2014 Glenn Kasten <gkasten@android.com> am a62c3572: Merge "Revert "For checkbuild, disable all Wilhelm tests in 64-bit""

* commit 'a62c3572e60ae0446632de15418a65089cccf551':
Revert "For checkbuild, disable all Wilhelm tests in 64-bit"
0266296b3a85561194cff36829dab4b02153d8f6 20-Mar-2014 Glenn Kasten <gkasten@android.com> Revert "For checkbuild, disable all Wilhelm tests in 64-bit"

This reverts commit 4a762c2b589568b7b4c1af4fe313d622a7b339c6.
ndroid.mk
utomated/Android.mk
xamples/Android.mk
istening/Android.mk
imeUri/Android.mk
ative-media/Android.mk
ative-media/jni/Android.mk
andbox/Android.mk
1a90a1b28e1c842178c0dfbf6d6c90510d7390be 18-Mar-2014 Glenn Kasten <gkasten@android.com> am 297ca210: Merge "For checkbuild, disable all Wilhelm tests in 64-bit"

* commit '297ca210a54028452edc067e89956d8605d607b2':
For checkbuild, disable all Wilhelm tests in 64-bit
4a762c2b589568b7b4c1af4fe313d622a7b339c6 18-Mar-2014 Glenn Kasten <gkasten@android.com> For checkbuild, disable all Wilhelm tests in 64-bit

These depend on libOpenSLES.so or libOpenMAXAL.so,
which in turn depend on libstagefright.so, which is not 64-bit ready yet.

Change-Id: I7b29feb4fdac08edad6b839cf3f8161940fb1555
ndroid.mk
utomated/Android.mk
xamples/Android.mk
istening/Android.mk
imeUri/Android.mk
ative-media/Android.mk
ative-media/jni/Android.mk
andbox/Android.mk
1dafaf975636480dd42c57ef2c3b806739325ef8 08-Mar-2014 Glenn Kasten <gkasten@google.com> Fix checkbuild

Change-Id: Ic05acbd53a8f0a2ded837c8999a5de51ccd6bb8a
andbox/playbq.c
cb66e5e0fa527d958f97fe835c35dbbf82810fb9 01-Mar-2014 Ying Wang <wangying@google.com> am 32e865f4: Merge "Fix indirect misuse of ."

* commit '32e865f451d2fbb97e5bb27300f8e4da803fb790':
Fix indirect misuse of $(my-dir).
c7afcd0a8aa1c1710ba37688f1843f31ff377af3 01-Mar-2014 Ying Wang <wangying@google.com> Fix indirect misuse of $(my-dir).

Change-Id: I4cf9a5bf66d7894995be2b8b045ad80f56190b52
utomated/Android.mk
a6babec83b52b08e9d2807afe2be05607fd7a133 14-Feb-2014 Narayan Kamath <narayan@google.com> am 298eac15: Merge "AArch64: Minor changes related to 64-bit platform"

* commit '298eac1548462c05e9c417abb0e401d805700e82':
AArch64: Minor changes related to 64-bit platform
01f8573bc2a850536b02855d483dfe130c050a2f 12-Mar-2013 Ashok Bhat <ashok.bhat@arm.com> AArch64: Minor changes related to 64-bit platform

Changes include
[x] Use %zu for size_t
[x] Use PRId64 to print 64-bit integer value
[x] Use uintptr_t for integer variable used to store address.

Change-Id: I69926cce76b0d645f1abccd584444197a5e40318
Signed-off-by: Marcus Oakland <marcus.oakland@arm.com>
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
xamples/slesTestDecodeAac.cpp
imeUri/slesTestPlayStreamType.cpp
ative-media/jni/native-media-jni.c
andbox/intbufq.c
andbox/xaplay.c
64ae6e1913b9330ad7ebd1c3ae62cdcf2d45b758 16-Jan-2014 Jean-Michel Trivi <jmtrivi@google.com> Fix erroneous comment in OpenSL ES recording sample

Fix copy paste error in recording sample code.

Change-Id: Ia20a2bb0fcba90d53171c644c6ba2f4770c5093b
xamples/slesTestRecBuffQueue.cpp
8191551b15a58cf988ee3b21ebbb5a27c94e9653 06-Aug-2013 Glenn Kasten <gkasten@google.com> Merge "Fix build warnings"
3eaa329775fc522d8ea4acd4edc379eabf9ac332 12-Nov-2012 Glenn Kasten <gkasten@google.com> Fix build warnings

narrowing conversion of '-1' from 'int' to 'SLuint32 {aka unsigned int}' inside { } is ill-formed in C++11 [-Wnarrowing]
converting to non-pointer type 'pthread_t {aka long int}' from NULL [-Wconversion-null]
warning: 'currentRate' may be used uninitialized in this function [-Wmaybe-uninitialized]

Change-Id: I066260cc216ff9f15c787f65e3d3efbda8f8ef35
andbox/playbq.c
5e6f449b9126cfd53743c83d55c52f1f50aa450d 02-Aug-2013 Glenn Kasten <gkasten@google.com> liblog is needed now

Change-Id: Ie17be7ed6d1d8c67c8e5f5515e16dac9e2cae04a
andbox/Android.mk
3f73d418d3738c05fbb872644edc90765d1de00a 10-Apr-2013 Ying Wang <wangying@google.com> Add liblog

Bug: 8580410
Change-Id: Ie9f89a3b26d0070c73d061c2c2566dd703d7a137
ative-media/jni/Android.mk
andbox/Android.mk
ad6c970f500cf99dd1eb23b9f5b2360948db90e7 31-Oct-2012 Glenn Kasten <gkasten@google.com> Use libnbaio to avoid file I/O in audio callback

Bug: 7142834
Change-Id: I4f78f029ac6bfe27bea4dfe1f00812a2bdf8785d
andbox/Android.mk
andbox/playbq.c
e21f91df7afb1175ddb5b0045ebb0d5338df2535 18-Dec-2012 Andy McFadden <fadden@android.com> Rename ISurfaceTexture and SurfaceTexture

The C++ class names don't match what the classes do, so rename
ISurfaceTexture to IGraphicBufferProducer, and SurfaceTexture to
GLConsumer.

Bug 7736700

Change-Id: I54f19904e325518a3af8fe23c018d3c0bb6bd807
ative-media/jni/native-media-jni.c
456d8452cb6ceeda3b2134b9077f19ca0f4a1890 12-Nov-2012 Glenn Kasten <gkasten@google.com> static libsndfile requires dynamic libaudioutils

Change-Id: I6a8f28503fd2dcde7d195879bc23d185ae93f617
andbox/Android.mk
85b1ba5dfb402b1acbfa516776d946769ccb8ffd 01-Nov-2012 Glenn Kasten <gkasten@google.com> Line length 100

Change-Id: I9a1a2e24e3b66e08ec33d0d8cf5ab2e14b559d4a
imeUri/slesTestSlowDownUri.cpp
56847632bc2fd39a8fff68fa1e883f06310c876a 31-Oct-2012 Glenn Kasten <gkasten@google.com> Use tinysndfile

Change-Id: I6f94fed488662a93e778ea64b8e4861dce528f26
andbox/Android.mk
andbox/playbq.c
f8d147df8f6dba1bb5bb0ea4c09795ee827569ca 06-Apr-2012 Glenn Kasten <gkasten@google.com> playbq's use of playback rate interface optional

The playback rate interface is not supported for fast tracks,
so to enable testing of fast tracks using playbq,
only request the playback rate interface if it is actually needed.

Change-Id: I15e512e1e853dccc752ad59c727bb0ed2d651162
andbox/playbq.c
799d44ecb3f5591c19d186b9675f363699116c2d 25-Aug-2012 Jeff Brown <jeffbrown@google.com> Use new surface flinger API.

Change-Id: Iecd955817d2800e2d1da3187da8958aa261ce435
andbox/nativewindow.cpp
b18944c03c48d91fada0ae7bb364d056840f6dba 19-Mar-2012 Glenn Kasten <gkasten@google.com> Merge "Prepare to move system/media"
ee3ad477a71ba690f0b5721056a6514bf2f76bd8 16-Mar-2012 Glenn Kasten <gkasten@google.com> Merge "Fix indentation and redundant whitespace"
5321b3665e1a538cdcf894dea99d15c10b18ccf8 14-Mar-2012 Glenn Kasten <gkasten@google.com> Prepare to move system/media

Change-Id: Iac6dcfb72753e53e9a42b5feeaa2d6523f2395a4
ndroid.mk
utomated/Android.mk
xamples/Android.mk
istening/Android.mk
imeUri/Android.mk
ative-media/jni/Android.mk
andbox/Android.mk
andbox/streamSource/Android.mk
01e4a8ff63523bba5c8f919a72e0adb66daf4b98 26-Feb-2012 Mathias Agopian <mathias@google.com> cleanup includes

Change-Id: Ia98b76b2e0c49ee257e1f31c61c2d6f72a9fe894
andbox/nativewindow.cpp
bbc2464b724471ba38669341cc992c21db1b9b08 09-Jan-2012 Glenn Kasten <gkasten@google.com> Merge "Minor improvements to test app"
b47c7beddecd38ae565d84b72da526843bfdd43e 08-Jan-2012 Steve Block <steveblock@google.com> Rename (IF_)LOGE(_IF) to (IF_)ALOGE(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/#/c/157220

Bug: 5449033
Change-Id: I584e6f6a3c52308b7a5a5c9980ca429c831f4320
ative-media/jni/native-media-jni.c
701cf2a089c87ec5b8e5a953f637b250aee4a58a 05-Jan-2012 Glenn Kasten <gkasten@google.com> Minor improvements to test app

Continuous pitch bend.
Expand the help text for options.
Improve error recovery for invalid options.
Fix typo in error message.

Change-Id: I7724372a510cb3733d31feeaffb22fbfa13b328c
andbox/playbq.c
7f7fde185e2739a88ba1847fa583a7dec459ea43 04-Jan-2012 Steve Block <steveblock@google.com> Rename (IF_)LOGI(_IF) to (IF_)ALOGI(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/156801

Bug: 5449033
Change-Id: Id162f100e77d64cce4a12cd62b330e7cb847d816
ative-media/jni/native-media-jni.c
22ced1dc023dc000118e3a26517b14e9babd7c5a 12-Aug-2011 Glenn Kasten <gkasten@google.com> Fix indentation and redundant whitespace

Change-Id: I8e0193ad5aa9405f64203bf7814d8a9e434c5dde
ative-media/jni/native-media-jni.c
dcc6a97a16b6536f455f29a03c02295c39583dcd 29-Nov-2011 Glenn Kasten <gkasten@google.com> Bug 5550980 test xaVideoDecoderCapabilities

Print video codec profiles and levels as strings in addition to numbers.

Change-Id: I88d84121fe15c1cc1ba84067ec6b6bdb3405d704
xamples/xaVideoDecoderCapabilities.cpp
09bc46f629d43102e8fe41d9a552e73d445b0f01 16-Nov-2011 Glenn Kasten <gkasten@google.com> Merge "Remove private ANativeWindow_fromSurfaceTexture"
e5ce0bdb3aca8976465b9e2e55b1267e48aef44d 28-Sep-2011 Glenn Kasten <gkasten@google.com> AAC decode test additions

Add prefetch status check: believe it or not, this can actually fail if
the first AAC frame is invalid (I found this out the hard way).

Use SL_PLAYEVENT_HEADATEND event to detect end of decode.
No more sleeps!

Fix typos in checking the per-buffer context.

Display message when corrupt AAC frame, and display frame sizes.

Add option to enable raw output, on by default.

Use same naming conventions as other tests: slesTest_decodeAac.

Clean up the comments.

Move metadata key queries (but not values!) to before prefetch started.

Change-Id: I69e89f3c67c5310e45117dffd08c55bed9f5914a
xamples/Android.mk
xamples/slesTestDecodeAac.cpp
738e761c42f146b655fa01707b82be25c2200d63 12-Nov-2011 Glenn Kasten <gkasten@google.com> Remove private ANativeWindow_fromSurfaceTexture

ANativeWindow_fromSurfaceTexture was a private API that is now deprecated
and is being removed in a separate CL. This change replaces all the
known uses by the preferred API ANativeWindow_fromSurface.

Note: a Surface can be derived from a SurfaceTexture by:

SurfaceTexture st = ...;
Surface s = new Surface(st);
// use s
s.release();

Change-Id: Ia55c023fc1487177ec76ae406ed77193083c9eac
ative-media/jni/native-media-jni.c
ative-media/src/com/example/nativemedia/NativeMedia.java
047916c6e882878075e42a7a5986a6bc1b0cf489 07-Nov-2011 Glenn Kasten <gkasten@google.com> Merge "CT and spec errata for MuteSolo::GetNumChannels"
6cb52acc3e6fc1ef23b26d0bf9827f168bb8b71e 07-Nov-2011 Glenn Kasten <gkasten@google.com> Merge "Fix line length"
68686bd0cb31f99f07ebc176176f8b51adf8d1d5 21-Jul-2011 Glenn Kasten <gkasten@google.com> Fix line length

And add explanation for -p# option of slesTest_recBuffQueue

Change-Id: I32a06caf633c6796e263a1beeec93513cd775096
xamples/slesTestEqFdPath.cpp
xamples/slesTestRecBuffQueue.cpp
xamples/xaVideoDecoderCapabilities.cpp
ative-media/src/com/example/nativemedia/NativeMedia.java
andbox/streamSource/slesTestPlayStream.cpp
04a960c641a5885784f84382c0dabd6d34f70226 07-Nov-2011 Glenn Kasten <gkasten@google.com> Merge "xaplay test additions"
c9a59d2a184ac461f46c3d878c6fc2574f1805f0 28-Sep-2011 Glenn Kasten <gkasten@google.com> CT and spec errata for MuteSolo::GetNumChannels

The question of what to return when channel count is unknown was dicussed
by Khronos working group. They decided to return zero channel count
and success if unknown. Both the spec errata and CT have been updated for this.

Change-Id: I820291271f83bad2142046372d9b22e4d05faf07
istening/slesTest_playMuteSolo.cpp
b17edb96ba759cd1197bf13cd13e279ee144da60 30-Aug-2011 Glenn Kasten <gkasten@google.com> xaplay test additions

Allow playing a subset of input file.
Add format change test.
Call gComposerClient->dispose before exit.
Remove dead code related to re-initializing the engine.
Add position, seek, loop tests.
Force callback failures with -c option.
Don't enqueue EOS more than once.
Add STOPPED at end of xaplay.
Add temporary set play state to paused.
Added discontinuity test.
More stream information queries and printfs.
Shorter marker to make it easier to hit when looping.
Add explanation of command line options.

Change-Id: I5b425a52f9afc2c8f9083badb6de0773f711c6d9
andbox/nativewindow.cpp
andbox/nativewindow.h
andbox/xaplay.c
de7c7da8460de9fb1e8739978f25e1463e2e1666 26-Oct-2011 Steve Block <steveblock@google.com> Rename LOGV(_IF) to ALOGV(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/#/c/143865

Bug: 5449033
Change-Id: I4c0e3dc9da0a0cdf9aef8be4fae7b24da876dc17
utomated/BufferQueue_test.cpp
ative-media/jni/native-media-jni.c
b96e08a32c49c8caeae52e35f7dedfd6e85d2dd8 18-Oct-2011 Jamie Gennis <jgennis@google.com> am 543c7826: wilhelm: fix native-media SurfaceTexture test

* commit '543c7826963411caef0c8052bb4866874def7cd7':
wilhelm: fix native-media SurfaceTexture test
c9034c3a484855366b663ce4b9b8c023be65ff95 18-Oct-2011 Ming Jia <mjia@google.com> Simplify the native-media demo.

1. Removed the old glsurfaceview.
2. remove physics and accelerometer related codes.
2. remove touch action.
4. Rotate the card a bit to show the tilting effect.

Change-Id: Ib2a7aeeef0b643644b22c285e6a295f5c09d3951
ative-media/src/com/example/nativemedia/MyGLSurfaceView.java
8cae77b0b4d0fb72ff2aba2066b65c0d73c98355 18-Oct-2011 Jamie Gennis <jgennis@google.com> wilhelm: fix native-media SurfaceTexture test

This change updates the Java portion of the native-media test to use the
new MediaPlayer#setSurface method rather than the MediaPlayer#setTexture
method, which is no longer present.

Change-Id: I0b89129b65fc3765b343ba5da7672e5d72afe775
ative-media/src/com/example/nativemedia/NativeMedia.java
c3b82a293ed06001ba6d50f111608160c6065ef2 18-Sep-2011 Glenn Kasten <gkasten@google.com> Final revisions for NDK API level 14

Rename ANDROID_MIME_MP2TS to XA_ANDROID_MIME_MP2TS and
ANDROID_MIME_AACADTS to SL_ANDROID_MIME_AACADTS and make public.
ANDROID_MIME_AACADTS_ANDROID_FRAMEWORK remains private.

Change-Id: Ie2cda273b6adb2db453aad188b28e64147f9e6b0
xamples/slesTestDecodeAac.cpp
ative-media/jni/native-media-jni.c
andbox/xaplay.c
6be131483b1ae3fefd5adda17294a22cff4db806 03-Oct-2011 Glenn Kasten <gkasten@google.com> Fix typos in usage: requires local filename

Change-Id: I6061757f3919718fc2b4da9392e37ed2c795f8b5
andbox/streamSource/slesTestPlayStream.cpp
3df2017547e7c9b9818068fc6fd83f66fa58bdc1 03-Aug-2011 Glenn Kasten <gkasten@google.com> Update the URI slow-down (playback rate) test

Use prefetch status callback to detect bad URI and signal to main thread.
Check return value of GetFillLevel and GetPrefetchStatus.
Display rate capabilities in a nicely formatted way.
Fix compile warnings.

Change-Id: I3f96ceb72a7a17ffe3dbcdcbda7053b3e736eb12
imeUri/slesTestSlowDownUri.cpp
29de1c6729c53706c039b061442732b974579166 27-Sep-2011 Glenn Kasten <gkasten@google.com> Merge "Use prefetch for error handling in mutesolo test"
ef2c495c9879347259de2fc3c8535b559ccd6792 27-Sep-2011 Glenn Kasten <gkasten@google.com> Merge "AAC decoder test"
a2478f0cb82910d4ef1202ff0a6b1723565d009f 13-Jun-2011 Glenn Kasten <gkasten@google.com> Use prefetch for error handling in mutesolo test

Change-Id: I526da804bd7f47b124d0aff3a47b1888fde3642f
istening/slesTest_playMuteSolo.cpp
e5cba3cbd006f0082af290cb34af8551c2710a03 02-Sep-2011 Glenn Kasten <gkasten@google.com> AAC decoder test

Record and display statistics on AAC frame sizes.
Record and display the number of buffer queue completions.
Make it optional whether to create a .raw file with PCM data.
Enable and display play events: HEADATMARKER and HEADATNEWPOS.
Add option to pause in middle of decoding.

Change-Id: Iaaa37337260cd061a13f942f6b5c07d7611b13a7
xamples/Android.mk
xamples/slesTestDecodeAac.cpp
c5479c4ca740a782d1ff4c82d1dc0f14de26962c 27-Sep-2011 Glenn Kasten <gkasten@google.com> Merge "Check result of GetFillLevel and GetPrefetchStatus"
41905ae712cbe5443d80224291e873f53c10ba5f 27-Sep-2011 Glenn Kasten <gkasten@google.com> Merge "Return after prefetch error in get position test"
1789f38026dd89f1650338295715ca6df2d0884c 27-Sep-2011 Glenn Kasten <gkasten@google.com> Merge "Decode to buffer queue test updates"
b4bdbe2d5d308effc7b9368491b0224d5cce6c1b 22-Aug-2011 Glenn Kasten <gkasten@google.com> Check result of GetFillLevel and GetPrefetchStatus

Change-Id: I07e962526215cbfe6ecf39bd8d0029e2b345bef3
imeUri/slesTestPlayUri.cpp
089a7c63adb033aec7b3200753e66b30ec8932be 29-Jul-2011 Glenn Kasten <gkasten@google.com> Return after prefetch error in get position test

Change-Id: I7de1ddd05e4d2115dc54215d62f8af76f6c352ff
imeUri/slesTestGetPositionUri.cpp
d6cdd7f7efdce16fc321f11bf5a3f88b3f28e244 03-Sep-2011 Glenn Kasten <gkasten@google.com> Decode to buffer queue test updates

Decrease frequency of decoder PCM buffer queue callback;
only display a line every 1000 PCM buffers.
Check result code returned by GetFillLevel and GetPrefetchStatus.
Share common call to GetPosition in DecProgressCallback for all HEAD* events.
Print error messages to stderr.

Change-Id: I088f7792c80693aa7742bfad36df1fada02fe1a4
xamples/slesTestDecodeToBuffQueue.cpp
947ccd3690e84649878f2583c701ca8de1b19ed4 24-Sep-2011 Glenn Kasten <gkasten@google.com> Bug 5365486 GetVideoDecoderCapabilities

If OMX IL implementation reports a codec with 0 profile/level
combinations, it should not be an error for the application to query
the number of profile/level combinations.

Change-Id: I6838ba1168da70a5c5e7d5a2832ec3ee1ee9aef3
xamples/xaVideoDecoderCapabilities.cpp
a07e6cd61b12a5c6ed78adaa88a08abd028f5a64 10-Sep-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 5236913 Update sample app for PLAYEVENT_HEADATEND with MP2TS

Update the sample application to receive the PLAYEVENT_HEADATEND
event after EOS has been processed.
Remove dead code in the corresponding implementation (in class
StreamPlayer).

Change-Id: Ibe484a8c0e9605c05cd47b154d6c0aff1e70d49e
ative-media/jni/native-media-jni.c
6bc8af4e67051af7c86c311cb9c50e294e547500 09-Sep-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 5236913 Callback for MP2TS when EOS was processed

When the buffer containing the EOS item in the Android Buffer Queue
gets processed, make sure the application callback gets called.

Change-Id: I7476a908419ec99c52c3d3f3938de3f86ab926c6
ative-media/jni/native-media-jni.c
113a9f14ea680a441540436b342f5008605aba27 09-Sep-2011 Jean-Michel Trivi <jmtrivi@google.com> Fix bug 5236913 EOS causes HEADATEND event in play callback

In AAC decode through an Android Buffer Queue, after receiving
an EOS command, prevent reading from the queue by returning
a size of 0, which causes the decoder to signal an end of
stream. This will cause the SL_PLAYEVENT_HEADATEND to be
fired (from the same thread that sends the decoded data)
if the event was part of the play event mask, and a callback
had been registered.

Change-Id: I435e8a66dbe9bc37f24c9e1f1c13f0dbd670b395
xamples/slesTestDecodeAac.cpp
5760ef34bd7f50060fd8fbda10e359f8a830bfbc 09-Sep-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 5236913 Callback for AAC decode when EOS was processed

When the buffer containing the EOS item in the Android Buffer Queue
gets processed, make sure the application callback gets called.

Change-Id: I0c8dfb61404ea33322a5755afa7c44213e53ce02
xamples/slesTestDecodeAac.cpp
0f92f48017588949daf7d24a339423e149bb2555 01-Sep-2011 Glenn Kasten <gkasten@google.com> Bug 5244675 PCM sample rate metadata units

The current metadata key macro name ANDROID_KEY_INDEX_PCMFORMAT_SAMPLESPERSEC
is confusing. This change renames it to ANDROID_KEY_INDEX_PCMFORMAT_SAMPLERATE,
and documents that it is in Hz rather than milliHz. The key string is
renamed from AndroidPcmFormatSamplesPerSec to AndroidPcmFormatSampleRate.

Details:

OpenSL ES 1.0.1 PCM struct SLDataFormat_PCM field samplesPerSec
[sic] is in milliHz. OpenSL ES 1.1 preserves that struct, but adds
struct SLDataFormat_PCM with field sampleRate also in milliHz. If the
ANDROID_KEY_INDEX_PCMFORMAT_* metadata keys were intended to exactly
model the OpenSL ES PCM data format struct, the metadata sample rate
would also be in milliHz units. However, the rest of Android operates
in Hz so we use Hz here also.

Backwards compatibility for the name should not be an issue,
as the initial beta developer has not yet started using this metadata.

Related change: delete a duplicate header file.

Change-Id: Ib8f620dfe7a328f621ddbb19f55e5691eb22d7b5
xamples/slesTestDecodeAac.cpp
xamples/slesTestDecodeToBuffQueue.cpp
f40b3718588c201794e9201d07671f5e293533eb 02-Sep-2011 Glenn Kasten <gkasten@google.com> Merge "Rename Android buffer queue GUID for future sink"
b77773fbc5a8133e4ba3ba70d3f37a7549b0e8fc 02-Sep-2011 Glenn Kasten <gkasten@google.com> Merge "Bug 5244675 miscellaenous AAC decode test"
60ca9f9ef02f6e486c3338cb811f603dd7825c05 29-Aug-2011 Glenn Kasten <gkasten@google.com> Rename Android buffer queue GUID for future sink

This change will make it easier to have Android buffer queue as a sink in
the future. For backwards source code compatibility with beta developers,
retain the old name temporarily. As soon as they have switched to the
new name, we will remove the old name.

Details:
- rename XA_IID_ANDROIDBUFFERQUEUE to XA_IID_ANDROIDBUFFERQUEUESOURCE
- rename SL_IID_ANDROIDBUFFERQUEUE to SL_IID_ANDROIDBUFFERQUEUESOURCE
- rename MPH_ANDROIDBUFFERQUEUE to MPH_ANDROIDBUFFERQUEUESOURCE
- did not rename the data locators and interface struct,
as they can be shared across both source and sink
- did not rename the member field mAndroidBufferQueue in
CAudioPlayer / CMediaPlayer as that would be a huge change;
can do that later if necessary
- the SINK definition will be added later when needed

Change-Id: I36dc01050efb99d4d7802b2ca2b870f4d978ee21
ative-media/jni/native-media-jni.c
andbox/streamSource/slesTestPlayStream.cpp
andbox/xaplay.c
ac8c7318e1d7ec1358bbf924e1bc2cee45b44fc6 19-Aug-2011 Glenn Kasten <gkasten@google.com> Add rewind (discontinuity) to native-media test

Change-Id: I0f32564d2a2937092436dd48fef877ed55b2d4f3
ative-media/jni/Android.mk
ative-media/jni/native-media-jni.c
ative-media/src/com/example/nativemedia/NativeMedia.java
33af4f47406b64af73e9e42e209c36320ea55410 31-Aug-2011 Glenn Kasten <gkasten@google.com> Bug 5244675 miscellaenous AAC decode test

Fix bug in counting encoded frames.
Test get play position and duration at various points.
Display all PCM metadata (in particular the channel mask).
Add example of expected output.

Change-Id: I0d0a629755a37b71a1540e79ae7a6f1ed7095a24
xamples/slesTestDecodeAac.cpp
688178c51666cf7df5814e7eac3a01fc3e076c0f 25-Aug-2011 Jean-Michel Trivi <jmtrivi@google.com> Example of AAC ADTS decoding with OpenSL ES

Put AAC ADTS in an AndroidBufferQueue, retrieve PCM data through
a BufferQueue.

Change-Id: I9718d7a9e030a2c3568de8579f3329b76f63d891
xamples/Android.mk
xamples/slesTestDecodeAac.cpp
d1df50751f8b112de78970c71f56fcd2edcb81c4 26-Aug-2011 Jean-Michel Trivi <jmtrivi@google.com> Merge "Metadata keys for PCM decoding"
68c8a1b6deea46eeca57848768a92e96d583aadd 25-Aug-2011 Jean-Michel Trivi <jmtrivi@google.com> Metadata keys for PCM decoding

Declare in a public header the metadata keys an application which
decodes audio data would use to figure out the output PCM format.

Make the SL ES Android header also include the configuration and
metadata headers.
Update test apps to reflect this.

Change-Id: I298db4fdb800df2d48047691441aa7489aad4822
xamples/slesTestDecodeToBuffQueue.cpp
xamples/slesTestRecBuffQueue.cpp
imeUri/slesTestPlayStreamType.cpp
75290ff394698c53f35a21612c03b8ddd21fecf9 22-Aug-2011 Glenn Kasten <gkasten@google.com> xaplay command-line mediaplayer for MPEG-2 TS ABQ

Change-Id: Id5ea3f478f45d4fa4b86772593ae831d9eade952
andbox/Android.mk
andbox/nativewindow.cpp
andbox/nativewindow.h
andbox/xaplay.c
ebca1a420c4ada9eff2e82f0100abaea95b48f24 11-Aug-2011 Glenn Kasten <gkasten@google.com> Test playbq: 8-bit and big-endian byte ordering

Change-Id: Ic34f35226fee07945925cad8cfbc10c756092fee
andbox/playbq.c
4dd1fab74463de4852b86af64481006f87d48b54 09-Aug-2011 Glenn Kasten <gkasten@google.com> Updates to slesTestRecBuffQueue test app

Allow the preset number to be specified on command line,
or to use default.

Change-Id: Ia4e996f8726a6bd8ca781bba5930b63bcba854bc
xamples/slesTestRecBuffQueue.cpp
6807fa7d803d02725fcca4422ae08f6c8e6db725 08-Aug-2011 Glenn Kasten <gkasten@google.com> Merge "Add playback rate to buffer queue test player"
33e2883826ba6902ad20b6b4019d5b39b6089536 08-Aug-2011 Glenn Kasten <gkasten@google.com> Merge "Miscellaneous loop test improvements"
56c5b9b986c00839e841f9660d9847173807a0c1 02-Aug-2011 Glenn Kasten <gkasten@google.com> Miscellaneous loop test improvements

Enable HEADATEND event to see whether looping causes that event.
Recover from prefetch errors using the new approach of condition signal rather than polling.
Check result returned by GetFillLevel.

Other changes:
- Make assert work.
- Pass NULL as 3rd parameter to RegisterCallback when context is not needed.
- Use CheckErr instead of assert when checking result codes.
- Add comments.

Change-Id: I972b9eca9836e62141b6a078345f091e60689321
imeUri/Android.mk
imeUri/slesTestLoopUri.cpp
9a6c9db763121c3b11765c6c8cf935983c0385bf 03-Aug-2011 Glenn Kasten <gkasten@google.com> Add playback rate to buffer queue test player

Change-Id: I831290c1d70bbd66031f609a63549801b7c7f57b
andbox/playbq.c
8653e8eeb955814f49b3b9548e0b6d2931b0221b 24-Jul-2011 Glenn Kasten <gkasten@google.com> Fix race in reverb test

Was setting play state to PAUSED before enabling prefetch callbacks

Change-Id: Idc3d19d87799afe7e8314199c1317cf2cea2c449
andbox/reverb.c
4076e5009bfe70bc06a78f5aafec77af6c03201d 02-Aug-2011 Glenn Kasten <gkasten@google.com> Bug 5108531 Report the correct API level

Use build macro PLATFORM_SDK_VERSION to automatically update the reported
value, however the test program will still need manual updates.

Change-Id: Iae044605db65021c7d1e9825aab80ab5d6b552a8
andbox/object.c
5050a75e342ce45794d56666cddde3d46472acc7 27-Jul-2011 Jean-Michel Trivi <jmtrivi@google.com> Report last decoded position as AudioPlayer position for PCM decode

Change-Id: I1ec413137d549235af4dc66cb033e1cd0bbbad62
xamples/slesTestDecodeToBuffQueue.cpp
94a5af22ba0a0f6b54e9d0ad15f9bb70f46b6d58 24-Jul-2011 Glenn Kasten <gkasten@google.com> Merge "pthread_signal instead of polling prefetch status"
0ab75a12c246f871771dc37b4ac0233cf7ee3f47 21-Jul-2011 Glenn Kasten <gkasten@google.com> pthread_signal instead of polling prefetch status

Also add looping for short files

Change-Id: Ia115ca5ff388a4824d56fad2ad34881479ab3f0d
andbox/reverb.c
47c325b8fe4cd967886ee82070c1eb3d1bb0c18c 20-Jul-2011 Glenn Kasten <gkasten@google.com> Miscellaneous improvements to preset reverb test

Add option to select URI or fd locator.
Use prefetch status callback to detect bad URI.
Fix bug where it was not playing the last few seconds of file.
Decrease reverb on/off interval from 5 to 3 seconds, for shorter files.
Add looping.

Change-Id: I34a0506742de14adcf996bfc508177b260afded8
xamples/slesTestSendToPresetReverb.cpp
62e784b9b9146cd926077dd550507add3e2a95b0 21-Jul-2011 Glenn Kasten <gkasten@google.com> Merge "Use prefetch status to recover from URI errors"
d91db4c34bdffa3b6d3f9234c8f4f8506bc0aa2e 20-Jul-2011 Glenn Kasten <gkasten@google.com> Use prefetch status to recover from URI errors

Change-Id: I1afa4af018c372448a456824c78e3e1ab1c13b42
andbox/multiplay.c
581dacbabb3db9dd65ae6cd6dee791e1a7fecd7a 20-Jul-2011 Jean-Michel Trivi <jmtrivi@google.com> Merge "Fix bug 5049371 Metadata for decode to PCM buffer queue"
ba539d5b0d28856f949a78d7a0b29064fdd805c9 20-Jul-2011 Glenn Kasten <gkasten@google.com> Merge "Use the documented header filenames"
ad09ae6fadea06f5a02630b66ce18acf88bb790d 20-Jul-2011 Glenn Kasten <gkasten@google.com> Merge "Fix newline"
54cad4f35a090a06e655fcc9e072e1d38f9e7689 20-Jul-2011 Jean-Michel Trivi <jmtrivi@google.com> Fix bug 5049371 Metadata for decode to PCM buffer queue

When decoding a URI or FD with OpenSL ES to a PCM buffer queue,
you cannot rely on the information given by the extractor, or
the OMXCodec before the latter has decoded one buffer.

The fix consists in two parts:
1/ where to retrieve the PCM format from:
the information first retrieved from the extractor if available,
but then overwritten by the OMXCodec values as soon as it
issues INFO_FORMAT_CHANGED
2/ when can the application retrieve the information:
the information is available when the first buffer of decoded
data is returned to the application via the buffer queue
callback. The test app is updated to reflect this, and verify
that the query can safely happen during the callback.

Change-Id: Ic034c7ff9412c94e9df2aaa3c1d61e9d3bf507d9
xamples/slesTestDecodeToBuffQueue.cpp
c6853892c94800e72c0bd676d5d2136d48cea76e 19-Jul-2011 Glenn Kasten <gkasten@google.com> Use the documented header filenames

Both Khronos and we say to use < > in our docs

Change-Id: Ibf1d2b83036582a605aa6b9043210c89a4eb0e1e
utomated/BufferQueue_test.cpp
xamples/Android.mk
xamples/slesTestBassBoostPath.cpp
xamples/slesTestEffectCapabilities.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestFeedback.cpp
xamples/slesTestPlayFdPath.cpp
xamples/slesTestRecBuffQueue.cpp
xamples/slesTestSawtoothBufferQueue.cpp
xamples/slesTestSendToPresetReverb.cpp
xamples/slesTestVirtualizerPath.cpp
xamples/xaVideoDecoderCapabilities.cpp
istening/seekTorture.c
istening/slesTest_playMuteSolo.cpp
imeUri/slesTestGetPositionUri.cpp
imeUri/slesTestLoopUri.cpp
imeUri/slesTestManyPlayers.cpp
imeUri/slesTestPlayStreamType.cpp
imeUri/slesTestPlayUri.cpp
imeUri/slesTestPlayUri2.cpp
imeUri/slesTestSlowDownUri.cpp
imeUri/slesTest_playStates.cpp
imeUri_test.cpp
ative-media/jni/native-media-jni.c
andbox/configbq.c
andbox/dim.c
andbox/dual.c
andbox/engine.c
andbox/intbufq.c
andbox/monkey.c
andbox/multiplay.c
andbox/multithread.c
andbox/object.c
andbox/outputmix.c
andbox/playbq.c
andbox/reverb.c
andbox/srcsink.c
andbox/streamSource/slesTestPlayStream.cpp
andbox/urimime.c
andbox/xa.c
c2f5fd8659f405de1a4769dfb075b2b27b217bd8 18-Jul-2011 Glenn Kasten <gkasten@google.com> Fix newline

Change-Id: Id06193de5ba82bebe36515c0ca18702b3a5c3222
xamples/slesTestSendToPresetReverb.cpp
6e7e174807fc639c49125ced8962aa369370fbf0 13-Jul-2011 Jean-Michel Trivi <jmtrivi@google.com> Implement XAVideoDecoderCapabilitiesItf

Add support for the OpenMAX AL XAVideoDecoderCapabilitiesItf
engine interface.

Implement the Android support of this interface in
VideoCodec_to_android.*. This functionality relies
on OMXCodec::QueryCodecs() feature, and does only
expose hardware codec capabilities (see full note in
VideoCodec_to_android.h).

Add sample code to list the platform's video decoders
and their profile / level combinations.

Change-Id: Iff6a42542c1db67ca1dcf539449ca96aa5944f6d
xamples/Android.mk
xamples/xaVideoDecoderCapabilities.cpp
fd921c5e16782bcf10f997487b44deb38156ab2b 12-Jul-2011 Jeff Brown <jeffbrown@google.com> Merge "Remove the simulator target from all makefiles. Bug: 5010576"
ffea36e11b068d171549b64ee767eefd2637555a 12-Jul-2011 Jeff Brown <jeffbrown@google.com> Remove the simulator target from all makefiles.
Bug: 5010576

Change-Id: I59e3c37c05c1114648172d9aba7abf035986bede
ndroid.mk
utomated/Android.mk
7c7511aa96e54d94df836357fbbf76c681f20a26 10-Jul-2011 Glenn Kasten <gkasten@google.com> Add --always-on option for effects tests

This will be used for CPU load measurements.
Also fix bug in duration calculation for reverb test.

Change-Id: Ia2f91fa7c3e564047378341d31e3f4bfcace5f98
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestSendToPresetReverb.cpp
xamples/slesTestVirtualizerPath.cpp
17af251383a81d5c74b94168c2e2d8a35c9d224d 10-Jul-2011 Glenn Kasten <gkasten@google.com> Merge "Add --always-on option for bass boost test"
b657e861b1a873a73cb9f492479c655dfdb68754 10-Jul-2011 Glenn Kasten <gkasten@google.com> Add --always-on option for bass boost test

This will be used for CPU load measurements

Change-Id: Ib8b15bd31d8fa5672ec69c6d2595e4590a700d53
xamples/slesTestBassBoostPath.cpp
4b0e0b2860ffd5e246b42c8a434833cca2f068b3 08-Jul-2011 Jean-Michel Trivi <jmtrivi@google.com> Implement GetPosition for players playing from a URI/FD

AudioPlayer (OpenSL ES) and MediaPlayer (OpenMAX AL) that play
media from a URI or FD are implemented on top of an Android
MediaPlayer. This CL implements requesting the current position
from the underlying MediaPlayer object inside the event loop.
At this stage, GetPosition cannot be called from inside a
callback as the callback is made on the same thread that will
process the asynchronous part of the GetPosition implementation.
Add test app for GetPosition.

Change-Id: Ife768bc40e37fc60cc19f6ba84bbe6cb06cc6590
imeUri/Android.mk
imeUri/slesTestGetPositionUri.cpp
01d7c3783cc019c67cca16ed4e563330257d4c4d 28-Jun-2011 Glenn Kasten <gkasten@google.com> Merge "Bug 4571308 Test video timestamps"
3bbd3bb7fcb082eba313614f072c11c41b38ebfe 27-Jun-2011 Glenn Kasten <gkasten@google.com> Bug 4571308 Test video timestamps

Change-Id: I4d1fe3b9e090fe014c45432a91ea43360213ee2e
ative-media/res/layout/main.xml
ative-media/res/values/strings.xml
ative-media/src/com/example/nativemedia/MyGLSurfaceView.java
ative-media/src/com/example/nativemedia/NativeMedia.java
7f5cc1afe49395fefaad9b2bbd728a45d1bfda6a 16-Jun-2011 Jean-Michel Trivi <jmtrivi@google.com> OpenSL ES: additional features when decoding to PCM

Support the following features useful when decoding a compressed
asset to PCM:
- GetDuration in SLPlayItf
- implemented SLMetadataExtractionItf on an AudioPlayer whose
data sink is a buffer queue (i.e. it's a decoder)
- added support for 6 new metadata keys that can be queried
through SLMetadataExtractionItf, which match the fields
of the SLDataFormat_PCM structure.
Updated the decode sample code to use these features: the
slesTestDecodeToBuffQueue app now displays:
- the number of channels
- the channel mask
- the sample size
- the container size
- the sample rate
- the format endianness

Change-Id: I3ca1e29828fd8c16c89da43a28df429c9cdef7af
xamples/slesTestDecodeToBuffQueue.cpp
58432eb9cea995c69b4f905e68b38c1b8216edeb 13-Jun-2011 Glenn Kasten <gkasten@google.com> Better defaults and fix warnings

Use better defaults for slesTestFeedback rxBufCount and channel count.
Fix build warnings.

Change-Id: Ieef4750cbc454029e61524cc8011a6c774088762
utomated/BufferQueue_test.cpp
xamples/slesTestBassBoostPath.cpp
xamples/slesTestDecodeToBuffQueue.cpp
xamples/slesTestEffectCapabilities.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestFeedback.cpp
xamples/slesTestPlayFdPath.cpp
xamples/slesTestRecBuffQueue.cpp
xamples/slesTestSawtoothBufferQueue.cpp
xamples/slesTestSendToPresetReverb.cpp
xamples/slesTestVirtualizerPath.cpp
istening/slesTest_playMuteSolo.cpp
imeUri/slesTestLoopUri.cpp
imeUri/slesTestPlayStreamType.cpp
imeUri/slesTestPlayUri.cpp
imeUri/slesTestPlayUri2.cpp
imeUri/slesTestSlowDownUri.cpp
imeUri/slesTest_playStates.cpp
ative-media/jni/native-media-jni.c
andbox/configbq.c
andbox/dual.c
andbox/engine.c
andbox/getch.c
andbox/getch.h
andbox/intbufq.c
andbox/multithread.c
andbox/object.c
andbox/outputmix.c
andbox/reverb.c
andbox/streamSource/slesTestPlayStream.cpp
andbox/xa.c
2b750ac8e486b75a0f5755d4b595077ec525235e 02-Jun-2011 Jean-Michel Trivi <jmtrivi@google.com> Stress test for OpenSL ES: create and delete many players

Implementation of a test to deal with 40 AudioPlayers:
- creation
- realize
- configuration
- prefetching
- playback
- destruction
If a player was created, regardless of whether the other
operations were successful, it will be destroyed.
The number of players, 40, is chosen specifically because it
is larger than the number of objects Wilhelm is currently
capable of supporting, and larger than the number of tracks
supported by the platform mixer.

Change-Id: I42287039d59b77e59c60d074fbc0177d9726b359
imeUri/Android.mk
imeUri/slesTestManyPlayers.cpp
ebbc7dd54bb3a6b05ac899af97fc4b7d0ad6f400 11-May-2011 Jean-Michel Trivi <jmtrivi@google.com> Update automated OpenSL ES test for playback from file path

Remove test where duration is queried after the player is realized
but before prefetching has started: invalid test, duration isn't
known at this time.

Changed wording of error messages to make test failures easier to
identify

Added test to compare retrieved duration, and expected duration.

Fixed expected file duration: was 75s, should be 71s

Change-Id: I6230c00f0c945c6966e1f08ecfbc67452667cf33
imeUri_test.cpp
e31a69fcbe27894a597176d05a08e04c06092021 13-Apr-2011 Glenn Kasten <gkasten@google.com> Fix various bugs found with unit tests

ISeek::SetLoop was returning undefined status.
Khronos Bug 7614 - sizeof(long) != 32 bits on x86_64.
Fix bug in IID hashing due to the above.
Fix bug in GenericMediaPlayer::onLoop; was using mPlayer without checking for NULL.
Fix wrong API level in tests/sandbox/object.c.
Decrease log level from I to V in MediaPlayerNotificationClient::notify
and GenericPlayer::~GenericPlayer.
Fix memory leak in tests/sandbox/engine.c.
Comment out overly verbose log in tests/sandbox/streamSource/slesTestPlayStream.cpp.

Change-Id: I322fa9e19ee95ea1e18870a20f6a3c03b8f21208
andbox/engine.c
andbox/object.c
andbox/streamSource/slesTestPlayStream.cpp
4ee246c55533bdab8ab5fa0f0581744fe58e7c91 29-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Move support for SL URI and FD playback under GenericPlayer class

The SfPlayer class was implementing URI and FD decode and playback
in the application process. This CL removes this class entirely
and moves its functionality under the GenericPlayer class. This
means that the playback of URIs and FDs is now implemented through
an android::MediaPlayer object running in the media service.

The SfPlayer header had many StageFright and system includes, which
are now moved to the relevant files where they are required,
instead of automagically coming from sles_allinclusive.h.

Note that this CL breaks support for the following OpenSL ES features
due to missing Android MediaPlayer features:
SLPlayItf.GetPosition
HEADATMARKER
HEADATNEWPOSITION
SLVolumeItf.EnableStereoPosition
SetStereoPosition
SLMuteSoloItf
SLPlaybackRateItf

Support for those features will be reintegrated in subsequent CLs.

Change-Id: I8d7f6ea006eb7b876ef1ca1909d74b4517335850
imeUri/slesTestPlayUri.cpp
4c94f69ce3aafc6bafa265fe2ef448c621e66f15 17-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> resolved conflicts for merge of c5dcfeb2 to master

Change-Id: Iff3428cd554c5b5940da8a243c661ae70a92af8d
22cc3b025511d50923a1ff3d6462ff9f2fad0587 17-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> am 30ebe675: Bug 3329759 clean logs, PTS should be unsigned

* commit '30ebe675beff91283cc72d4ee5e94e56ab7e107f':
Bug 3329759 clean logs, PTS should be unsigned
2de28cc2b424a49a440e1d5893beb07086ab0ad7 17-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Merge "Bug 4106199 Split libOpenSLES.so & libOpenMAXAL.so" into honeycomb-mr1
527f8ca99f2938d6569fc25dcf3256985a54dec6 16-Mar-2011 Glenn Kasten <gkasten@google.com> Bug 4106199 Split libOpenSLES.so & libOpenMAXAL.so

Change-Id: I718cf6bcfff51a6fb153928eb160a36b4ca9fc96
ative-media/jni/Android.mk
andbox/Android.mk
e9236d046fdb5cac0696c42e03443a2439188146 16-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 3329759 clean logs, PTS should be unsigned

- Don't pollute logs.
- Save MPEG-2 PTS as an unsigned 64bit value, negative values are
invalid.

Change-Id: I51d427789dd1e42219a63c68159f2e28628f0448
andbox/streamSource/slesTestPlayStream.cpp
9a40703b539028b2dce5a62d94deb81375d75f6a 16-Mar-2011 Glenn Kasten <gkasten@google.com> am 7a713baa: Merge "Bug 4099084 native window data locator" into honeycomb-mr1

* commit '7a713baae6cac3740cc27380f1dc8099dd272470':
Bug 4099084 native window data locator
0f1c886e9bea56ce7b4ccfa58d733b0952942751 16-Mar-2011 Glenn Kasten <gkasten@google.com> Merge "Bug 4099084 native window data locator" into honeycomb-mr1
02b00f099a69e1ed58ae901febb7e5c831ec14dd 16-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> am 632d1061: Merge "Bug 3329759 callback mask for TS streaming" into honeycomb-mr1

* commit '632d10616d5d20296d9ea32d4c94d2fc76926534':
Bug 3329759 callback mask for TS streaming
39310fca2e30101fa6e5168da443581cc60c20bf 16-Mar-2011 Glenn Kasten <gkasten@google.com> Bug 4099084 native window data locator

Change-Id: I03cac7501c3f185a2f95395b140b52b695081c4b
ative-media/jni/native-media-jni.c
1c853a41d9d9886e60618a7c878ce3912f46bf3c 15-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 3329759 callback mask for TS streaming

- declare a "buffer event" item key and the event mask matching
the OpenSL ES 1.1 buffer queue event mask
- added a buffer state field in AdvancedBufferHeader to keep
track of the lifecycle of a buffer in the queue
- in StreamPlayer, store a constant to be sent as the item
each time a buffer is dequeued because it's been processed
- fix bug in playStream test app where after clearing the
queue, the data was read to the last dequeued buffer address,
rather than at the beginning of the cache.

Change-Id: I07141c8a913dfedeb9fde41d80afbce794ab7379
andbox/streamSource/slesTestPlayStream.cpp
6e0c1cc74aac0f9289df066f3fc7cc6aab954943 15-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> am fcc99629: Bug 3329759 Implement streamInformation and volume in OpenMAX AL

* commit 'fcc996296bdbf6c3949ad4312991fdde4ae2e157':
Bug 3329759 Implement streamInformation and volume in OpenMAX AL
37dc2fccf3f122b79ebd554de209d0a3c94ae161 09-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 3329759 Implement streamInformation and volume in OpenMAX AL

- Implement StreamInformation for video size notification.
- Implement the XAVolumeItf for volume control
- Fix bug in GUID -> MPH hash.
- Fixed typo in GenericPlayer::pause() log
- Do not signal a discontinuity automatically when the ABQ is
cleared because clearing the queue doesn't imply there will
be a discontinuity in the data (e.g. the same data that was
cleared could be reenqueued)
- In "native-media" test app: add test code to exercise the
XAVolumeItf functionality.

Change-Id: I9f69f8cacbdce51b6d96d60141ec1d0f645df991
ative-media/jni/native-media-jni.c
andbox/streamSource/slesTestPlayStream.cpp
f62485fd570f004d0e336e4c2624a935a4a284cc 14-Mar-2011 Iliyan Malchev <malchev@google.com> system/media: remove LOCAL_PRELINK_MODULE

Change-Id: I55942287d5789a6297ab16f4049f529cb9f9e56c
Signed-off-by: Iliyan Malchev <malchev@google.com>
ative-media/jni/Android.mk
f2f18de503fb20e101ce483ff55d5f98dac83f86 11-Mar-2011 Glenn Kasten <gkasten@google.com> Merge "Bug 3463332 Unified test/demo of video sink & APIs" into honeycomb-mr1
b66b0745d45f4c0c7620749185f7fb3306804ce3 09-Mar-2011 Glenn Kasten <gkasten@google.com> Bug 3463332 Unified test/demo of video sink & APIs

Note: this only affects test code, nothing in the platform.

Can use for testing Java and native APIs
Video sinks is selectable as Surface (SurfaceView) or SurfaceTexture (GLSurfaceView)
Media source is selectable from drop-down list

Change-Id: I45fe16b672e0783ee89e0985b446b8ecc4f452e3
ative-media/Android.mk
ative-media/AndroidManifest.xml
ative-media/jni/native-media-jni.c
ative-media/res/layout/main.xml
ative-media/res/values/strings.xml
ative-media/src/com/example/nativemedia/MyGLSurfaceView.java
ative-media/src/com/example/nativemedia/NativeMedia.java
e7bfcdc183454ec959ff51342f0973cabba219b2 08-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 3329759 Implement Clear() and GetState() for MPEG-2 TS

- implemented Clear() in AndroidBufferQueue
- declared and implemented GetState() in AndroidBufferQueue
- fixed typo in AudioPlayer_to_android.cpp that cause a "case"
to be compiled as a label (no unused label warning from
compiler)
- more test in sandbox/streamSource

Change-Id: If4eede16430cda943224bf950669cc105ac2f894
andbox/streamSource/slesTestPlayStream.cpp
70c49ae2867094072a4365423417ea452bf82231 07-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 3329759 support commands in SLAndroidBufferQueueItf

Support for EOS, DISCONTINUITY, and DISCONTINUITY with
a PTS.

- in IAndroidBufferQueue structure, added buffer type
- modified AdvancedBufferHeader structure to have a buffer
type-specific structure that contains all the items for each
buffer
- added parsing of items when enqueueing a buffer
- enforce buffer size enqueue to be a multiple of MPEG-2 TS
block size for buffer of the corresponding types
- when enqueueing a buffer on an empty queue, implemented
an asynchronous notification on StreamPlayer to consume
the newly queued buffer. Verified this kicks off playback
after having starved the framework for buffers.
- report unknown duration when using AndroidBufferQueue

Change-Id: I9bde97a6c6ffca7d376b4963313b820b35f50a26
ative-media/jni/native-media-jni.c
andbox/streamSource/slesTestPlayStream.cpp
ad1ab1d13a9b043202b9d5cdc1d8c4ef66cbbca8 05-Mar-2011 Glenn Kasten <gkasten@google.com> Bug 3329759 Surface texture as video sink

XA_DATALOCATOR_NATIVEDISPLAY now allows either a Surface or SurfaceTexture
together with a JNIEnv *.

Miscellaneous fixes:
- Clarify test button labels.
- Line length 100.
- Fix typos in XA_DATALOCATOR_ANDROIDFD and XA_DATALOCATOR_ANDROIDFD_USE_FILE_SIZE.

Change-Id: I3f3c604dfda3cf66ef7d7adc8689564a83623b2f
ative-media/jni/native-media-jni.c
ative-media/res/values/strings.xml
ative-media/src/com/example/nativemedia/NativeMedia.java
d158d31a6bbb06426b71c3d097b7768bc3fb79a3 04-Mar-2011 Jean-Michel Trivi <jmtrivi@google.com> Bug 3329759 TS streaming over SLAndroidBufferQueueItf

Modify the SLAndroidBufferQueueItf interface to offer a model
where buffers of data can be queued along with commands
(messages) when used for playback, or buffers of data can be
received along with metadata (messages)

changes:
- new callback and enqueue functions in SLAndroidBufferQueueItf
and XAAndroidBufferQueueItf.
- definition of a new struct, AdvancedBufferHeader, for
the buffers in the queue.
- decoupling of the "buffer available to be filled" from SF
and the call to the ABQ callback. Implemented in new
file AndroidBufferQueueSource.cpp
- source/sink checks and memory allocation when creating an
AudioPlayer or MediaPlayer that uses SLAndroidBufferQueueItf,
and verifying the data fed to the ABQ is declared as
SL_CONTAINERTYPE_MPEG_TS
- updated tests/native-media XA demo code, and
tests/sandbox/streamSource to use the new interface.

Change-Id: I48e44f346e718041d835fde51e349923fcc1f4b1
ative-media/jni/native-media-jni.c
andbox/streamSource/slesTestPlayStream.cpp
1fd0cd18598d76e9a0f9e6675e4d988be41644f7 23-Feb-2011 Jean-Michel Trivi <jmtrivi@google.com> Fix bug in decode to memory example app

Bug in detecting write errors: count and size in fwrite were
swapped, so an error was always reported.

Change-Id: If20276a412d110c2791c50ebc41761d6e1d3386e
xamples/slesTestDecodeToBuffQueue.cpp
ebd4303bd8fb9f1c6a61ff66332248a43b781df5 12-Feb-2011 Jean-Michel Trivi <jmtrivi@google.com> OpenSL ES: add demo app for decode to PCM buffer queue.

Example for the decoding of a compressed file to PCM, saved in
a .raw file as the decoded buffers are received through a
buffer queue.

Change-Id: Ia44078e00569e6aa1f14ab3eaa2b2ebfb07b709d
xamples/Android.mk
xamples/slesTestDecodeToBuffQueue.cpp
04186529e0bcdfa543aa67013fb6d44bf4a1fbbe 25-Jan-2011 Glenn Kasten <gkasten@google.com> Add more test cases to reverb test

Change-Id: Ia0970ebd8e182a45157a6edbef762f2350605a9b
andbox/reverb.c
262059f71a68edc5e510427c63f5f1623d3672a8 12-Jan-2011 Glenn Kasten <gkasten@google.com> Directory re-organization

Change-Id: I8e3f12a22e765d36ddefd87edf204735b25474f6
ndroid.mk
utomated/Android.mk
xamples/Android.mk
istening/Android.mk
imeUri/Android.mk
ative-media/jni/Android.mk
andbox/Android.mk
andbox/streamSource/Android.mk
6b158877242b43a0c0f63b56b035c74207b71a34 12-Jan-2011 Glenn Kasten <gkasten@google.com> Merge "AudioRecorder source format should be NULL not PCM" into honeycomb
e670554ea199eef745740eaccc176ff283b0cd10 12-Jan-2011 Glenn Kasten <gkasten@google.com> Ignore the pFormat in some cases per spec

Change-Id: Iac14c558fa7410a4b3de5c89f9e5d475404efcea
andbox/srcsink.c
35c82a8173d1fcc18ae0bc08954a018bfce041de 11-Jan-2011 Glenn Kasten <gkasten@google.com> AudioRecorder source format should be NULL not PCM

Change-Id: I4bfdfa3700685f1705e0430fd4fe15b51ab9cefb
xamples/slesTestFeedback.cpp
1d081e49a10543018e1ae33792bd3d30504719ba 05-Jan-2011 Glenn Kasten <gkasten@google.com> Squashed commit of 9 cherry-picks from master

Android SDK level report is the highest available

Fix bug in seek torture test
This was found because we now do better checking of data locators.

Comment out and decrease log level for play state

Improve error handling and help message in test

Include data source or sink name in log messages

Bug 3326605: AudioRecorder uses wrong channel mask

Don't overwrite previous error in locator check

OpenSLESUT.h is not (yet) a supported header
so remove the symlink from the SLES/ directory

Shared engine between OpenSL ES and OpenMAX AL
utomated/Android.mk
utomated/BufferQueue_test.cpp
istening/seekTorture.c
imeUri/slesTestPlayStreamType.cpp
andbox/Android.mk
andbox/dual.c
andbox/engine.c
andbox/object.c
andbox/outputmix.c
andbox/xa.c
f183d0fd23f1c0f45ceaf280d404f1b0709a699a 07-Jan-2011 Jean-Michel Trivi <jmtrivi@google.com> OpenMAX AL example: remove useless includes

It's no longer necessary to include the OpenSL ES headers in
an OpenMAX AL application for the declaration of
XA_IID_ANDROIDBUFFERQUEUE.

Change-Id: I2077997087ff23db033ab69c498daf8eaaffedc9
ative-media/jni/native-media-jni.c
2daf9b3ede1268e0f89cff53898b7b10940d8de1 16-Dec-2010 Glenn Kasten <gkasten@google.com> Merge "Test bug fixes"
295395c087000a9d804f8d12d58dea4cd9e7d26a 15-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> Use NDK API to initialize display surface in OpenMAX AL TS demo.

Use ANativeWindow functions defined in android/native_window_jni.h
to initialize the display surface to be used as video sink by the
OpenMAX AL MediaPlayer.

Change-Id: I36a91f4d9a928efa861ae0c01ea5856d4e36b46f
ative-media/jni/Android.mk
ative-media/jni/native-media-jni.c
841a4d749b44b67f43a4dfad9dbc477e48f87529 14-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> Merge "OpenMAX AL: set video display surface from video sink"
0e47a0657162bbff48886ea2f5c68d9edb607768 14-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> OpenMAX AL: set video display surface from video sink

Initialize the media player's video surface with the surface pointer
obtained from the Java Surface.
Added notes on parts of the interface that will change, and are
currently in place for the sample code to run, before the
upcoming video initialization changes.

Change-Id: Id606f4bca68d227fa9df863922b880e865f845d5
ative-media/jni/native-media-jni.c
a0a5dfe5210c3e00e0d49b65a9bf23fcc43407a8 14-Dec-2010 Ying Wang <wangying@google.com> The correct tag is "tests", not "test"

Change-Id: Ib28337b6f2bf2598175dc697950c46a9c7e98b1b
ative-media/Android.mk
ative-media/jni/Android.mk
2246c698482ab6860906672229f0ae6d886e6302 16-Nov-2010 Glenn Kasten <gkasten@google.com> Test bug fixes

Preset reverb durationInMsec changed from 5000 to 10000.
NDK does not have an independent API level, so use the SDK's API level.
Removed a workaround for a bug which is now fixed in the implementation.
Fix uninitialized variable in test.

Change-Id: Ibaa4f1d2351e8f75290377cadc02ee2709bf720b
xamples/slesTestRecBuffQueue.cpp
xamples/slesTestSendToPresetReverb.cpp
andbox/object.c
andbox/srcsink.c
eae4df541ba1d46f65d37e959baf2127aa632c93 10-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> Start support for XAAndroidBufferQueueItf in OpenMAX AL

Added an Android OpenMAX AL header for the Android interfaces
Registered the AndroidBufferQueueItf as an explicit
interface on MediaPlayer.
Updated the Java+Native example to register a callback from
which OpenMAX AL can retrieve the data to play
Started unifying the player object used by OpenMAX AL and
OpenSL ES so they use a common class.

Change-Id: I73cec8c802f74767545c91278e5e73c8c7995218
ative-media/jni/native-media-jni.c
ative-media/src/com/example/nativemedia/NativeMedia.java
andbox/streamSource/slesTestPlayStream.cpp
16ce39d96d41884c7b0d1676553ab8167baaab74 09-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> Add superclass for audio-video playback

Change-Id: Ie7f5cb9d789d41c605dc318bbb311aadabce2c96
andbox/streamSource/slesTestPlayStream.cpp
97bdbe13fc48640babe6c1ce270660476f04c3df 07-Dec-2010 Glenn Kasten <gkasten@google.com> Native media test app

Change-Id: I2089733b4b4adc1d9da75a9c93c72b7c353c668f
ative-media/Android.mk
ative-media/AndroidManifest.xml
ative-media/jni/Android.mk
ative-media/jni/native-media-jni.c
ative-media/res/drawable/icon.png
ative-media/res/layout/main.xml
ative-media/res/values/strings.xml
ative-media/src/com/example/nativemedia/NativeMedia.java
94a37e8117fb72790882dfb815f99e2365754c74 03-Dec-2010 Glenn Kasten <gkasten@google.com> Continue implementation of MediaPlayer object

Add CMediaPlayer.c for the various hooks.
Start implementing Play::SetPlayState for MediaPlayer.
CheckDataSource and Sink now takes a mask of allowed data locator types.
Data source and sink error logs now include the name of the source or sink.

Change-Id: I3702c977dd367a788ce78575e1e2891dafd2c983
andbox/xa.c
aa2fafdac2711436e5fd8faf162d7087a515cb1c 02-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> StreamPlayer::onPrepare() should synchronously prepare its player

Change-Id: If8ec63e8b93dea2e1810046e05e692755e6a8887
StreamPlayer::onPrepare() should only return when its media player
is done preparing, so other player commands are processed from
the message queue when the player is ready to receive them.
andbox/streamSource/slesTestPlayStream.cpp
cb417262919560a715628f4317dc8a4de386f750 02-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> Asynchronous prepare() on StreamPlayer

Prepare the StreamPlayer object asynchronously.
Fixes the deadlock issue between the SLAndroidBufferQueue callback
registration and Enqueue() functions.

Change-Id: I76963233f658946db87d0aab6f225bc9e7c8210a
andbox/streamSource/slesTestPlayStream.cpp
be59fc5cfd9354d70d4b0e28bb2bca24a6ca6f22 01-Dec-2010 Jean-Michel Trivi <jmtrivi@google.com> More support for SLAndroidBufferQueueItf

Implement Enqueue()
Store "caller" interface to use in the AndroidBufferQueue
callback.
Update test app in sandbox to use the callback to read
from a file and enqueue buffers directly.

Change-Id: I68413731d311532b08f8f13577e3ca81c033fcd4
andbox/streamSource/slesTestPlayStream.cpp
8b8875067dd02b79361abb00c5d65b02a8ae72b0 01-Dec-2010 Glenn Kasten <gkasten@google.com> Start implementing CreateMediaPlayer

Add CMediaPlayer class.
Add IEngine_CreateMediaPlayer handler.
Add OpenMAX AL native display data locator and raw image data format.
Add OpenMAX AL I/O devices: camera and radio.

Change-Id: Ie99c09110ac9fdcd98bf0bfc487c6e3fcde58f19
andbox/xa.c
fa62f9f2c20b446178c05e3e92407fe5dfdbf8a1 30-Nov-2010 Jean-Michel Trivi <jmtrivi@google.com> Support for the SLAndroidBufferQueueItf interface

Rename AndroidStreamSource to AndroidBufferQueue.
Add prototype for SLAndroidBufferQueue functions.
Update sandbox test app to use the new interface.

Change-Id: Ib82180c22e5cf0dd982b4a9bb132667cd2ac4dd7
andbox/streamSource/slesTestPlayStream.cpp
8db0b106cdce5f5216b1535492de7930ad738aed 29-Nov-2010 Glenn Kasten <gkasten@google.com> Continued work on OpenMAX AL engine APIs

Added xaCreateEngine as synonym for slCreateEngine,
but not yet reference counted to share same object with slCreateEngine.
Added the beginnings of a XA_IID_ENGINE engine interface
but still needs more work.
Added simple xa test app.
New extension: ANDROID_SDK_LEVEL_10 (not NDK per digit).
Split up sles.c:
- Move data source, sink, locator, format code to data.c
- Move global entry points to entry.c
- Collect all engine-related code into CEngine.c
- Collect all device-related code into devices.c

Change-Id: I9fdeed1e29f698869f409014a39401999ac84e5f
andbox/Android.mk
andbox/xa.c
26043f06b7d6cb2f93a2f2e7846a4e59da722206 23-Nov-2010 Jean-Michel Trivi <jmtrivi@google.com> Control MediaPlayer instance from SL ES interfaces

Implement transport control on StreamPlayer.
Store the StreamPlayer in CAudioPlayer as an sp<>
In StreamPlayer: create a media player from the
mediaplayerservice, and implement the IStreamSource
interface to get data fromt the application
callback.
Note that the SLDataLocator_AndroidStreamer and
SLAndroidStreamSourceItf are very much in flux
at the moment.

Change-Id: I11035aafcefd59aad99d1fec9fd54a622e6d1e0f
andbox/streamSource/slesTestPlayStream.cpp
b0ab2dee391dd2cb257faeaba252ee6ecccc5f03 08-Nov-2010 Glenn Kasten <gkasten@google.com> Prepare for merged OpenMAX AL and OpenSL ES engine

Field mEngine is now a reference to CEngine instead of IEngine.
Restore Android.mk.
Move mThreadPool, mEqPresetNames, mEqNumPresets from IEngine to CEngine.
IEngineCapabilities_QueryLEDCapabilities and
IEngineCapabilities_QueryVibraCapabilities are now non-static
so that they can be shared by OpenMAX AL's IEngine.
IEngineCapabilities is now required in the build, used by OpenMAX AL IEngine.
The default MPH tables now depend on USE_DESIGNATED_INITIALIZER,
and generate tables for other C compilers programmatically.
Updated comments in MPH.h.
Removed conditionals from MPH_to.c so that non-GNU tables can be built more easily.
Make the interface ID hash generator less specific about hashing algorithm.
Re-build interface ID hash tables.
Update IID_to_MPH.c based on hashgen.
Add generated MPH_to_*.h.
Remove Android dependency.

Change-Id: Icdf89eedc825f9e52bc264b22d923ae157244ed3
andbox/multithread.c
ad887a253969ac2017a1dbe062d0b76d505594c0 20-Nov-2010 Jean-Michel Trivi <jmtrivi@google.com> Set the MediaPlayer data source from a SL_DATALOCATOR_ANDROIDSTREAMER

Use the data locator information to initialize the data source
of the MediaPlayer instance used in the StreamPlayer object.
Register the callback only when the player is stopped.
Added callback events that can be passed from the application
to the implementation to synchronously signal events.

Change-Id: I1fc52d8d46b2bcf8ca11ab0e4d44d40e704ddbfc
andbox/streamSource/slesTestPlayStream.cpp
fe6f6b9ed3683119721618e1aeaa8c7d6baee188 19-Nov-2010 Jean-Michel Trivi <jmtrivi@google.com> More support for SL_DATALOCATOR_ANDROIDSTREAM

- add test app in sandbox: based on playUri with different data
locator
- new object, StreamPlayer, that will encapsulate the life-cycle
of the new MediaPlayer object that implements the streaming.

Change-Id: Idfdb00e8622ff18d131465d11178979232ee04f8
andbox/streamSource/Android.mk
andbox/streamSource/slesTestPlayStream.cpp
0a058cc3d720cdf3f0f8222472a862258482f34f 18-Oct-2010 Glenn Kasten <gkasten@google.com> Bug 3102561 - Tests only

Make the multi-thread test more stressful, to crash more often.
New tests: playbq, srcsink, monkey.
In monkey, re-enable destroy at difficult times.
Add support for testing player insert reverb to the reverb test.
Note: building playbq is disabled by default because it needs libsndfile.

Change-Id: I592ea5f567bddc61174e7d41bc5b36ce32d2b6b8
andbox/Android.mk
andbox/intbufq.c
andbox/monkey.c
andbox/multiplay.c
andbox/multithread.c
andbox/playbq.c
andbox/reverb.c
andbox/srcsink.c
7126c25d7c037e5086216cf540ecf40779c3585a 13-Oct-2010 Glenn Kasten <gkasten@google.com> Bug 3102561 - Tests and examples only

Note: the modifications in directory libopensles aid testing,
but have no affect on production builds because they are related
to tracing, which is is disabled by default.

Update feedback test to be more reliable.
Update slesTestPlayUri to exit on prefetch error.
Clean up error and termination handling.
Add comment to record test on how to use it.
Reduce global symbol dependencies when trace is enabled.
Split OpenSLESUT into two files: part that uses printf, and another part that doesn't.
Add SL_RESULT_ prefix to result strings.
slesutResultToString returns NULL for unknown value.
Add multithread torture test.
Compile stream test for non-Android as a no-op.
Improve API test coverage.
Enable assertion checks on test programs.

Change-Id: I6b82026cfa19d2f08cda4c11137e0706e8ff4b8c
utomated/BufferQueue_test.cpp
xamples/Android.mk
xamples/slesTestEffectCapabilities.cpp
xamples/slesTestFeedback.cpp
xamples/slesTestRecBuffQueue.cpp
imeUri/slesTestPlayStreamType.cpp
imeUri/slesTestPlayUri.cpp
andbox/Android.mk
andbox/engine.c
andbox/multithread.c
andbox/object.c
andbox/outputmix.c
61c8274a30ba403191b05d556d063fa5f309ea95 15-Oct-2010 Glenn Kasten <gkasten@google.com> Bug 3102561 - Clean up reverb test

Change-Id: If573c06134810eafd4d41efeb938fa23ae77c2da
andbox/reverb.c
f536948a85be5e3f3731b64b01cfacdf90ed1157 12-Oct-2010 Jean-Michel Trivi <jmtrivi@google.com> Notify when prefetching fails

There is no event in the SLPrefetchStatus event callback in
OpenSL ES 1.0 to indicate a prefetch error. So we signal it by
sending simulataneously two events:
- SL_PREFETCHEVENT_FILLLEVELCHANGE with a level of 0
- SL_PREFETCHEVENT_STATUSCHANGE with a status of
SL_PREFETCHSTATUS_UNDERFLOW

Change-Id: I399ea3474e6cc7796c940401306ca9a076fac4e2
imeUri/slesTestPlayUri.cpp
e629abc58c2acadc7487ea71c1e063f8f8989199 11-Oct-2010 Glenn Kasten <gkasten@google.com> Fix build warnings

Change-Id: I449da85b97901a632591dd16a52cb924a2722883
istening/seekTorture.c
andbox/getch.c
andbox/intbufq.c
andbox/reverb.c
andbox/urimime.c
c2303eb5497c488db786dcb2b8514db229452536 11-Oct-2010 Glenn Kasten <gkasten@google.com> Test cleanup

Fix bug in QueryEffect test - was not re-initializing the name length.
Add QueryEffect test for over-writing the name buffer.
Don't create output with VOLUME or NULL interfaces.
Use <stdlib.h> symbolic names for exit codes instead of 0 and 1.
Remove Android-style logging from examples; use only printf.
Remove extra blank lines in test output.
Remove the MAX_NUMBER_OUTPUT_DEVICES macro.
Use <unistd.h> to declare usleep.
Remove obsolete #include statements.
Fix build warnings.

Change-Id: I8d198a317246b3894f104edf7c9f317a51593d07
xamples/slesTestBassBoostPath.cpp
xamples/slesTestEffectCapabilities.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestPlayFdPath.cpp
xamples/slesTestRecBuffQueue.cpp
xamples/slesTestSawtoothBufferQueue.cpp
xamples/slesTestSendToPresetReverb.cpp
xamples/slesTestVirtualizerPath.cpp
istening/slesTest_playMuteSolo.cpp
imeUri/Android.mk
imeUri/slesTestLoopUri.cpp
imeUri/slesTestPlayStreamType.cpp
imeUri/slesTestPlayUri.cpp
imeUri/slesTestPlayUri2.cpp
imeUri/slesTestSlowDownUri.cpp
imeUri/slesTest_playStates.cpp
imeUri_test.cpp
andbox/configbq.c
andbox/multiplay.c
andbox/reverb.c
andbox/urimime.c
711332800108ad6e0e594796e5f8db0da3eff402 07-Oct-2010 Glenn Kasten <gkasten@google.com> More tests and bug fixes

New tests:
- urimime.c tests audio player with URI data source and MIME data format
- dim.c tests DynamicInterfaceManagement
- engine.c new test cases:
- create more than one engine simultaneously
- exit application without destroying engine first

Bug fixes:
- Can't request SLBufferQueueItf or its alias SLAndroidSimpleBufferQueueItf
if the data source is not a buffer queue.
- BufferQueue interface is explicit on AudioPlayer.
- OutputMixExt is unavailable (internal) on AudioPlayer.
- There was a nested mutex lock when resuming a non-suspended interface.
- This implementation supports at most one engine, so check for that
- Class configuration table had wrong entry for DynamicInterfaceManagement
on 4 of 10 classes.

Restore most of the infrastructure for removing interfaces (code review):
- DynamicInterfaceManagement is included, but body of RemoveInterface is compiled
out, and replaced by FEATURE_UNSUPPORTED until all our deinit hooks are clean.
- Remove hook must be called with mutex locked, rather than unlocked as before.
The remove hook is called during IDynamicInterfaceManagement::RemoveInterface
and Object::Destroy, so the entry conditions must be the same.
- Add NULL remove hooks to the interface hook table.

Change-Id: I328dd254ed24a32b220996a6d9592cc8c0f4e943
Miscellaneous:
- Always memset object to garbage in Object::Destroy to catch broken applications.
- Add comments about how GetInterface manipulates the v-table pointer (code review).
- Re-enable DynamicInterfaceManagement for testing the example code.
andbox/Android.mk
andbox/dim.c
andbox/engine.c
andbox/urimime.c
104c000a6f36b871ca11e0394db1e5217f374caf 06-Oct-2010 Glenn Kasten <gkasten@google.com> Interface testing and bug fixes

Add some new tests, and fix the bugs they found.

New and improved tests:
Added output mix API test with focus on interfaces.
Add mute solo and seek test cases to the automated buffer queue test.
Buffer queue configuration test is now listenable:
Buffer queue configuration test now generates a sequence of sine
waves in order so that the listener can tell if each format is
supported correctly.

Bug fixes:
Engine::Create... was not checking if the interface was available
for a particular class. Fixing that bug showed some other bugs
in the class/interface configuration tables.
The effects interfaces is available on an output mix.
The Volume interface is not available on an output mix.
The Object interface can do GetInterface before realized.
OutputMix interface is available on an OutputMix;
needed by the demos/examples in back of book
OutputMix::ReRoute fails if number of output device IDs is not 1.
Improve interface checks on a buffer queue source.
Don't allow mute solo interface on a mono buffer queue.
The earlier code to check for seek interface on a buffer queue
compared by address, which didn't work if application
used a private copy of the GUID. Now compares using the
MPH which will work in all cases.
Buffer queue, effect send, and mute solo are explicit interfaces on audio player.
slCreateEngine was not publishing the engine object.

Miscellaneous cleanup:
Removed the hard-coded fake device ID constants in
OutputMix::ReRoute that were there just for testing.
In Engine::Create..., log an error for all unsupported interfaces, not just the first one.
Make hash generator build again:
It turns out interfaces.c is needed, even though it duplicates
OpenSLESUT.c. Restore from 1a6bb4f8e738c9387dc9629db294ea5de618a53c.
Remove some redundant comments.

Change-Id: Iddabe73e298b69a44f3b43ed224c918eb95961a1
utomated/BufferQueue_test.cpp
andbox/Android.mk
andbox/configbq.c
andbox/outputmix.c
9e60b0a390d780539459f41c2bf4a45a326a7b62 30-Sep-2010 Glenn Kasten <gkasten@google.com> Add new test, fix bugs found by test & code review

Bugs:
- EnvironmentalReverb::GetEnvironmentalReverbProperties left mutex
unlocked at end.
- buffer queue configuration test revealed not checking enough
combinations
- would have failed conformance test in a couple places
- replace peek locks by shared locks for SMP
- undocumented symbols were being exported by library
- fix handling of EffectSend for MIDI player

New test:
- Add reverb test

Miscellaneous:
- Move some FIXME to to-do list where they are easier to organize
- Fix typos in name of profile constant
- EffectSend::IsEnabled sets enabled = false for unsupported aux effect.
- Add curlies to if statements.
- Add more error logging.
- Fix indentation in switch statement.
- Add comments to makefile.

Details:
- Reduce visibility of libOpenSLESUT symbols.
- Use LOCAL_STATIC_LIBRARIES := libOpenSLESUT where needed in
applications.
- Move FIXME for OEM configuration, interface, SDL, Sndfile,
buffer queue, destroy to to-do list
- For SDL, disallow buffer queue with source not 44.1 kHz because it
is hard-wired to 44.1 kHz and there is no sample rate converter.
- return successful result for enabled effect send on unsupported
MIDI player
for future conformance testing

Change-Id: I39cb543169996f78c16e3ac363ea6157a9242743
andbox/Android.mk
andbox/reverb.c
5f34a9086031b9bd3affd54463c82f7f66a97e02 30-Sep-2010 Glenn Kasten <gkasten@google.com> Merge "Add buffer queue configuration test" into gingerbread
df30c8bcac7de55c9d9f7e4cde7aac24158d8941 30-Sep-2010 Glenn Kasten <gkasten@google.com> Add buffer queue configuration test

Add comments to makefile for each test

Change-Id: I8741d93e7aadb02c4b75e3a0a7a81d593dfa7f97
andbox/Android.mk
andbox/configbq.c
8a1b7f28c1c3de212a302182022310ab7b227788 30-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Lock tweak between interface and object

When locking the interface for the prefetch status, lock the
object instead of the prefetch interface, as it updates
the android object state.

Fix the playState test app.

Change-Id: Ib4e0e99a4cf0720e2b7ebd920fe92f69377f19d9
imeUri/slesTest_playStates.cpp
24430c9070298f12e68b84c921add38da6ad0490 29-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix issues with SLPlaybackRateItf interface

Set rate was not applied when the AudioTrack is created after
prepare completed.
Modified playback rate functions in AudioPlayer to pass a
CAudioPlayer pointer, rather than a pointer to IPlaybackRate
so the rate update function can be queried from the CAudioPlayer.
Added test that exercises the SLPlaybackRateItf interface as
well as content looping.
Simplified evaluation of delay between decode and render to
use a fixed (small) delay that balances time to run the
event looper, and prevents clicks.

Change-Id: I598e9a96e93ef7a7c3603c8467f9d6b36dacd26d
imeUri/Android.mk
imeUri/slesTestSlowDownUri.cpp
c0d58ae8d307d2fc44ae36cba0b4956d0973e2a3 29-Sep-2010 Glenn Kasten <gkasten@google.com> Merge "Add MuteSolo checks for audio player and fix bugs" into gingerbread
f6f5ceb363286d5ebef2c2e70c8a5aa135d5d1ee 28-Sep-2010 Glenn Kasten <gkasten@google.com> Add MuteSolo checks for audio player and fix bugs

The specification says "This [SLMuteSoloItf] interface cannot be
exposed on a player whose audio format is mono." This has a lot of
implications ...

Deny an explicit interface request for SLMuteSoloItf at audio player
creation time if the player is known pre-realize to have mono channel
count (e.g. PCM buffer queue).

Deny a GetInterface on MuteSolo if channel count is known to be mono,
but allow it if the channel count is still unknown.

When DynamicSource (or its replacement) is implemented, it will be
possible for the application to have done a GetInterface successfully,
and then to change the source such that the MuteSolo interface is
no longer valid. In that case, return SL_RESULT_FEATURE_UNSUPPORTED
for most MuteSolo operations, if called when channel count is unknown
or is mono. We _do_ allow MuteSolo::GetChannelCount to succeed if
channel count is known to be mono.

Enhance the URI-based mute solo test to check some of the above,
and the interactive buffer queue test to get and test the channel count.

Add curly braces to if statements.

Other bug fixes:
- Do not rely on peek locks; they don't work on SMP.
- Channel count and sample rate were not being set correctly
for buffer queue data source audio players.
- CreateAudioPlayer and AudioRecorder were both referring to
application pointers more than once, with the possibility of
reading inconsistent data.

Change-Id: Ie0109cbddc0aff8a56c0b53d989fb2be823e627b
istening/slesTest_playMuteSolo.cpp
andbox/intbufq.c
83046edf745416ed68bd258f43ecf202eb6b2131 28-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Merge "Fix bug 3004701 do not prefetch during Realize." into gingerbread
3ddf7a34cc617e52a9b9a5593a0d1c5ef8d22bd9 28-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix bug 3004701 do not prefetch during Realize.

Removed unused Android object states in enum, not used in
play state machine.
Made SfPlayer responsible for the creation of its
AudioTrack once it knows the sample rate and number of
channels of the content to play once it's done
preparing.
Added notification from SfPlayer to signal when it's
done preparing. This informs of the audio characteristics
and kicks off the content prefetching.
In the AudioPlayer realize:
- do not start the prefetching, do it when the player
is set to PAUSED
- don not create the AudioTrack, do it when SfPlayer
is done preparing.

Change-Id: Ic345040e71cef0e5953ea47366930d1dfbc5e761
imeUri/Android.mk
c2b9d79c4b59caff965076f445f5a735a360b084 28-Sep-2010 Glenn Kasten <gkasten@google.com> Enable and test more interface ID queries

Enable Engine::IEngine_QueryNumSupportedInterfaces and
Engine::QuerySupportedInterfaces.
Add object ID test.
Return SL_RESULT_FEATURE_UNSUPPORTED from Engine::Create... if the
corresponding class is not configured..
Add slesutObjectIDToString to utility toolkit.

Change-Id: I28b8beff71d65e7eccd558e586652bb606c89848
andbox/Android.mk
andbox/object.c
1d8ab068ca8a72771514b443b42003ca06623d5e 28-Sep-2010 Glenn Kasten <gkasten@google.com> Add engine interface test

Change-Id: I5c1fd1e8ab6dc050f416f28708e3ef218910cd8d
andbox/Android.mk
andbox/engine.c
f9f752208f2521f92389f17592ffe335ccfb65eb 27-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Merge "Support content looping for URI and FD data sources." into gingerbread
d94d32190f845b41f212c9c1918758e33fef6382 26-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Support content looping for URI and FD data sources.

Implement SetLoop() on AudioPlayer with URI and FD
data sources. Only looping over the whole duration
of the audio content is supported here.

Change-Id: Ic033f61063e57c3a9f8c51bad15852a42b21ab46
imeUri/Android.mk
imeUri/slesTestLoopUri.cpp
3e5c4d36074ffd81c468bb9e9d5a15564e6e99aa 26-Sep-2010 Glenn Kasten <gkasten@google.com> Restore the 2 unmerged equalizer tests

Change-Id: I667cfdddd34fff7017fedab9ee84e954c1c9f690
xamples/Android.mk
xamples/Android.mk_
xamples/slesTestEqOutputPath.cpp
ff037a1f697a15fb4249e62fe783f22398572cbe 21-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Implement buffer cache fill level and status notification.

OpenSL ES requires the notification of buffering status
changes and caching fill level updates. Fill level
updates happen only when the level has changed by
a certain amount.

Change-Id: I8b5e82ac1dfff35d7a27eda0dd1f395311d554f3
imeUri/slesTestPlayUri.cpp
a4106829c36285cac8f39b6bedb7f8c0d60a7e4e 26-Sep-2010 Glenn Kasten <gkasten@google.com> Temporary fix for broken build

Change-Id: I1b02cbe6ce22766ccbab4e8bf040418eba69d6fc
xamples/Android.mk
xamples/Android.mk_
5e3b06982dbf1eae237cc74326e66d51d3cdd664 26-Sep-2010 Glenn Kasten <gkasten@google.com> Replace one configuration hack by another

Previous hack allowed an application to call GetInterface for any
interface prior to Realize. The new hack allows an application
to do so only for interfaces which have a "pre-realize OK"
relationship to their associated class. Currently this is
SL_IID_ANDROIDCONFIGURATION.
Reduce logging in record test.
Allow default tracing level to be set in makefile.
Line length 100.

Change-Id: Id17c55ee7284dca108e0eab379a8f987963fd8c4
xamples/slesTestEqOutputPath.cpp
xamples/slesTestRecBuffQueue.cpp
04c7354b8a9afcf2151c00c1dfbc64d0ba5d33cc 24-Sep-2010 Glenn Kasten <gkasten@google.com> Fix problems found during testing

Fix crash in android_audioPlayer_destroy if audio player is only partially
constructed, e.g. when using a buffer queue source and the buffer count
is invalid etc.
Add temporary workaround to buffer queue automated test to be quieter if
hardware volume control is not working.
Make the record test less noisy on console.

Change-Id: Ief255c3f5f3c94c990f589b2373686b2ac526dd3
utomated/BufferQueue_test.cpp
xamples/slesTestRecBuffQueue.cpp
43ad61e9e61b332f7d9f2b991954fcac4c11d691 23-Sep-2010 Glenn Kasten <gkasten@google.com> Fix bug found by BufferQueue automated test

Fix bug for destroying partially constructed audio player.
Remove obsolete logging.

Change-Id: Ib186153bf50ed1311c021d53711ec90d000bdee2
utomated/BufferQueue_test.cpp
01e9f5fa4698856f92bcfd88188ee4c8397b22db 22-Sep-2010 Glenn Kasten <gkasten@google.com> Android simple buffer queue locator and interface

Bug fixes:
Fix bug in error handling and recovery for checkDataSource - potential memory leak.
Clean up MPH table; there were some missing and uncommented entries.

Testing:
Add comments about using the END macro to test the MPH table.
Convert feedback test from buffer queue to Android simplified
buffer queue for rx side only, tx is still 1.0.1 buffer queue.
Add option to sample/intbufq test to use build option to decide
whether to use 1.0.1 buffer queue or Andorid simple buffer queue.
Convert record test for new APIs.

Miscellaneous:
Update hashgen table and add an install rule.
Add comments.
Add more logging.
Line length 100.
Fix build warning.
Double indent.
Fix SL_DATALOCATOR value for FD.

Change-Id: I35cce8934157fed88251e846b1beb15523b2b1a6
xamples/slesTestEffectCapabilities.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestFeedback.cpp
xamples/slesTestRecBuffQueue.cpp
xamples/slesTestVirtualizerPath.cpp
istening/slesTest_playMuteSolo.cpp
imeUri/slesTestPlayStreamType.cpp
imeUri/slesTestPlayUri.cpp
andbox/intbufq.c
93a283eaea47af6f4c97a22f49ed02a115b01dd8 22-Sep-2010 Glenn Kasten <gkasten@google.com> Add explicit dependency to utility library.

Change-Id: I3a85b071b355ac9e0c330a71e6457cb01b665af0
utomated/Android.mk
2e2d97d82283c7048db0fe1876708aee1badc423 22-Sep-2010 Glenn Kasten <gkasten@google.com> Quick fix for build break, real fix to follow

Change-Id: Ib8542a689a0287fe19cd74b14eceb6b4a8b6afeb
utomated/Android.mk
453dd564a81fe98b7a947ae4a9844a53fa957c2b 18-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Remove the SLAndroidStreamTypeItf interface.

It is now replaced by SLAndroidConfigurationItf which implements
the same functionality (and more).

Modified test to demo setting AudioPlayer stream type to use
SLAndroidConfigurationItf

Modified SLAndroidConfigurationItf to enable passing a
NULL pointer to value so the value size for the key ca
be queried.

Fixed type in AudioPlayer and AudioRecorder Android side
which reported an error if the SetConfig() function was
called when the object was unrealized (the intent is
to check that the object is NOT realized because we
are configuring the resources the object is going to use).

Change-Id: I20f3dba8c63066db94d537109854b4c4139f65b3
imeUri/Android.mk
imeUri/slesTestPlayStreamType.cpp
719dfe48a4ffa7d26dc2652b92bf4b9c4a186619 18-Sep-2010 Yu Shan Emily Lau <yslau@google.com> Turn on the opensl samples.

Change-Id: I0ca645fe506e8690d960bf113472a400cd422ea3
xamples/Android.mk
xamples/Android.mk_
9bc234ed758273259e334144cc6e1643b2494175 17-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Add example for SLRecordItf callback registration and use.

Change-Id: Ibcd27f5a49a42ddbcd313b30e7b07b1ce4f13705
xamples/slesTestRecBuffQueue.cpp
43e7743b5297cc5afcb246a7e2b5d825a607f8af 15-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix bug where OutputMix is not fully initialized by CreateOutputMix()

In the implementation of SLEngineItf, CreateOutputMix() didn't call
android_outputMix_create() which initializes the mEffects pointers.
Added checks on SfPlayer in case an application start calling
interface functions when Realize() on an AudioPlayer isn't done.

Change-Id: Id3fb9f02b5c29a1d87255e7935542ebcf4b8dd46
imeUri/slesTestPlayUri.cpp
b3e52a63baaea367cf411348b68ecd8fd429b029 14-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Implement SLAndroidConfigurationItf on AudioRecorder.

Enable the use of the configuration interface before the
AudioRecorder object is realized to set the recording
preset. Recording presets map to the Android
AudioRecord input source.

Change-Id: I804095a0b39e4676862f6bc8e7fbaa0ba63b9336
xamples/Android.mk_
xamples/slesTestRecBuffQueue.cpp
00667fcca51d62236b538e6857b7e6b923453569 09-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix aux reverb issues:

- when creating an effect, only pass the effect type to the
AudioEffect framework so it selects whether to use an insert
or aux effect based on the session.
- SL ES aux reverb effects don't have an explicit SetEnabled()
function, so enable the effect upon creation, or based on the
preset for the preset reverb effect.

Add a test for SLEffectSend.

Change-Id: I683331cac19cf1fb9628d636569ab3d342c02820
xamples/Android.mk_
xamples/slesTestBassBoostPath.cpp
xamples/slesTestSendToPresetReverb.cpp
60d41cc12c14843454404d0183739e8f0569ad92 09-Sep-2010 Yu Shan Emily Lau <yslau@google.com> Fixed the make file which it can build all the sub-dir.
Remove the samples temporary until it's fixed.

Change-Id: I6dd9b15a16c3dcc22ecee1fd1acecaebbd59262f
ndroid.mk
xamples/Android.mk
xamples/Android.mk_
23cdb9057c15ec9e0f9f1c63d6b80af84691c597 08-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Cleanup SLAndroidEffectCapabilitiesItf example.

Change-Id: I3b73d089fde7f8ada5387f6e030869356a918b4a
xamples/slesTestEffectCapabilities.cpp
5b09aa864215690580b18eb802927e8cc7eb4861 03-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Implement SLAndroidEffectItf and SLAndroidEffectCapabilities.

Change-Id: Ia2cf6e3f0178189b0ed010690bc9906b61a746a7
xamples/Android.mk
xamples/slesTestEffectCapabilities.cpp
cb5ef4dc25d2f526898d12f008d551877347b9b8 03-Sep-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix OpenSL ES effect test durations based on audio file duration.
Fix make file to build the EQ test.

Change-Id: I509d1f0cea775c4f955c8c23fc27ba313995dd5b
xamples/Android.mk
xamples/slesTestBassBoostPath.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestVirtualizerPath.cpp
91bfd060b992810ca092f640f77f795bc3d008be 01-Sep-2010 Glenn Kasten <gkasten@google.com> Improve test app portability for other platforms

Change-Id: I8793b7e6f6ebd0f83ff8e5bd534234cd1f4166a2
xamples/Android.mk
xamples/slesTestBassBoostPath.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestVirtualizerPath.cpp
imeUri/slesTestPlayStreamType.cpp
d48ff338b8338c1e3e54e0f9dcd03567a0aa9de4 01-Sep-2010 Glenn Kasten <gkasten@google.com> Verify that no extant objects at engine shutdown

Log the total count and ID numbers of any stragglers.
Fix the order of steps in engine shutdown.
Add more comments.

Change-Id: I12b531bcd43c288f9988768193274bad6984748a
utomated/BufferQueue_test.cpp
527b7d2e606abdbde0e29fe75f7e9a67285629d2 01-Sep-2010 Glenn Kasten <gkasten@google.com> Use standard filenames for tests.

Change-Id: I0bfc8bd98f00ce1dd9d7e36d402d4cd422cb8ea6
xamples/Android.mk
xamples/bufferQueue.c
xamples/feedback.c
xamples/playSawtoothBufferQueue.cpp
xamples/slesTestFeedback.cpp
xamples/slesTestSawtoothBufferQueue.cpp
8c065779232fdd89abace68d2fc7bea786a010d7 31-Aug-2010 Glenn Kasten <gkasten@google.com> Fix problems found by the mute solo test.

Bug fixes for USE_OUTPUTMIXEXT (desktop):
- SL_PLAYEVENT_HEADATNEWPOS was broken
- GetPosition is now accurate, with or without seeking
- Fix race condition between AudioPlayer and Track
- Duration is updated if initial estimate is too low (e.g. if unknown is reported as zero)
- GetPosition while pending Seek now returns that value so the Seek appears synchronous
- Remove useless code to retry Enqueues; now drop decoded data if Enqueue fails
For all source files touched, add curlies to the "if" statements.

Change-Id: I1f70d8e683bc92831848af20857347d45c6407a9
istening/slesTest_playMuteSolo.cpp
7e01bc6208fb5b4a2a0019d67bf74373f8ee9428 30-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Add support for auxiliary effects.

- Implement the OutputMix object.

- Modify the interface of the Android effect initialization since
an effect can be attached to a player (insert) or to an OuputMix
(aux)
- fix bug in EQ where SL_RESULT_CONTROL_LOST was returned on a
properly initialized EQ effect.

- Add a test application which creates an EQ on an OutputMix
- Remove unused constant in test apps.

Change-Id: Id9e4633d0e44e8a784f1154ce1a6df1357b72966
xamples/Android.mk
xamples/slesTestEqFdPath.cpp
xamples/slesTestEqOutputPath.cpp
xamples/slesTestVirtualizerPath.cpp
b12deb54e78a45a8cfe380da7c047ec9ac3fe5d8 28-Aug-2010 Glenn Kasten <gkasten@google.com> Buffer queue automated test update

Make it run on desktop as well as Android, so we can use desktop driver
for comparison, and get test coverage using gcov.
Use slesutResultToString for error reporting.
Run each test case for all valid numbers of buffers.

Change-Id: If7753a0e77f4a906a41eae90135e1bc84531f2fc
utomated/BufferQueue_test.cpp
cfe5b1c6f0b65499d9aed2cf4b2a7e805fb02758 27-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Implement the SLVirtualizerItf interface.

Add example for the SLVirtualizerItf.

Unify how an effect interface checks whether a valid effect is
attached to the interface.

In implementation of SLEqualizerItf, ensure the effect is accessed
only if its valid (just like for BassBoost and Virtualizer).

Change-Id: I03032de2925488bc78502f23a83972e666435a8b
xamples/Android.mk
xamples/slesTestBassBoostPath.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestVirtualizerPath.cpp
4597a7427b697df31d0bbf4c2040806d0c27b6e0 26-Aug-2010 Glenn Kasten <gkasten@google.com> Fix bugs in BufferQueue automated test and related

Fix test bugs:
Clean up the player, mixer, and the engine (must be done in that order).
Re-enable 2 more tests; all 9 tests pass now.

Fix engine bugs:
IObject now has a de-init hook, which cleans up condition variable and mutex.
Run the de-initializers in reverse order so that IObject de-init hook is run last.
Replace the dedicated mEngine.mShutdownCond by the shared IObject condition variable.
Forgot to iniitalize mShtudownAck.
Unlocking the object mutex during CEngine_Destroy was bogus.

Miscellaneous logging and debugging improvements:
Track the source code location of the most recent mutex unlock.
Add more trace log options for detailed leave reasons.
Improve performance of trace log when disabled.
Turn on assert checking.
Check return value of pthread_cond_destroy and pthread_mutex_destroy.
Add comment.
Line length 100.

Change-Id: I23b7b495d439894b2fd31295a38cb73ef7b6be2e
utomated/BufferQueue_test.cpp
4f064c143ef2b26347130a49788116b5d2e1252a 25-Aug-2010 Glenn Kasten <gkasten@google.com> Fix bug in BufferQueue::Clear

BufferQueue::Clear must clear playIndex also -- see pg 423 section 9.1.5.
Only print a lock error message if delayed 100 ms.
Object lock debugging did not take into account that cond_wait also releases the lock.
Improve error reporting for recursive locks.
Reduce the noisy output of sawtooth test.

Change-Id: I66a959445de7e0763440e22251465c796bb1883b
xamples/bufferQueue.c
9cd3c9e7a2395647b92c32f33c06cf9fd546b22f 24-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Implement the SLBassBoostItf on an AudioPlayer
Prevent the SLEqualizerItf to use an EQ effect that wasn't
successfully initialized.

Change-Id: I4cdb07fc4deebba1cb591f0ca96fc3f494e37080
xamples/Android.mk
xamples/slesTestBassBoostPath.cpp
fe96fa06360516c60490c7a697e1148017b4c1b2 23-Aug-2010 Glenn Kasten <gkasten@google.com> Fix bug with nested lock.

Add object lock debugging.
Replace !NDEBUG by USE_DEBUG.
Remove $(JNI_H_INCLUDE) and $(TOP).

Change-Id: I61217b82a7edc42d37dacf443ad0ca852ee0dfe9
ndroid.mk
utomated/Android.mk
xamples/Android.mk
istening/Android.mk
imeUri/Android.mk
andbox/Android.mk
4c71179974933c5c36cbfc3e8227c8df63248d91 21-Aug-2010 Glenn Kasten <gkasten@google.com> Test reorganization

Change-Id: I0fb84afd72fe6839773937fdaece3276bba1b952
pi/Android.mk
pi/BufferQueue_test.cpp
utomated/Android.mk
utomated/BufferQueue_test.cpp
ffects/eqFdPath/Android.mk
ffects/eqFdPath/slesTestEqFdPath.cpp
xamples/Android.mk
xamples/bufferQueue.c
xamples/feedback.c
xamples/playSawtoothBufferQueue.cpp
xamples/slesTestEqFdPath.cpp
xamples/slesTestPlayFdPath.cpp
xamples/slesTestRecBuffQueue.cpp
istening/Android.mk
istening/seekTorture.c
istening/slesTest_playMuteSolo.cpp
imeFd/playFdPath/Android.mk
imeFd/playFdPath/slesTestPlayFdPath.cpp
imeUri/Android.mk
imeUri/multiplay.c
imeUri/seekTorture.c
imeUri/slesTest_playMuteSolo.cpp
cmBufferQueue/intbufq/Android.mk
cmBufferQueue/intbufq/getch.c
cmBufferQueue/intbufq/intbufq.c
cmBufferQueue/loop/Android.mk
cmBufferQueue/loop/loop.c
cmBufferQueue/sawtoothBufferQueue/Android.mk
cmBufferQueue/sawtoothBufferQueue/bufferQueue.c
cmBufferQueue/sawtoothBufferQueue/playSawtoothBufferQueue.cpp
ecorder/recBuffQueue/Android.mk
ecorder/recBuffQueue/slesTestRecBuffQueue.cpp
andbox/Android.mk
andbox/getch.c
andbox/intbufq.c
andbox/multiplay.c
f5fce95f98037ea4ab341b416c82444af595313d 21-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Exercise more functions of the SLEqualizerItf interface.
Refactor EQ effect descriptor initialization in an effect neutral
function so it can be reused for other effects.

Change-Id: I72d71f7e05f19f0be3541440c1f67269c179b5cc
ffects/eqFdPath/slesTestEqFdPath.cpp
bea5fc020e8453472b25a8456a0b40d7a361e411 17-Aug-2010 Yu Shan Emily Lau <yslau@google.com> Merge "Re-org the bufferQueue unit tests." into gingerbread
3b2a7f6713db24c529a117a67aaabbc676678748 17-Aug-2010 Yu Shan Emily Lau <yslau@google.com> Re-org the bufferQueue unit tests.

Change-Id: I55d63ca25e98a6b89634c9ec496a07dacb9c71b6
pi/Android.mk
pi/Android.mk_
pi/BufferQueue_test.cpp
5940f26b6c2da96c0f0b2293623ed692d1fd9026 17-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix the MimeUri test:
- some logs were reported as errors
- the SLPrefetchItf was declared as required, but not requested in
the creation of the AudioPlayer.

Change-Id: I33f07ec532ef1d8151aa1bda4f7cfa4d3e64c8ec
imeUri_test.cpp
a05622c974763d8ca038f3d39743c926309ab2c2 16-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Support SLPrefetchStatusItf on an AudioPlayer pulling from a BufferQueue
- Make SLPrefetchStatusItf explicit on Android as per spec.
- Signal prefetch status underflow when queue becomes empty, and
sufficient data when filled again.

Change-Id: I0e0ae9dc305fe6d83dd4497741f9271ca465edd5
imeUri/seekTorture.c
e5d006b298ce7683d66f7ec86136403cf5fb20d6 13-Aug-2010 Glenn Kasten <gkasten@google.com> Make internal implicit interfaces safer.

Add IsInterfaceInitialized.
Don't directly manipulate a buffer queue.
Call the interface via it's named entry points, not the v-table as it may not be initialized/available.
GetInterface enables the v-table not init.
Update Doxygen comments.
Line length 100.
Allow bool, true, and false in C code.
Add a verbose option to seek torture test.

Change-Id: I37c42834422759b881d2ffe4b171d9aa284fde98
cmBufferQueue/loop/loop.c
095ce2204cc75a50d9f1df60d1c8f357209a7c3d 10-Aug-2010 Glenn Kasten <gkasten@google.com> Permute is a tool used by seek torture test.

Change-Id: Ifd077cda90f89c11011c8dd606a766d8b0ed5797
imeUri/seekTorture.c
5d033b8b0c7649860177f4f82d5784e83d3ff504 10-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Merge "Do not initialize effect descriptors if the audio player couldn't be initialized." into gingerbread
0ac2a7d4343d98e3cb02180e548a5a4737ba0df1 10-Aug-2010 Glenn Kasten <gkasten@google.com> Add command-line options to loop test.

Fix file permissions (no execute).
Line length 100.

Change-Id: If9a3e435ce5a48684a281c8f68488894dcefbe6f
cmBufferQueue/loop/loop.c
ecorder/recBuffQueue/Android.mk
ecorder/recBuffQueue/slesTestRecBuffQueue.cpp
b78fe5f783209fbe1fed42634ca9889052ffcd0b 10-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Do not initialize effect descriptors if the audio player couldn't
be initialized.

Test playback behavior after stop.

Change-Id: I67d78b73f5392948e00af99eaa9335f76256df14
imeUri/slesTest_playStates.cpp
5ef8af762b27b4fa45f59d944b11ad00311cb14b 09-Aug-2010 Glenn Kasten <gkasten@google.com> This version works but has high latency.

Change-Id: I7dc4e81cf78aa5c1c251d097f083b9428cb34984
Problems: mismatch of channel counts, too many buffers, buffers too large.
cmBufferQueue/loop/loop.c
a384948fc96e81947a9b689fc65ea0e7b93df25c 07-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Use paranthesis in macro for buffer size.
Use stderr for error display.

Change-Id: I83d41377f58e10ac494522bea15bafe41ca84982
ecorder/recBuffQueue/slesTestRecBuffQueue.cpp
ece0014725c0f3b8ff6c369aeabd27a71f03510b 07-Aug-2010 Jean-Michel Trivi <jmtrivi@google.com> Add a demo app showcasing the use of the BufferQueue interface on
an AudioRecorder object to record PCM samples to a file.

Change-Id: Ia27465a6540b81962266951800da1a81ef0794d1
ecorder/recBuffQueue/Android.mk
ecorder/recBuffQueue/slesTestRecBuffQueue.cpp
f460ec604707d0bdaf8124d84c5f8595cba9c804 04-Aug-2010 Glenn Kasten <gkasten@google.com> Add the record to play loop test (broken)

Change-Id: I2b50501fef8a110d97d3cac69a0fec807b9de422
cmBufferQueue/loop/Android.mk
cmBufferQueue/loop/loop.c
b9fa556e62aa6e0c8a59f224136e509df813cfc7 04-Aug-2010 Glenn Kasten <gkasten@google.com> Add the seek torture test

Change-Id: Icd4ef20283f6f0ac499901a7ffa8e9416abb2798
imeUri/Android.mk
imeUri/seekTorture.c
2a6437ce83811c28df37b4cbad171c74e7613892 04-Aug-2010 Glenn Kasten <gkasten@google.com> A \n should continue to be mapped to \r\n

Change-Id: I84a2c215e53d77a5a38fc9527b3111c1db76dfe6
cmBufferQueue/intbufq/getch.c
972fc5efc39b27efdf0c23397ff66923cdb729b9 31-Jul-2010 Glenn Kasten <gkasten@google.com> Fix broken build for sim-eng.

Change-Id: Ie1b1eaa93819bede1e024b1930de86c0b9772138
pi/Android.mk
pi/Android.mk_
a15af1c45c3ad1d96e3012f1613a79a86c0b2547 30-Jul-2010 Glenn Kasten <gkasten@google.com> Automated test for buffer queues.

Change-Id: If59517d83bbb6c3e985e72303e6503301d091dda
pi/Android.mk
pi/BufferQueue_test.cpp
ee21d26b4b66d0f19b826685b3070497523994d5 28-Jul-2010 Glenn Kasten <gkasten@google.com> Khronos recommendation: include "SLES/OpenSLES.h"

Change-Id: Iaa36d08f313a29ad2914e7459448bf9418e8c6c8
ffects/eqFdPath/slesTestEqFdPath.cpp
imeFd/playFdPath/slesTestPlayFdPath.cpp
imeUri/multiplay.c
imeUri/slesTestPlayStreamType.cpp
imeUri/slesTestPlayUri.cpp
imeUri/slesTestPlayUri2.cpp
imeUri/slesTest_playMuteSolo.cpp
imeUri/slesTest_playStates.cpp
imeUri_test.cpp
cmBufferQueue/intbufq/intbufq.c
cmBufferQueue/sawtoothBufferQueue/bufferQueue.c
cmBufferQueue/sawtoothBufferQueue/playSawtoothBufferQueue.cpp
a64474bb5e142123ae3630bcd403dfb62bd64fc8 26-Jul-2010 Glenn Kasten <gkasten@google.com> Flatten the tests/mimeUri directory.

Change-Id: Ib8056ec7a4a167e6afdce7f020468381126c657e
imeUri/Android.mk
imeUri/multiplay.c
imeUri/multiplay/Android.mk
imeUri/multiplay/multiplay.c
imeUri/playMuteSolo/Android.mk
imeUri/playMuteSolo/slesTest_playMuteSolo.cpp
imeUri/playStates/Android.mk
imeUri/playStates/slesTest_playStates.cpp
imeUri/playStreamType/Android.mk
imeUri/playStreamType/slesTestPlayStreamType.cpp
imeUri/playUri/Android.mk
imeUri/playUri/slesTestPlayUri.cpp
imeUri/playUri2/Android.mk
imeUri/playUri2/slesTestPlayUri.cpp
imeUri/slesTestPlayStreamType.cpp
imeUri/slesTestPlayUri.cpp
imeUri/slesTestPlayUri2.cpp
imeUri/slesTest_playMuteSolo.cpp
imeUri/slesTest_playStates.cpp
4776ee2b7b465472da86b2601db078c37363aa94 23-Jul-2010 Jean-Michel Trivi <jmtrivi@google.com> Merge "Add test to exercise the SLEqualizerItf interface." into gingerbread
34f7db8908b2d85ecdbca1a7bcb263d979d869e7 23-Jul-2010 Jean-Michel Trivi <jmtrivi@google.com> Add test to exercise the SLEqualizerItf interface.

Change-Id: I8c23516cee834e05911f890a89671fb1acd4a8e4
ffects/eqFdPath/Android.mk
ffects/eqFdPath/slesTestEqFdPath.cpp
4b65ef9efdf5aba01bea89d8cdd64f500560a28d 17-Jul-2010 Glenn Kasten <gkasten@google.com> Buffer queue and audio player maintenance.

Known problems on Android only (SDL is ok):
High latency on first enqueue, or first after buffer underrun
Play after stop does not resume the current buffer.

Improvements:
Implement BufferQueue::Clear for both Android and SDL.
Play::SetPlayState to Stopped now works for SDL (not yet for Android), and
sets play cursor to start of current buffer.
Play::Pause and Play::Stop while playing now block until done for SDL.
SDL now calls buffer queue callback after each buffer completion, instead of when mixer needs a buffer.
Move SF_INFO sfinfo to CAudioPlayer so we always have good stuff like the sample rate etc.
BufferQueue::Enqueue on a successful enqueue to a formerly empty queue
now kicks off an attribute change followed by a synchronous call to a
hook when first buffer enqueued. Currently unused but could be a way to reduce latency.
Minor comment changes.
Add interface_cond_broadcast.
More logging of errors.
Include source file and line number in logs.
sles_to_android.cpp: needs code for #if 0 sections.
Disable trace logging of BufferQueue::Enqueue and GetState.
Fix printf warnings.
Fix typo in number of interfaces requested at CreateAudioPlayer.
Remove spurious printf and while loop.
Line length 100.
Add intermediate play states which need to be re-mapped.
Fix printf format warnings.
Re-organize the buffer queue initialization.
Implement true seeking based on position for libsndfile.
SndFile is working again, but just barely.
Make it build on non-Android platforms.
BufferQueue::RegisterCallback now checks for STOPPED play state.
Include function name in trace logs.
Enhance test to check buffer queue callbacks, get buffer queue state, get play state.
Fix bug with Stop while Paused not resetting buffer pointer.
Remove obsolete comments and #if 0.
Set enqueue attribute is state is PLAYING and the first buffer is enqueued.
Added slutPrintIIDs.
Update comments.
Fix build warnings.
Fix compile error introduced by the merge.
Fix runtime problems introduced during the merge.
Address code review comments:
- BufferQueue changes apply to AudioRecord also.
- Rename to conform to new naming conventions.
- Add comments.
Fix build warning.
Add interactive buffer queue test application.

Change-Id: I5b00545a599fd9dba96efb834fca2369d149eaaa
imeUri/multiplay/multiplay.c
imeUri/playMuteSolo/slesTest_playMuteSolo.cpp
imeUri/playUri2/slesTestPlayUri.cpp
cmBufferQueue/intbufq/Android.mk
cmBufferQueue/intbufq/getch.c
cmBufferQueue/intbufq/intbufq.c
cmBufferQueue/sawtoothBufferQueue/bufferQueue.c
8eabaa529bf4796543a54bccc6f87def95e0b326 09-Jul-2010 Glenn Kasten <gkasten@google.com> Port test apps to non-Android platform.

Change-Id: If4e8ace08b3eee8c62c375a5b238fd1ed3665a06
imeUri/playMuteSolo/slesTest_playMuteSolo.cpp
imeUri/playUri/slesTestPlayUri.cpp
imeUri/playUri2/slesTestPlayUri.cpp
cmBufferQueue/sawtoothBufferQueue/playSawtoothBufferQueue.cpp
603d9aec6b2d96693bf91cba4b0a678027c34572 09-Jul-2010 Jean-Michel Trivi <jmtrivi@google.com> Since SLPrefetchStatusItf is explicit, fix the playUri test to
request two interfaces (volume and prefetch) when creating the
AudioPlayer.

Change-Id: I97b18b68dac2ffacef9c709c3f1c2ee85081e07d
imeUri/playUri/slesTestPlayUri.cpp
791b3c0bb7bef1fd930a1b91274b972989f6a715 08-Jul-2010 Yu Shan Emily Lau <yslau@google.com> Added the make file for the opensles gTest.

Change-Id: Ib2750cd5ba9500d7030bf64fca99a3411bbaa74c
ndroid.mk
imeUri_test.cpp
98aadb37725077b313d237a070e0c3633487edee 07-Jul-2010 Glenn Kasten <gkasten@google.com> Merge "Trace debug support." into gingerbread
ed46c29d6a09112dbbf584c82953f63289596fd6 03-Jul-2010 Glenn Kasten <gkasten@google.com> Trace debug support.

Add Enter/Leave interface macros for trace debugging.
3D interface methods do not block for now.
Line length 100.
Add blank lines between interface methods for clarity.

Change-Id: I412936e8574f95308731e41f8b854fe342cb04b6
imeUri/multiplay/multiplay.c
2b42246440867e6be3e2b508e2dbd5a62bd6686e 03-Jul-2010 Yu Shan Emily Lau <yslau@google.com> The change broke the sim build. Remove the makefile for now until find the fix.

Change-Id: I83eb123fdaec129238f62efdc5ea21f2426f7f8c
ndroid.mk
af1a1f532a7a9d90675022c0d063a48b5d33a0d3 02-Jul-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix sim build. Proper makefile modification, not copy paste.

Change-Id: Iede8f9b07029491e76a46e500a13aff0aa6de881
ndroid.mk
e09d6784d14b138484179aae680fbfe1b08eeba0 02-Jul-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix sim build. Exclude stlport on the simulator.

Change-Id: I54f66168b75788846ee0c94216be7f487ab4c0f2
ndroid.mk
cbd591140854c0266e6c04bc95ad7bcac234f4c2 02-Jul-2010 Yu Shan Emily Lau <yslau@google.com> Merge "Integrated the mimeUri PlayUri native with the gTest framework." into gingerbread
1c1c2d6d225e8180ba85f41170f7921d471308da 01-Jul-2010 Jean-Michel Trivi <jmtrivi@google.com> Let SfPlayer handle the play state with regards to decoding.
This fixes the bug where the player couldn't be resumed after being paused.
Add test of the OpenSL ES play states.

Change-Id: I3793941abf852aaca359346c656e4a8e29ed666c
imeUri/playStates/Android.mk
imeUri/playStates/slesTest_playStates.cpp
8009647ac2acc84df0d8d97196224abbc00f62d4 01-Jul-2010 Jean-Michel Trivi <jmtrivi@google.com> Merge "Declaration of a new DataLocator type for OpenSL ES on Android: file descriptor. Implementation of support for SL_DATALOCATOR_ANDROIDFD. Test application to play a file from a file descriptor. Fix bug in sles_to_android.cpp where resources were never freed when destroying the player." into gingerbread
95ba463b7fd020b23dc48ac0049b9c107add7990 30-Jun-2010 Yu Shan Emily Lau <yslau@google.com> Integrated the mimeUri PlayUri native with the gTest framework.

Change-Id: I64bfc2acfdd1be7088a1536dec8033576eb11fdc
ndroid.mk
imeUri_test.cpp
989ab369777ef514ac3ba6cdb893de9ae0c976bc 30-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Declaration of a new DataLocator type for OpenSL ES on Android: file
descriptor.
Implementation of support for SL_DATALOCATOR_ANDROIDFD.
Test application to play a file from a file descriptor.
Fix bug in sles_to_android.cpp where resources were never freed
when destroying the player.

Change-Id: I45156f41ee5ca77d3a944f8f89b75880db8b4aba
imeFd/playFdPath/Android.mk
imeFd/playFdPath/slesTestPlayFdPath.cpp
1c1c16f5469b9ebb4943e2c5eb648f832e0a3c37 30-Jun-2010 Glenn Kasten <gkasten@google.com> Initial draft of multiplay command-line test app.

Change-Id: I821573c7e9eef123dab3a5b00e1040ab69ea215a
imeUri/multiplay/Android.mk
imeUri/multiplay/multiplay.c
b98e6b7b1cc2a130a29904e52ae7a71e15332a49 29-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Add a test for GetStreamType on SLAndroidStreamTypeItf.

Change-Id: I2115488a2d4dc97a8bb1f5f01742e77d0960e394
imeUri/playStreamType/slesTestPlayStreamType.cpp
05ccff2aaa3e1507cdc7ab3b244c973c6708e009 29-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Declaration and implementation of a new OpenSL ES interface to set
to set the Android stream type on an AudioPlayer object.

Change-Id: Ic5d14e9899dfbccfc647642ae562730807bc73fe
imeUri/playStreamType/Android.mk
imeUri/playStreamType/slesTestPlayStreamType.cpp
e5bf0d2c9531a7064eb3ddcafaf93ac1b0974037 24-Jun-2010 Glenn Kasten <gkasten@google.com> Gain and transport attributes at mutex unlock.

Update both interface and player copies of mute/solo.
Move synchronous gain and transport updates to mutex unlock exclusive.
Update sync thread logic.
Keep track of player position using tracks in PCM frame units.
Implement solo.
Various volume-related fixes.
Mute solo fields are only in IMuteSolo, but IMuteSolo is
immediately after IVolume to make it easier to find.
Move Android volume fields into audio player.
Fix printf missing newline.
Only one copy of mute and solo.
Clean up comments.
Line length 100.
SDL gain and transport updates are synchronous.
Fix unused variable warnings.
Use symbol for number of stereo channels.
Rearrange fields to save memory.
Add comments.
Fix problems introduced during the last merge.

Change-Id: I121fcbe4189b06850983941f540942a745fc51fb
imeUri/playMuteSolo/slesTest_playMuteSolo.cpp
fa8629b180d59a299675cda6c95c4fc2b74645e3 29-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Fix test makefiles for OpenSL ES test apps.

Change-Id: I996bd47aad50231f8d93f48fdedac3be74295592
imeUri/playMuteSolo/Android.mk
imeUri/playUri/Android.mk
imeUri/playUri2/Android.mk
cmBufferQueue/sawtoothBufferQueue/Android.mk
85bae78453492b42c7095cafc404a049e52bbc22 25-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> New test / demo to exercise SLMuteSoloItf on an AudioPlayer.

Change-Id: Ib3fddaea46098ed944b62d08d8ba8a657bf0174c
imeUri/playMuteSolo/Android.mk
imeUri/playMuteSolo/slesTest_playMuteSolo.cpp
de16b4c2bc71c163c7c821a475a53a3b567789b2 16-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Introduction of Stagefright to replace MediaPlayer.
Change-Id: I59c467ebafed6f5ceee37c2d8f6cd132b25c1459
imeUri/playUri/slesTestPlayUri.cpp
276cab2d983b892d1b634474b6249f6bec400c76 16-Jun-2010 Glenn Kasten <gkasten@google.com> Add limited volume support for USE_SNDFILE platform.

Fix build warnings.
Remove obsolete FIXME.
cmBufferQueue/sawtoothBufferQueue/bufferQueue.c
2a00e1105c1e051f13d2b5f3f69f02882de982ea 11-Jun-2010 Glenn Kasten <gkasten@google.com> Fix printf format bug.

Change-Id: Ic81eea513315ca6465a6cbc5d19731122bbb62ed
imeUri/playUri2/slesTestPlayUri.cpp
85da61df4231113debc9e829c9b71493ab945200 10-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> The library for the OpenSL ES implementation is supposed to be name
libOpenSLES, not libopensles.

Change-Id: Icdfb266650abb75a8aaf5670b651bfea1361c3c1
imeUri/playUri/Android.mk
imeUri/playUri2/Android.mk
cmBufferQueue/sawtoothBufferQueue/Android.mk
b0dc406de15e71fb53df0bd070b611317bea1d73 09-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> New OpenSL ES test+demo application that uses the SLPrefetchStatusItf.
Plays two URIs and pans them left and right.

Change-Id: Ic804c0d666889088db6a4075f5c40029e11273fe
imeUri/playUri2/Android.mk
imeUri/playUri2/slesTestPlayUri.cpp
8addfbc02746de2e4d3f87ce50e4ba2e547e7485 09-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Merge "OpenSL ES tests shouldn't be built in all builds." into kraken
c0bee8e867b37db601809df7a6fc30f8ee698e83 08-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> OpenSL ES tests shouldn't be built in all builds.

Change-Id: Ib014c47cb5c25d1348e544ead3e272e4d2194d5f
imeUri/playUri/Android.mk
cmBufferQueue/sawtoothBufferQueue/Android.mk
06a1b91fb42d3ecc9da725e673b56ca849b9b9a4 04-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Modify implementation of SLPlayItf to only start prefetching data
when the playstate is set to PAUSED, and notify prefetch status
change and buffer fill level through the SLPrefetchItf callback.
Modify test app to correctly start playing only after a prefetch
status change.

Change-Id: I51482bb5b7db419bdb694be2277282d94ff8234f
imeUri/playUri/slesTestPlayUri.cpp
f8acf4b469cdc9d2fe08fb7f6ca007365efc8bc1 02-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> For audio players with URI data source:
- Modify stereo volume update to also work on a MediaPlayer.
- Add support for completion callback when play event mask
specifies SL_PLAYEVENT_HEADATEND
Before changing a property related to the SLVolumeItf or
SLPlayItf, check that the property has changed before applying
it to avoid useless calls and computations.
Cleanup in playUri test and compile without warnings.
Remove "driver" test content: test app was previously moved
to tests/pcmBufferQueue.
According to spec: initialize periodic update for SLPlayItf
and SLRecordItf to 1s.
Change-Id: I00dad162eac7c0d88b535ab65e2351353b8888d5
river/Android.mk_
river/bufferQueue.c
river/playSine.cpp
river/slesTestBufferQueue.cpp
imeUri/playUri/slesTestPlayUri.cpp
dc181a4a041fe4be7c91b92646b236b6d652f4a3 02-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Implement GetDuration and GetPosition in SLPlayItf

Change-Id: I83ae15310c3e473556703e5d373aef5a07e6eda5
imeUri/playUri/slesTestPlayUri.cpp
daf661248ff6ea2e21799e5114c78b7c1d49630e 29-May-2010 Glenn Kasten <gkasten@google.com> Move platform-specific code to separate files. Use sles_allinclusive.h to really mean all inclusive. MuteSolo check channel count.

Change-Id: I96caab5be55a1f04342eb67b511309babd5a6916

Make a copy of data source and sink parameter to avoid dangling inputs. Pre-process URI scheme and MIME type using a perfect hash. Line length 100.

Change-Id: Icb1e1a7a9c6370eda1e15e61f0dff35c1d59d7fa

Fix merge problem on Android.

Change-Id: I70b724273147f3981550272990729a4a409e1f72

MIME type needs to be completely initialized.

Change-Id: I3766acfb170abc976506cf305fabd5548107f592

Remove MIME lookup and URI scheme lookup.

Change-Id: I7058dfef01c9db509ad5915d9f8099a720e6736b
imeUri/playUri/slesTestPlayUri.cpp
1be90f9197d7a48e788b5e40fd15d73a877acef0 01-Jun-2010 Jean-Michel Trivi <jmtrivi@google.com> Add command line test to play a URI, to exercise the OpenSL ES
AudioPlayer with a SL_DATALOCATOR_URI as data source. Plays 10s
of the URI.

Change-Id: I24b8ae5293c4efbc372551febd91eb6dafe890eb
imeUri/playUri/Android.mk
imeUri/playUri/slesTestPlayUri.cpp
9309fe7834ab02adfacb2d6b4ac02852d3aa121d 26-May-2010 Jean-Michel Trivi <jmtrivi@google.com> Add a command line test for PCM buffer queues.
This example is based on the buffer queue sample code from the
OpenSL ES specification.

Change-Id: Ic0730549fe54e7d5cedf1bd7d374e2b81c1e969d
cmBufferQueue/sawtoothBufferQueue/Android.mk
cmBufferQueue/sawtoothBufferQueue/bufferQueue.c
cmBufferQueue/sawtoothBufferQueue/playSawtoothBufferQueue.cpp
1ae30e37f39fcfe7937a707b789e49a7d68112ba 19-May-2010 Jean-Michel Trivi <jmtrivi@google.com> Implement the AudioTrack callback to retrieve audio data from a
BufferQueue interface.
When handing audio data from the buffer queue to the AudioTrack
callback, you cannot give more data than the given size. This
requires the handling of partial buffer consumption, before
the play index is incremented and the buffer queue callback
is called.

Change-Id: I2181afbc509182ff5c38aebbc4784f9b9916a6ae
river/Android.mk_
river/bufferQueue.c
river/slesTestBufferQueue.cpp
a852e9eca77c64fcba11eb590bec7a11aca5fe16 18-May-2010 Jean-Michel Trivi <jmtrivi@google.com> Add android-specific AudioPlayer Realize function.

Change-Id: Ice8fcc0243a146cdfc7941d72419b4181f9a5909
river/bufferQueue.c
d20441ee29747b206cb0d197260c3ac78d7762da 08-May-2010 Glenn Kasten <gkasten@google.com> First audio output using Android AudioTrack.

Change-Id: Id18de8f51a73d9c801dbc79c1e8a19845b6045c2
river/Android.mk_
river/bufferQueue.c
river/playSine.cpp