OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #include "content/common/gpu/client/gl_helper_scaling.h" | 5 #include "content/common/gpu/client/gl_helper_scaling.h" |
6 | 6 |
7 #include <deque> | 7 #include <deque> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/debug/trace_event.h" | 12 #include "base/debug/trace_event.h" |
13 #include "base/lazy_instance.h" | 13 #include "base/lazy_instance.h" |
14 #include "base/logging.h" | 14 #include "base/logging.h" |
15 #include "base/memory/ref_counted.h" | 15 #include "base/memory/ref_counted.h" |
16 #include "base/message_loop.h" | 16 #include "base/message_loop.h" |
17 #include "base/time.h" | 17 #include "base/time.h" |
18 #include "third_party/WebKit/Source/Platform/chromium/public/WebCString.h" | 18 #include "third_party/WebKit/public/platform/WebCString.h" |
19 #include "third_party/skia/include/core/SkRegion.h" | 19 #include "third_party/skia/include/core/SkRegion.h" |
20 #include "ui/gfx/rect.h" | 20 #include "ui/gfx/rect.h" |
21 #include "ui/gfx/size.h" | 21 #include "ui/gfx/size.h" |
22 #include "ui/gl/gl_bindings.h" | 22 #include "ui/gl/gl_bindings.h" |
23 | 23 |
24 using WebKit::WebGLId; | 24 using WebKit::WebGLId; |
25 using WebKit::WebGraphicsContext3D; | 25 using WebKit::WebGraphicsContext3D; |
26 | 26 |
27 namespace content { | 27 namespace content { |
28 | 28 |
(...skipping 709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
738 context_->uniform2f(dst_pixelsize_location_, | 738 context_->uniform2f(dst_pixelsize_location_, |
739 static_cast<float>(dst_size.width()), | 739 static_cast<float>(dst_size.width()), |
740 static_cast<float>(dst_size.height())); | 740 static_cast<float>(dst_size.height())); |
741 | 741 |
742 context_->uniform2f(scaling_vector_location_, | 742 context_->uniform2f(scaling_vector_location_, |
743 scale_x ? 1.0 : 0.0, | 743 scale_x ? 1.0 : 0.0, |
744 scale_x ? 0.0 : 1.0); | 744 scale_x ? 0.0 : 1.0); |
745 } | 745 } |
746 | 746 |
747 } // namespace content | 747 } // namespace content |
OLD | NEW |