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

Side by Side Diff: media/filters/gpu_video_decoder.cc

Issue 2363303002: [WIP] Proxy RtcVideoDecoder calls to a media::VideoDecoder.
Patch Set: Now working with remote ffmpeg decoder Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « media/filters/ffmpeg_video_decoder.cc ('k') | media/mojo/services/mojo_video_decoder_service.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/filters/gpu_video_decoder.h" 5 #include "media/filters/gpu_video_decoder.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 571 matching lines...) Expand 10 before | Expand all | Expand 10 after
582 gfx::Size natural_size; 582 gfx::Size natural_size;
583 GetBufferData(picture.bitstream_buffer_id(), &timestamp, &visible_rect, 583 GetBufferData(picture.bitstream_buffer_id(), &timestamp, &visible_rect,
584 &natural_size); 584 &natural_size);
585 585
586 if (!picture.visible_rect().IsEmpty()) { 586 if (!picture.visible_rect().IsEmpty()) {
587 visible_rect = picture.visible_rect(); 587 visible_rect = picture.visible_rect();
588 } 588 }
589 if (!gfx::Rect(pb.size()).Contains(visible_rect)) { 589 if (!gfx::Rect(pb.size()).Contains(visible_rect)) {
590 LOG(WARNING) << "Visible size " << visible_rect.ToString() 590 LOG(WARNING) << "Visible size " << visible_rect.ToString()
591 << " is larger than coded size " << pb.size().ToString(); 591 << " is larger than coded size " << pb.size().ToString();
592 NOTREACHED() << "NOTE(slan): This is a NotifyError in the WebRTC pipeline";
592 visible_rect = gfx::Rect(pb.size()); 593 visible_rect = gfx::Rect(pb.size());
593 } 594 }
594 595
595 DCHECK(decoder_texture_target_); 596 DCHECK(decoder_texture_target_);
596 597
597 gpu::MailboxHolder mailbox_holders[VideoFrame::kMaxPlanes]; 598 gpu::MailboxHolder mailbox_holders[VideoFrame::kMaxPlanes];
598 for (size_t i = 0; i < pb.texture_ids().size(); ++i) { 599 for (size_t i = 0; i < pb.texture_ids().size(); ++i) {
599 mailbox_holders[i] = gpu::MailboxHolder(pb.texture_mailbox(i), sync_token_, 600 mailbox_holders[i] = gpu::MailboxHolder(pb.texture_mailbox(i), sync_token_,
600 decoder_texture_target_); 601 decoder_texture_target_);
601 } 602 }
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
828 } 829 }
829 return false; 830 return false;
830 } 831 }
831 832
832 void GpuVideoDecoder::DCheckGpuVideoAcceleratorFactoriesTaskRunnerIsCurrent() 833 void GpuVideoDecoder::DCheckGpuVideoAcceleratorFactoriesTaskRunnerIsCurrent()
833 const { 834 const {
834 DCHECK(factories_->GetTaskRunner()->BelongsToCurrentThread()); 835 DCHECK(factories_->GetTaskRunner()->BelongsToCurrentThread());
835 } 836 }
836 837
837 } // namespace media 838 } // namespace media
OLDNEW
« no previous file with comments | « media/filters/ffmpeg_video_decoder.cc ('k') | media/mojo/services/mojo_video_decoder_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698