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

Unified Diff: cc/layers/video_layer_impl.cc

Issue 633773004: cc: Pass Occlusion instead of OcclusionTracker to LayerImpls (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/layers/video_layer_impl.h ('k') | cc/test/fake_picture_layer_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/video_layer_impl.cc
diff --git a/cc/layers/video_layer_impl.cc b/cc/layers/video_layer_impl.cc
index 2edea947da42c07b0b00bb3db1ae402f44ab918e..5e3739728a2e8d5328236a1b7e097bbba6dc1b9c 100644
--- a/cc/layers/video_layer_impl.cc
+++ b/cc/layers/video_layer_impl.cc
@@ -14,7 +14,7 @@
#include "cc/resources/resource_provider.h"
#include "cc/resources/single_release_callback_impl.h"
#include "cc/trees/layer_tree_impl.h"
-#include "cc/trees/occlusion_tracker.h"
+#include "cc/trees/occlusion.h"
#include "cc/trees/proxy.h"
#include "media/base/video_frame.h"
@@ -129,10 +129,9 @@ bool VideoLayerImpl::WillDraw(DrawMode draw_mode,
return true;
}
-void VideoLayerImpl::AppendQuads(
- RenderPass* render_pass,
- const OcclusionTracker<LayerImpl>& occlusion_tracker,
- AppendQuadsData* append_quads_data) {
+void VideoLayerImpl::AppendQuads(RenderPass* render_pass,
+ const Occlusion& occlusion_in_content_space,
+ AppendQuadsData* append_quads_data) {
DCHECK(frame_.get());
gfx::Transform transform = draw_transform();
@@ -175,9 +174,10 @@ void VideoLayerImpl::AppendQuads(
gfx::Rect visible_rect = frame_->visible_rect();
gfx::Size coded_size = frame_->coded_size();
+ Occlusion occlusion_in_video_space =
+ occlusion_in_content_space.GetOcclusionWithGivenDrawTransform(transform);
gfx::Rect visible_quad_rect =
- occlusion_tracker.GetCurrentOcclusionForLayer(transform)
- .GetUnoccludedContentRect(quad_rect);
+ occlusion_in_video_space.GetUnoccludedContentRect(quad_rect);
if (visible_quad_rect.IsEmpty())
return;
« no previous file with comments | « cc/layers/video_layer_impl.h ('k') | cc/test/fake_picture_layer_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698