Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(57)

Unified Diff: chrome/gpu/arc_gpu_video_decode_accelerator.cc

Issue 1942123002: Plumb decoded video pixel format from GPU process to renderer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix test on bots Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/gpu/arc_gpu_video_decode_accelerator.h ('k') | content/renderer/media/rtc_video_decoder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/gpu/arc_gpu_video_decode_accelerator.cc
diff --git a/chrome/gpu/arc_gpu_video_decode_accelerator.cc b/chrome/gpu/arc_gpu_video_decode_accelerator.cc
index 2766cf1e72a9c643937f3dd405d210f42bcae271..3ede55e9a53fba52d23b93de39af6cffecfb9f8d 100644
--- a/chrome/gpu/arc_gpu_video_decode_accelerator.cc
+++ b/chrome/gpu/arc_gpu_video_decode_accelerator.cc
@@ -304,6 +304,7 @@ void ArcGpuVideoDecodeAccelerator::Flush() {
void ArcGpuVideoDecodeAccelerator::ProvidePictureBuffers(
uint32_t requested_num_of_buffers,
+ media::VideoPixelFormat output_pixel_format,
uint32_t textures_per_buffer,
const gfx::Size& dimensions,
uint32_t texture_target) {
@@ -312,7 +313,12 @@ void ArcGpuVideoDecodeAccelerator::ProvidePictureBuffers(
<< ", dimensions=" << dimensions.ToString() << ")";
DCHECK(thread_checker_.CalledOnValidThread());
coded_size_ = dimensions;
- output_pixel_format_ = vda_->GetOutputFormat();
+ if ((output_pixel_format_ != media::PIXEL_FORMAT_UNKNOWN) &&
+ (output_pixel_format_ != output_pixel_format)) {
+ arc_client_->OnError(PLATFORM_FAILURE);
+ return;
+ }
+ output_pixel_format_ = output_pixel_format;
VideoFormat video_format;
switch (output_pixel_format_) {
« no previous file with comments | « chrome/gpu/arc_gpu_video_decode_accelerator.h ('k') | content/renderer/media/rtc_video_decoder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698