skia2/include/gpu/gl/GrGLConfig_chrome.h
tomhudson@google.com 6bf38b59c9 Move GL-specific include files to their own subdirectory, to better
coexist alongside D3D backend.
Requires gyp change.

http://codereview.appspot.com/5665045/



git-svn-id: http://skia.googlecode.com/svn/trunk@3185 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-02-14 15:11:59 +00:00

38 lines
1.3 KiB
C

/*
* Copyright 2011 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#ifndef GrGLConfig_chrome_DEFINED
#define GrGLConfig_chrome_DEFINED
// glGetError() forces a sync with gpu process on chrome
#define GR_GL_CHECK_ERROR_START 0
// ANGLE creates a temp VB for vertex attributes not specified per-vertex.
#define GR_GL_NO_CONSTANT_ATTRIBUTES GR_WIN32_BUILD
// For RGBA teximage/readpixels ANGLE will sw-convert to/from BGRA.
#define GR_GL_RGBA_8888_PIXEL_OPS_SLOW GR_WIN32_BUILD
// ANGLE can go faster if the entire fbo is read rather than a subrect
#define GR_GL_FULL_READPIXELS_FASTER_THAN_PARTIAL GR_WIN32_BUILD
// cmd buffer allocates memory and memsets it to zero when it sees glBufferData
// with NULL.
#define GR_GL_USE_BUFFER_DATA_NULL_HINT 0
// chrome uses this to set the context on each GL call.
#define GR_GL_PER_GL_FUNC_CALLBACK 1
// Check error is even more expensive in chrome (cmd buffer flush). The
// compositor also doesn't check its allocations.
#define GR_GL_CHECK_ALLOC_WITH_GET_ERROR 0
// CheckFramebufferStatus in chrome synchronizes the gpu and renderer processes.
#define GR_GL_CHECK_FBO_STATUS_ONCE_PER_FORMAT 1
#endif