| Index: cc/resources/video_resource_updater.cc
|
| diff --git a/cc/resources/video_resource_updater.cc b/cc/resources/video_resource_updater.cc
|
| index 54e4a5cd3d4603278b6926c2a2711a4c075a0cae..bd914179fade171507746dde9fa64be321e94d0f 100644
|
| --- a/cc/resources/video_resource_updater.cc
|
| +++ b/cc/resources/video_resource_updater.cc
|
| @@ -306,7 +306,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));
|
| }
|
| @@ -316,9 +316,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()->sync_point = sync_point;
|
| }
|
|
|
| VideoFrameExternalResources VideoResourceUpdater::CreateForHardwarePlanes(
|
| @@ -332,8 +332,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->texture_target) {
|
| case GL_TEXTURE_2D:
|
| external_resources.type = VideoFrameExternalResources::RGB_RESOURCE;
|
| break;
|
| @@ -349,13 +350,10 @@ 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->sync_point()));
|
| + TextureMailbox(mailbox_holder->mailbox,
|
| + mailbox_holder->texture_target,
|
| + mailbox_holder->sync_point));
|
| external_resources.release_callbacks.push_back(
|
| base::Bind(&ReturnTexture, video_frame));
|
| return external_resources;
|
| @@ -365,7 +363,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.
|
|
|