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

Side by Side Diff: cc/quads/yuv_video_draw_quad.h

Issue 1152473006: cc: Remove DrawQuad::IterateResoruces (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef CC_QUADS_YUV_VIDEO_DRAW_QUAD_H_ 5 #ifndef CC_QUADS_YUV_VIDEO_DRAW_QUAD_H_
6 #define CC_QUADS_YUV_VIDEO_DRAW_QUAD_H_ 6 #define CC_QUADS_YUV_VIDEO_DRAW_QUAD_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "cc/base/cc_export.h" 10 #include "cc/base/cc_export.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 unsigned y_plane_resource_id, 57 unsigned y_plane_resource_id,
58 unsigned u_plane_resource_id, 58 unsigned u_plane_resource_id,
59 unsigned v_plane_resource_id, 59 unsigned v_plane_resource_id,
60 unsigned a_plane_resource_id, 60 unsigned a_plane_resource_id,
61 ColorSpace color_space); 61 ColorSpace color_space);
62 62
63 gfx::RectF ya_tex_coord_rect; 63 gfx::RectF ya_tex_coord_rect;
64 gfx::RectF uv_tex_coord_rect; 64 gfx::RectF uv_tex_coord_rect;
65 gfx::Size ya_tex_size; 65 gfx::Size ya_tex_size;
66 gfx::Size uv_tex_size; 66 gfx::Size uv_tex_size;
67 unsigned y_plane_resource_id;
68 unsigned u_plane_resource_id;
69 unsigned v_plane_resource_id;
70 unsigned a_plane_resource_id;
71 ColorSpace color_space; 67 ColorSpace color_space;
72 68
73 void IterateResources(const ResourceIteratorCallback& callback) override;
74
75 static const YUVVideoDrawQuad* MaterialCast(const DrawQuad*); 69 static const YUVVideoDrawQuad* MaterialCast(const DrawQuad*);
76 70
71 ResourceId y_plane_resource_id() const {
72 return resources.ids[kYPlaneResourceIdIndex];
73 }
74 ResourceId u_plane_resource_id() const {
75 return resources.ids[kUPlaneResourceIdIndex];
76 }
77 ResourceId v_plane_resource_id() const {
78 return resources.ids[kVPlaneResourceIdIndex];
79 }
80 ResourceId a_plane_resource_id() const {
81 return resources.ids[kAPlaneResourceIdIndex];
82 }
83
77 private: 84 private:
85 static const size_t kYPlaneResourceIdIndex = 0;
86 static const size_t kUPlaneResourceIdIndex = 1;
87 static const size_t kVPlaneResourceIdIndex = 2;
88 static const size_t kAPlaneResourceIdIndex = 3;
89
78 void ExtendValue(base::trace_event::TracedValue* value) const override; 90 void ExtendValue(base::trace_event::TracedValue* value) const override;
79 }; 91 };
80 92
81 } // namespace cc 93 } // namespace cc
82 94
83 #endif // CC_QUADS_YUV_VIDEO_DRAW_QUAD_H_ 95 #endif // CC_QUADS_YUV_VIDEO_DRAW_QUAD_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698