Index: cc/resources/video_resource_updater.cc |
diff --git a/cc/resources/video_resource_updater.cc b/cc/resources/video_resource_updater.cc |
index 8c8c3a783db6aa31212bc1ad50afecbac9a2a43b..92f1c30bd3311d1533cde0e665fc5e2e9163d979 100644 |
--- a/cc/resources/video_resource_updater.cc |
+++ b/cc/resources/video_resource_updater.cc |
@@ -315,7 +315,7 @@ VideoFrameExternalResources VideoResourceUpdater::CreateForSoftwarePlanes( |
}; |
external_resources.mailboxes.push_back( |
- TextureMailbox(plane_resources[i].mailbox)); |
+ TextureMailbox(plane_resources[i].mailbox, GL_TEXTURE_2D, 0)); |
external_resources.release_callbacks.push_back( |
base::Bind(&RecycleResource, AsWeakPtr(), recycle_data)); |
} |
@@ -325,9 +325,9 @@ VideoFrameExternalResources VideoResourceUpdater::CreateForSoftwarePlanes( |
} |
static void ReturnTexture(const scoped_refptr<media::VideoFrame>& frame, |
- unsigned sync_point, |
+ uint32 sync_point, |
bool lost_resource) { |
- frame->texture_mailbox()->Resync(sync_point); |
+ frame->mailbox_holder()->set_sync_point(sync_point); |
} |
VideoFrameExternalResources VideoResourceUpdater::CreateForHardwarePlanes( |
@@ -341,8 +341,9 @@ VideoFrameExternalResources VideoResourceUpdater::CreateForHardwarePlanes( |
if (!context_provider_) |
return VideoFrameExternalResources(); |
+ gpu::MailboxHolder* mailbox_holder = video_frame->mailbox_holder(); |
VideoFrameExternalResources external_resources; |
- switch (video_frame->texture_target()) { |
+ switch (mailbox_holder->target()) { |
case GL_TEXTURE_2D: |
external_resources.type = VideoFrameExternalResources::RGB_RESOURCE; |
break; |
@@ -358,12 +359,9 @@ VideoFrameExternalResources VideoResourceUpdater::CreateForHardwarePlanes( |
return VideoFrameExternalResources(); |
} |
- media::VideoFrame::MailboxHolder* mailbox_holder = |
- video_frame->texture_mailbox(); |
- |
external_resources.mailboxes.push_back( |
TextureMailbox(mailbox_holder->mailbox(), |
- video_frame->texture_target(), |
+ mailbox_holder->target(), |
mailbox_holder->sync_point())); |
external_resources.release_callbacks.push_back( |
base::Bind(&ReturnTexture, video_frame)); |
@@ -374,7 +372,7 @@ VideoFrameExternalResources VideoResourceUpdater::CreateForHardwarePlanes( |
void VideoResourceUpdater::RecycleResource( |
base::WeakPtr<VideoResourceUpdater> updater, |
RecycleResourceData data, |
- unsigned sync_point, |
+ uint32 sync_point, |
bool lost_resource) { |
if (!updater.get()) { |
// Resource was already deleted. |