Add image codec support to MediaCodec
Adds a concept of a codec domain to MediaCodec which is one of video,
audio or image. Records metrics for image codecs and manages resources
for image codecs. Generalizes video width and video height to work for
images too.
Bytes sent to an image encoder and received from an encoder are not
tracked, which is different from video encoders. Concepts of priority,
frame rate, capture rate and operating rate are also not applicable to
image codecs.
Note: I'm not aware of any way to test the changes to MediaCodec, since
there is no unit test for this component and no device with an image
decoder exists yet. Let me know if you know of a way.
Test: presubmit passed
Bug: 209803992
Change-Id: Ic887d208608d231fdecb75412862bc5dccb60a3f
5 files changed