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

Side by Side Diff: content/browser/renderer_host/compositor_impl_android.cc

Issue 12614013: Plumb cc::LatencyInfo through command buffer and output surface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | Annotate | Revision Log
OLDNEW
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/browser/renderer_host/compositor_impl_android.h" 5 #include "content/browser/renderer_host/compositor_impl_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 #include <android/native_window_jni.h> 8 #include <android/native_window_jni.h>
9 #include <map> 9 #include <map>
10 10
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 42
43 namespace { 43 namespace {
44 44
45 // Used for drawing directly to the screen. Bypasses resizing and swaps. 45 // Used for drawing directly to the screen. Bypasses resizing and swaps.
46 class DirectOutputSurface : public cc::OutputSurface { 46 class DirectOutputSurface : public cc::OutputSurface {
47 public: 47 public:
48 DirectOutputSurface(scoped_ptr<WebKit::WebGraphicsContext3D> context3d) 48 DirectOutputSurface(scoped_ptr<WebKit::WebGraphicsContext3D> context3d)
49 : cc::OutputSurface(context3d.Pass()) {} 49 : cc::OutputSurface(context3d.Pass()) {}
50 50
51 virtual void Reshape(gfx::Size size) OVERRIDE {} 51 virtual void Reshape(gfx::Size size) OVERRIDE {}
52 virtual void PostSubBuffer(gfx::Rect rect) OVERRIDE {} 52 virtual void PostSubBuffer(gfx::Rect rect, const cc::LatencyInfo&) OVERRIDE {}
53 virtual void SwapBuffers() OVERRIDE {} 53 virtual void SwapBuffers(const cc::LatencyInfo&) OVERRIDE {}
54 }; 54 };
55 55
56 static bool g_initialized = false; 56 static bool g_initialized = false;
57 static webkit_glue::WebThreadImpl* g_impl_thread = NULL; 57 static webkit_glue::WebThreadImpl* g_impl_thread = NULL;
58 static bool g_use_direct_gl = false; 58 static bool g_use_direct_gl = false;
59 59
60 } // anonymous namespace 60 } // anonymous namespace
61 61
62 namespace content { 62 namespace content {
63 63
(...skipping 380 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 case ANDROID_BITMAP_FORMAT_RGBA_8888: 444 case ANDROID_BITMAP_FORMAT_RGBA_8888:
445 return GL_UNSIGNED_BYTE; 445 return GL_UNSIGNED_BYTE;
446 break; 446 break;
447 case ANDROID_BITMAP_FORMAT_RGB_565: 447 case ANDROID_BITMAP_FORMAT_RGB_565:
448 default: 448 default:
449 return GL_UNSIGNED_SHORT_5_6_5; 449 return GL_UNSIGNED_SHORT_5_6_5;
450 } 450 }
451 } 451 }
452 452
453 } // namespace content 453 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698