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

Side by Side Diff: services/gfx/compositor/graph/scene_content.h

Issue 1995873002: Mozart: Improve tracing and backpressure. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: address review comments Created 4 years, 7 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef SERVICES_GFX_COMPOSITOR_GRAPH_SCENE_CONTENT_H_ 5 #ifndef SERVICES_GFX_COMPOSITOR_GRAPH_SCENE_CONTENT_H_
6 #define SERVICES_GFX_COMPOSITOR_GRAPH_SCENE_CONTENT_H_ 6 #define SERVICES_GFX_COMPOSITOR_GRAPH_SCENE_CONTENT_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 #include <string> 9 #include <string>
10 #include <unordered_map> 10 #include <unordered_map>
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 52
53 // Gets the version of the scene represented by this object. 53 // Gets the version of the scene represented by this object.
54 uint32_t version() const { return version_; } 54 uint32_t version() const { return version_; }
55 55
56 // Gets the time when this scene was presented. 56 // Gets the time when this scene was presented.
57 int64_t presentation_time() const { return presentation_time_; } 57 int64_t presentation_time() const { return presentation_time_; }
58 58
59 // Returns true if this content satisfies a request for the specified version. 59 // Returns true if this content satisfies a request for the specified version.
60 bool MatchesVersion(uint32_t requested_version) const; 60 bool MatchesVersion(uint32_t requested_version) const;
61 61
62 // Called to record drawing commands from a snapshot. 62 // Paints the content of the scene to a recording canvas.
63 void RecordPicture(const Snapshot* snapshot, SkCanvas* canvas) const; 63 void Paint(const Snapshot* snapshot, SkCanvas* canvas) const;
64 64
65 // Performs a hit test at the specified point. 65 // Performs a hit test at the specified point.
66 // The |scene_point| is the hit tested point in the scene's coordinate space. 66 // The |scene_point| is the hit tested point in the scene's coordinate space.
67 // The |global_to_scene_transform| is the accumulated transform from the 67 // The |global_to_scene_transform| is the accumulated transform from the
68 // global coordinate space to the scene's coordinate space. 68 // global coordinate space to the scene's coordinate space.
69 // Provides hit information for the scene in |out_scene_hit| if any. 69 // Provides hit information for the scene in |out_scene_hit| if any.
70 // Returns true if the search was terminated by an opaque hit. 70 // Returns true if the search was terminated by an opaque hit.
71 bool HitTest(const Snapshot* snapshot, 71 bool HitTest(const Snapshot* snapshot,
72 const SkPoint& scene_point, 72 const SkPoint& scene_point,
73 const SkMatrix44& global_to_scene_transform, 73 const SkMatrix44& global_to_scene_transform,
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 141
142 scoped_refptr<SceneContent> content_; 142 scoped_refptr<SceneContent> content_;
143 std::ostream& err_; 143 std::ostream& err_;
144 144
145 DISALLOW_COPY_AND_ASSIGN(SceneContentBuilder); 145 DISALLOW_COPY_AND_ASSIGN(SceneContentBuilder);
146 }; 146 };
147 147
148 } // namespace compositor 148 } // namespace compositor
149 149
150 #endif // SERVICES_GFX_COMPOSITOR_GRAPH_SCENE_CONTENT_H_ 150 #endif // SERVICES_GFX_COMPOSITOR_GRAPH_SCENE_CONTENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698