- Fix ResourceManagerSerivce handling of adding same-type
resource in multiple calls, combine entries with the same
<type, subtype>. This is not required in existing usage,
bug could be required if we allow same type to be added
incrementally (eg. memory usage).
- Add api for removing some resources. Currently we can
add resources in multiple calls, but removeResource always
remove all resources of that client. We need this to toggle
battery stat On/Off based on actual usage of the codec.
- Add unit tests for the above.
bug: 138381810
test: ResourceManagerService_test; CTS ResourceManangerTest.
Change-Id: Icdba6c6b4c517755291668c52764169aac3071ea
We can't track video stats accurately if it's reported from
app side MediaCodec. If the app dies, video stats get stuck
in On state forever. This can be easily triggered by forcefully
kill and app that uses MediaCodec from app side (instead of
through mediaserver's Recorder or Player service), eg.
launch GoogleCamera app and switch to Video tab, and kill it
from adb shell.
In order to track MediaCodec usage from apps we need to move
the battery stats reporting from MediaCodec into ResourceManager.
bug: 138381810
test:
1. test if app uses MediaCodec directly and it dies off, the video
off is received: launch GoogleCamera app, swipe to Video tab,
"dumpsys batterystats --history" and see +video; now adb shell
kill GoogleCamera, dumpsys should show -video.
2. test app that uses MediaCodec through mediaserver: use Chrome
(which uses MediaPlayer) to play some website with video, kills
Chrome from adb shell, and check -video is received.
In anycase it shouldn't stuck in On state.
3. ResourceManagerService_test
Change-Id: I164b31681c4e72e8cce02342641dbec14b8df374
(cherry picked from commit 47db2ff19c)
MediaMuxer would find 'time-lapse-fps' value in input format from GCA
and pass it on to MPEG4Writer for SlowMotionRecord.
Bug: 138995916
Test: atest CtsMediaTestCases
atest CtsMediaTestCases:android.media.cts.MediaMuxerTest
Change-Id: I6af102540ddd439b203351ebba07eabf89f2d330
am: b279c8c347 -s ours
am skip reason: change_id I567890f3d04544c12adfe29a6a23c06f1db699e7 with SHA1 8c886ae968 is in history
Change-Id: I4bfd0f36c5a235579fa2a2203510e47501f1e7a6
am: b2f9f22cfa -s ours
am skip reason: change_id I567890f3d04544c12adfe29a6a23c06f1db699e7 with SHA1 8c886ae968 is in history
Change-Id: I7ea414423ef5017c02e3e3b19ccc424240d4e6d2
This reverts commit 10ceef9f3b.
Reason for revert: This isn't wanted in qt-dev. It is in qt-r1-dev and will be delivered in the December Mainline train.
Bug: 137245963
Change-Id: I0a5a4991786d6dcbd324663a6d342729166a5528
Merged-In: I567890f3d04544c12adfe29a6a23c06f1db699e7
The file name and path of the media profiles can be changed by
media.settings.xml property. So befor test, we should check
media.settings.xml property.
Bug: 138413934
Test: vts-tradefed run vts -m VtsValidateMediaProfiles
Change-Id: Ib7070cca94b9d637b9a1a175d09baf7b78ec0fd9
Merged-In: Ib7070cca94b9d637b9a1a175d09baf7b78ec0fd9
(cherry picked from commit ef8695ed84)
Return cloned handle as output parameter in order to use it after
closing the bufferpool connection.
Bug: 138171841
Test: atest CtsMediaTestCases -- --module-arg CtsMediaTestCases:size:small
Merged-In: I4ac142fcb7e3ecdb3fb02792f516b343d71bfc38
Change-Id: I4ac142fcb7e3ecdb3fb02792f516b343d71bfc38
(cherry picked from commit dc5cb62ff4)
isConfigured() in soft vorbis decoder omx plugin was using
mInputBufferCount to detect if the decoder was configured.
But mInputBufferCount was reset to 0 after flush.
This was prone to a race condition, when flush was called immediately
after start(), before codec could signal correct number of channels and
sampling rate.
isConfigured() is now fixed to check decoder state rather than
mInputBufferCount.
Bug: 137736256
Bug: 138213973
Test: atest android.media.cts.DecoderTest#testDecodeWithEOSOnLastBuffer
Change-Id: Ia1e6b88eca45b46fe20f36627f79cd767b73cc1a
Also remove the expected argument in addProviderLocked method as
we now can query from device manifest for instance names.
Test: manually modify Pixel3 manifest to test, CTS
Bug: 136010319
Merged-In: Ib57fd84ad8f22aac2a82920e03148cff2592daae
Change-Id: Ib57fd84ad8f22aac2a82920e03148cff2592daae
Do not consider Accessibility services when determining
lastest active capture client. As an Accessibility service
capturing does not silence other captures, it should not
prevent another client from being selected as the latest active.
Bug: 135806801
Test: Start capture with Recorder app, activate Voice Access
Change-Id: I864be785752f27201d45ce24f95013de6391dbd6
Replace the item MIME type with value supported
by the dynamic depth specification.
Bug: 138399780
Test: runtest -x
cts/tests/camera/src/android/hardware/camera2/cts/ImageReaderTest.java
-m testDynamicDepth
Change-Id: Ib51dd69e6de7da3269eccfa6b671fe95a269b4d6
The decoder does not support an increase in frame width, and
would exceed its buffer if the width increased mid-stream.
There was an existing check to prevent the total frame size
(width*height) from increasing, but in fact the decoder also
does not even support a width increase, even if the height
decreases correspondingly.
Bug: 136175447
Bug: 136173699
Test: manual
Change-Id: Ic2d28bb0503635dadeb69ba3be9412d58684e910
Add # of input slots to max dequeue buffer count for output buffers.
If pipeline is paused, # of output buffers could be whole pipeline depth
including # of input slots.
Bug: 137150765
Merged-In: I5fce613a383160ea8a49e77f67628f85408cdcfa
Change-Id: I5fce613a383160ea8a49e77f67628f85408cdcfa
(cherry picked from commit 7a7b742c7a)
Do not consider Assistant capturing with HOTWORD source
when determining lastest active capture client. As assistant
capturing for HOTWORD does not silence other captures, it should not
prevent another client from being selected as the latest active.
Bug: 135806801
Test: Start capture with Recorder app, place in background and trigger
false OK G detection
Change-Id: Ic17bfd70675ef749d6a678d067112b1dbd205746