OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "mojo/examples/sample_app/gles2_client_impl.h" | 5 #include "mojo/examples/sample_app/gles2_client_impl.h" |
6 | 6 |
7 #include <GLES2/gl2.h> | 7 #include <GLES2/gl2.h> |
8 #include <GLES2/gl2ext.h> | 8 #include <GLES2/gl2ext.h> |
9 #include <math.h> | 9 #include <math.h> |
10 | 10 |
11 #include "mojo/public/gles2/gles2.h" | 11 #include "mojo/public/c/gles2/gles2.h" |
12 #include "ui/events/event_constants.h" | 12 #include "ui/events/event_constants.h" |
13 | 13 |
14 namespace mojo { | 14 namespace mojo { |
15 namespace examples { | 15 namespace examples { |
16 namespace { | 16 namespace { |
17 | 17 |
18 float CalculateDragDistance(const gfx::PointF& start, const Point& end) { | 18 float CalculateDragDistance(const gfx::PointF& start, const Point& end) { |
19 return hypot(start.x() - end.x(), start.y() - end.y()); | 19 return hypot(start.x() - end.x(), start.y() - end.y()); |
20 } | 20 } |
21 | 21 |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
112 last_time_ = GetTimeTicksNow(); | 112 last_time_ = GetTimeTicksNow(); |
113 } | 113 } |
114 | 114 |
115 void GLES2ClientImpl::CancelAnimationFrames() { | 115 void GLES2ClientImpl::CancelAnimationFrames() { |
116 getting_animation_frames_ = false; | 116 getting_animation_frames_ = false; |
117 MojoGLES2CancelAnimationFrames(context_); | 117 MojoGLES2CancelAnimationFrames(context_); |
118 } | 118 } |
119 | 119 |
120 } // namespace examples | 120 } // namespace examples |
121 } // namespace mojo | 121 } // namespace mojo |
OLD | NEW |