We started redesigning GpuMemoryBuffer interface to handle multiple buffers [0].
[0] https://codereview.chromium.org/
1024113003/#ps200001
In this CL:
- I added a new format gfx::GpuMemoryBuffer::YUV_420
- Implemented helper functions to use with it on GpuMemoryBufferImpl.
- I added support in GpuMemoryBufferImplSharedMemory and GpuMemoryBufferFactorySharedMemory
- I added { gfx::GpuMemoryBuffer::YUV_420, gfx::GpuMemoryBuffer::MAP } as a supported config for testing
- I added support for multi plane in test implementations: test_gpu_memory_buffer_manager, gl_manager, gpu_memory_buffer_impl_unittest
The future steps are:
- Add a new GL_* internalformat corresponding to YUV_420
- Implement support for YUV_420 in GpuMemoryBufferFactoryOzoneNativeBuffer, GLImageLinuxDMABuffer and SurfaceFactoryOzone
- Expose file descriptors for gfx::GpuMemoryBuffer::YUV_420 via Map() or GpuMemoryBufferHandle struct
Check usage of gbm_bo_get_fd() at the lowest gbmbuffer level
- Add support in GLImageSharedMemory and GLImageMemory through Bind functions
- Look for possible use cases of multiple buffers on Android, Mac, and Win platforms
BUG=439520
TEST=content_unittests --gtest_filter=GpuMemoryBufferImplTests.*
content_unittests --gtest_filter=GpuMemoryBufferFactoryTest.*
gl_tests --gtest_filter=GpuMemoryBufferTest*
Review URL: https://codereview.chromium.org/
1062853002
Cr-Commit-Position: refs/heads/master@{#324190}