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

Unified Diff: chrome/browser/android/vr_shell/ui_elements.h

Issue 2668093002: VrShell background implemented in JS. (Closed)
Patch Set: Replaced content_quad with CONTENT filling, gradient renderer respects opacity, nits Created 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/android/vr_shell/ui_elements.h
diff --git a/chrome/browser/android/vr_shell/ui_elements.h b/chrome/browser/android/vr_shell/ui_elements.h
index 42c349058508660b945750d247c88f5696d33354..5040182025e74c14d34c20eff5cc675249388192 100644
--- a/chrome/browser/android/vr_shell/ui_elements.h
+++ b/chrome/browser/android/vr_shell/ui_elements.h
@@ -28,6 +28,16 @@ enum YAnchoring {
YBOTTOM
};
+enum Fill {
+ NONE = 0,
+ SPRITE = 1,
+ OPAQUE_GRADIENT = 2,
+ GRID_GRADIENT = 3,
+ // The element is the content quad. Only one content quad may be added to the
+ // scene.
+ CONTENT = 4
+};
+
struct ReversibleTransform {
ReversibleTransform();
@@ -72,7 +82,7 @@ struct ContentRectangle : public WorldRectangle {
// Valid IDs are non-negative.
int id = -1;
- // If a non-negative parent ID is specified, applicable tranformations
+ // If a non-negative parent ID is specified, applicable transformations
// are applied relative to the parent, rather than absolutely.
int parent_id = -1;
@@ -86,10 +96,6 @@ struct ContentRectangle : public WorldRectangle {
// rather than the world.
bool lock_to_fov = false;
- // If true, this element is the content quad. Only one content quad may be
- // added to the scene.
- bool content_quad = false;
-
// Specifies the region (in pixels) of a texture to render.
Recti copy_rect = {0, 0, 0, 0};
@@ -121,6 +127,13 @@ struct ContentRectangle : public WorldRectangle {
// Animations that affect the properties of the object over time.
std::vector<std::unique_ptr<Animation>> animations;
+ Fill fill = Fill::NONE;
+
+ Colorf edge_color = {1.0f, 1.0f, 1.0f, 1.0f};
+ Colorf center_color = {1.0f, 1.0f, 1.0f, 1.0f};
+
+ unsigned int tile_number;
+
private:
DISALLOW_COPY_AND_ASSIGN(ContentRectangle);
};
« no previous file with comments | « no previous file | chrome/browser/android/vr_shell/ui_scene.cc » ('j') | chrome/browser/android/vr_shell/ui_scene.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698