summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/ProgramVertexFixedFunction.java
diff options
context:
space:
mode:
authorChong Zhang <chz@google.com>2019-08-08 15:43:44 -0700
committerChong Zhang <chz@google.com>2019-08-14 23:23:15 +0000
commit969034824948622a30a2d6a7d4a83c76c32d7758 (patch)
tree647666dd541657c7e66c6584a88897ee95888bf1 /rs/java/android/renderscript/ProgramVertexFixedFunction.java
parentc55e4e668f72630903f2e6154bed330af3005c52 (diff)
Only allow mediaserver to report video battery stats
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. (This reverts commit 0fc2da03fe61a4105ffadd2e09f1accc9b790b5a, since neither video nor audio reports battery from client side.) 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. Change-Id: I17ce96715f20e9d29e4f429995e48294d5fd5cb7 (cherry picked from commit 62a7e0151f8c8760018fd061fd24bd8399ea38d9)
Diffstat (limited to 'rs/java/android/renderscript/ProgramVertexFixedFunction.java')
0 files changed, 0 insertions, 0 deletions