1// Copyright 2014 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "content/browser/renderer_host/test/no_transport_image_transport_factory_android.h"
6
7#include "cc/output/context_provider.h"
8#include "content/common/gpu/client/gl_helper.h"
9#include "ui/compositor/compositor.h"
10#include "ui/compositor/test/in_process_context_factory.h"
11
12namespace content {
13
14NoTransportImageTransportFactoryAndroid::
15    NoTransportImageTransportFactoryAndroid()
16    : context_factory_(new ui::InProcessContextFactory) {
17}
18
19NoTransportImageTransportFactoryAndroid::
20    ~NoTransportImageTransportFactoryAndroid() {
21}
22
23GLHelper* NoTransportImageTransportFactoryAndroid::GetGLHelper() {
24  if (!gl_helper_) {
25    context_provider_ = context_factory_->SharedMainThreadContextProvider();
26    gl_helper_.reset(new GLHelper(context_provider_->ContextGL(),
27                                  context_provider_->ContextSupport()));
28  }
29  return gl_helper_.get();
30}
31
32uint32 NoTransportImageTransportFactoryAndroid::GetChannelID() {
33  NOTREACHED();
34  return 0;
35}
36
37}  // namespace content
38