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
3 // found in the LICENSE file.
5 // These functions emulate GLES2 over command buffers.
7 #ifndef GPU_COMMAND_BUFFER_CLIENT_GLES2_LIB_H_
8 #define GPU_COMMAND_BUFFER_CLIENT_GLES2_LIB_H_
10 #include "gpu/command_buffer/client/gles2_c_lib_export.h"
11 #include "gpu/command_buffer/client/gles2_interface.h"
15 typedef void (*GLES2FunctionPointer
)(void);
19 gles2::GLES2FunctionPointer func
;
22 // Initialize the GLES2 library.
23 GLES2_C_LIB_EXPORT
void Initialize();
25 // Terminate the GLES2 library.
26 GLES2_C_LIB_EXPORT
void Terminate();
28 // Get the current GL context.
29 GLES2_C_LIB_EXPORT
gpu::gles2::GLES2Interface
* GetGLContext();
31 // Set the current GL context.
32 GLES2_C_LIB_EXPORT
void SetGLContext(gpu::gles2::GLES2Interface
* impl
);
34 GLES2_C_LIB_EXPORT GLES2FunctionPointer
GetGLFunctionPointer(const char* name
);
38 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_LIB_H_