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

Unified Diff: content/renderer/pepper/pepper_video_decoder_host.cc

Issue 1751323002: Allow multiple texture ids per picture buffer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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
Index: content/renderer/pepper/pepper_video_decoder_host.cc
diff --git a/content/renderer/pepper/pepper_video_decoder_host.cc b/content/renderer/pepper/pepper_video_decoder_host.cc
index c8f3bd8ed9dc6f12665f35459599da3e8e62476d..8c02ae18aa9f79b45ec74e10c0b8a95b89484bf6 100644
--- a/content/renderer/pepper/pepper_video_decoder_host.cc
+++ b/content/renderer/pepper/pepper_video_decoder_host.cc
@@ -279,10 +279,11 @@ int32_t PepperVideoDecoderHost::OnHostMsgAssignTextures(
std::vector<media::PictureBuffer> picture_buffers;
for (uint32_t i = 0; i < texture_ids.size(); i++) {
+ media::PictureBuffer::TextureIds ids;
+ ids.push_back(texture_ids[i]);
media::PictureBuffer buffer(
texture_ids[i], // Use the texture_id to identify the buffer.
- gfx::Size(size.width, size.height),
- texture_ids[i]);
+ gfx::Size(size.width, size.height), ids);
picture_buffers.push_back(buffer);
}
decoder_->AssignPictureBuffers(picture_buffers);
@@ -351,8 +352,10 @@ int32_t PepperVideoDecoderHost::OnHostMsgReset(
void PepperVideoDecoderHost::ProvidePictureBuffers(
uint32_t requested_num_of_buffers,
+ uint32_t textures_per_buffer,
const gfx::Size& dimensions,
uint32_t texture_target) {
+ DCHECK_EQ(1u, textures_per_buffer);
RequestTextures(std::max(min_picture_count_, requested_num_of_buffers),
dimensions,
texture_target,

Powered by Google App Engine
This is Rietveld 408576698