Index: media/gpu/vaapi_video_decode_accelerator.cc |
diff --git a/media/gpu/vaapi_video_decode_accelerator.cc b/media/gpu/vaapi_video_decode_accelerator.cc |
index 9c6897fa15abd9ac8c453bfb94953f9328bed059..49fb45c44b27cb3c582c8ab1141af2811ca98420 100644 |
--- a/media/gpu/vaapi_video_decode_accelerator.cc |
+++ b/media/gpu/vaapi_video_decode_accelerator.cc |
@@ -427,14 +427,13 @@ void VaapiVideoDecodeAccelerator::OutputPicture( |
// Notify the client a picture is ready to be displayed. |
++num_frames_at_client_; |
TRACE_COUNTER1("Video Decoder", "Textures at client", num_frames_at_client_); |
- DVLOG(4) << "Notifying output picture id " << output_id |
- << " for input " << input_id << " is ready"; |
- // TODO(posciak): Use visible size from decoder here instead |
- // (crbug.com/402760). Passing (0, 0) results in the client using the |
- // visible size extracted from the container instead. |
+ gfx::Rect visible_rect = decoder_->GetVisibleRect(); |
Owen Lin
2017/06/07 06:11:00
I am afraid you cannot get the visible size here.
johnylin1
2017/06/07 15:38:37
I think it would be better to put visible_size in
Pawel Osciak
2017/06/08 04:58:24
Could you explain your reasoning please?
Owen is
Owen Lin
2017/06/09 02:03:17
I understand why we need this in DecodeSurface. H2
johnylin1
2017/06/12 13:41:53
My thought is same as Owen, we need to have visibl
|
+ DVLOG(4) << "Notifying output picture id " << output_id << " for input " |
+ << input_id |
+ << " is ready. visible rect: " << visible_rect.ToString(); |
// TODO(hubbe): Use the correct color space. http://crbug.com/647725 |
if (client_) |
- client_->PictureReady(Picture(output_id, input_id, gfx::Rect(0, 0), |
+ client_->PictureReady(Picture(output_id, input_id, visible_rect, |
gfx::ColorSpace(), picture->AllowOverlay())); |
} |