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

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

Issue 13844021: Move compositor thread input handling logic into content (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix win component build Created 7 years, 7 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 352 matching lines...) Expand 10 before | Expand all | Expand 10 after
363 false, 363 false,
364 CAUSE_FOR_GPU_LAUNCH_WEBGRAPHICSCONTEXT3DCOMMANDBUFFERIMPL_INITIALIZE)) { 364 CAUSE_FOR_GPU_LAUNCH_WEBGRAPHICSCONTEXT3DCOMMANDBUFFERIMPL_INITIALIZE)) {
365 LOG(ERROR) << "Failed to create 3D context for compositor."; 365 LOG(ERROR) << "Failed to create 3D context for compositor.";
366 return scoped_ptr<cc::OutputSurface>(); 366 return scoped_ptr<cc::OutputSurface>();
367 } 367 }
368 return make_scoped_ptr(new cc::OutputSurface( 368 return make_scoped_ptr(new cc::OutputSurface(
369 context.PassAs<WebKit::WebGraphicsContext3D>())); 369 context.PassAs<WebKit::WebGraphicsContext3D>()));
370 } 370 }
371 } 371 }
372 372
373 scoped_ptr<cc::InputHandlerClient> CompositorImpl::CreateInputHandlerClient() {
374 return scoped_ptr<cc::InputHandlerClient>();
375 }
376
377 void CompositorImpl::DidCompleteSwapBuffers() { 373 void CompositorImpl::DidCompleteSwapBuffers() {
378 client_->OnSwapBuffersCompleted(); 374 client_->OnSwapBuffersCompleted();
379 } 375 }
380 376
381 void CompositorImpl::ScheduleComposite() { 377 void CompositorImpl::ScheduleComposite() {
382 client_->ScheduleComposite(); 378 client_->ScheduleComposite();
383 } 379 }
384 380
385 scoped_refptr<cc::ContextProvider> 381 scoped_refptr<cc::ContextProvider>
386 CompositorImpl::OffscreenContextProviderForMainThread() { 382 CompositorImpl::OffscreenContextProviderForMainThread() {
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
460 case ANDROID_BITMAP_FORMAT_RGBA_8888: 456 case ANDROID_BITMAP_FORMAT_RGBA_8888:
461 return GL_UNSIGNED_BYTE; 457 return GL_UNSIGNED_BYTE;
462 break; 458 break;
463 case ANDROID_BITMAP_FORMAT_RGB_565: 459 case ANDROID_BITMAP_FORMAT_RGB_565:
464 default: 460 default:
465 return GL_UNSIGNED_SHORT_5_6_5; 461 return GL_UNSIGNED_SHORT_5_6_5;
466 } 462 }
467 } 463 }
468 464
469 } // namespace content 465 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698