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

Side by Side Diff: cc/layers/texture_layer.h

Issue 139233002: [#4] Pass gfx structs by const ref (gfx::PointF) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Corrected as per review comments! Created 6 years, 11 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 | « cc/layers/layer_position_constraint_unittest.cc ('k') | cc/layers/texture_layer.cc » ('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 2010 The Chromium Authors. All rights reserved. 1 // Copyright 2010 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_LAYERS_TEXTURE_LAYER_H_ 5 #ifndef CC_LAYERS_TEXTURE_LAYER_H_
6 #define CC_LAYERS_TEXTURE_LAYER_H_ 6 #define CC_LAYERS_TEXTURE_LAYER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 void ClearClient(); 92 void ClearClient();
93 93
94 virtual scoped_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl) 94 virtual scoped_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl)
95 OVERRIDE; 95 OVERRIDE;
96 96
97 // Sets whether this texture should be Y-flipped at draw time. Defaults to 97 // Sets whether this texture should be Y-flipped at draw time. Defaults to
98 // true. 98 // true.
99 void SetFlipped(bool flipped); 99 void SetFlipped(bool flipped);
100 100
101 // Sets a UV transform to be used at draw time. Defaults to (0, 0) and (1, 1). 101 // Sets a UV transform to be used at draw time. Defaults to (0, 0) and (1, 1).
102 void SetUV(gfx::PointF top_left, gfx::PointF bottom_right); 102 void SetUV(const gfx::PointF& top_left, const gfx::PointF& bottom_right);
103 103
104 // Sets an opacity value per vertex. It will be multiplied by the layer 104 // Sets an opacity value per vertex. It will be multiplied by the layer
105 // opacity value. 105 // opacity value.
106 void SetVertexOpacity(float bottom_left, 106 void SetVertexOpacity(float bottom_left,
107 float top_left, 107 float top_left,
108 float top_right, 108 float top_right,
109 float bottom_right); 109 float bottom_right);
110 110
111 // Sets whether the alpha channel is premultiplied or unpremultiplied. 111 // Sets whether the alpha channel is premultiplied or unpremultiplied.
112 // Defaults to true. 112 // Defaults to true.
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 166
167 unsigned texture_id_; 167 unsigned texture_id_;
168 scoped_ptr<MailboxHolder::MainThreadReference> holder_ref_; 168 scoped_ptr<MailboxHolder::MainThreadReference> holder_ref_;
169 bool needs_set_mailbox_; 169 bool needs_set_mailbox_;
170 170
171 DISALLOW_COPY_AND_ASSIGN(TextureLayer); 171 DISALLOW_COPY_AND_ASSIGN(TextureLayer);
172 }; 172 };
173 173
174 } // namespace cc 174 } // namespace cc
175 #endif // CC_LAYERS_TEXTURE_LAYER_H_ 175 #endif // CC_LAYERS_TEXTURE_LAYER_H_
OLDNEW
« no previous file with comments | « cc/layers/layer_position_constraint_unittest.cc ('k') | cc/layers/texture_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698