Commit f4486fdf by Nicolas Capens

Rename the desktop OpenGL namespace to gl.

Bug 18962347 Change-Id: I0bb263b749d3af3362b2fdc02d81ab856e0f46b4 Reviewed-on: https://swiftshader-review.googlesource.com/1770Reviewed-by: 's avatarNicolas Capens <capn@google.com> Tested-by: 's avatarNicolas Capens <capn@google.com>
parent 5597eef8
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#include "VertexDataManager.h" #include "VertexDataManager.h"
#include "IndexDataManager.h" #include "IndexDataManager.h"
namespace es2 namespace gl
{ {
Buffer::Buffer(GLuint id) : RefCountObject(id) Buffer::Buffer(GLuint id) : RefCountObject(id)
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
#include <cstddef> #include <cstddef>
#include <vector> #include <vector>
namespace es2 namespace gl
{ {
class Buffer : public gl::RefCountObject class Buffer : public gl::RefCountObject
{ {
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
// or implied, including but not limited to any patent rights, are granted to you. // or implied, including but not limited to any patent rights, are granted to you.
// //
// Context.cpp: Implements the es2::Context class, managing all GL state and performing // Context.cpp: Implements the gl::Context class, managing all GL state and performing
// rendering operations. It is the GLES2 specific implementation of EGLContext. // rendering operations. It is the GLES2 specific implementation of EGLContext.
#include "Context.h" #include "Context.h"
...@@ -37,12 +37,12 @@ ...@@ -37,12 +37,12 @@
#undef near #undef near
#undef far #undef far
namespace es2 namespace gl
{ {
Context::Context(const egl::Config *config, const Context *shareContext) : mConfig(config) Context::Context(const egl::Config *config, const Context *shareContext) : mConfig(config)
{ {
sw::Context *context = new sw::Context(); sw::Context *context = new sw::Context();
device = new es2::Device(context); device = new gl::Device(context);
mFenceHandleAllocator.setBaseHandle(0); mFenceHandleAllocator.setBaseHandle(0);
...@@ -3002,7 +3002,7 @@ void Context::blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1 ...@@ -3002,7 +3002,7 @@ void Context::blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1
void Context::bindTexImage(egl::Surface *surface) void Context::bindTexImage(egl::Surface *surface)
{ {
es2::Texture2D *textureObject = getTexture2D(); gl::Texture2D *textureObject = getTexture2D();
if(textureObject) if(textureObject)
{ {
...@@ -3033,14 +3033,14 @@ EGLenum Context::validateSharedImage(EGLenum target, GLuint name, GLuint texture ...@@ -3033,14 +3033,14 @@ EGLenum Context::validateSharedImage(EGLenum target, GLuint name, GLuint texture
return EGL_BAD_PARAMETER; return EGL_BAD_PARAMETER;
} }
if(textureLevel >= es2::IMPLEMENTATION_MAX_TEXTURE_LEVELS) if(textureLevel >= gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS)
{ {
return EGL_BAD_MATCH; return EGL_BAD_MATCH;
} }
if(textureTarget != GL_NONE) if(textureTarget != GL_NONE)
{ {
es2::Texture *texture = getTexture(name); gl::Texture *texture = getTexture(name);
if(!texture || texture->getTarget() != textureTarget) if(!texture || texture->getTarget() != textureTarget)
{ {
...@@ -3064,7 +3064,7 @@ EGLenum Context::validateSharedImage(EGLenum target, GLuint name, GLuint texture ...@@ -3064,7 +3064,7 @@ EGLenum Context::validateSharedImage(EGLenum target, GLuint name, GLuint texture
} }
else if(target == EGL_GL_RENDERBUFFER_KHR) else if(target == EGL_GL_RENDERBUFFER_KHR)
{ {
es2::Renderbuffer *renderbuffer = getRenderbuffer(name); gl::Renderbuffer *renderbuffer = getRenderbuffer(name);
if(!renderbuffer) if(!renderbuffer)
{ {
...@@ -3098,13 +3098,13 @@ egl::Image *Context::createSharedImage(EGLenum target, GLuint name, GLuint textu ...@@ -3098,13 +3098,13 @@ egl::Image *Context::createSharedImage(EGLenum target, GLuint name, GLuint textu
if(textureTarget != GL_NONE) if(textureTarget != GL_NONE)
{ {
es2::Texture *texture = getTexture(name); gl::Texture *texture = getTexture(name);
return texture->createSharedImage(textureTarget, textureLevel); return texture->createSharedImage(textureTarget, textureLevel);
} }
else if(target == EGL_GL_RENDERBUFFER_KHR) else if(target == EGL_GL_RENDERBUFFER_KHR)
{ {
es2::Renderbuffer *renderbuffer = getRenderbuffer(name); gl::Renderbuffer *renderbuffer = getRenderbuffer(name);
return renderbuffer->createSharedImage(); return renderbuffer->createSharedImage();
} }
...@@ -3123,8 +3123,8 @@ Device *Context::getDevice() ...@@ -3123,8 +3123,8 @@ Device *Context::getDevice()
// Exported functions for use by EGL // Exported functions for use by EGL
extern "C" extern "C"
{ {
es2::Context *glCreateContext(const egl::Config *config, const es2::Context *shareContext) gl::Context *glCreateContext(const egl::Config *config, const gl::Context *shareContext)
{ {
return new es2::Context(config, shareContext); return new gl::Context(config, shareContext);
} }
} }
...@@ -38,7 +38,7 @@ class Surface; ...@@ -38,7 +38,7 @@ class Surface;
class Config; class Config;
} }
namespace es2 namespace gl
{ {
struct TranslatedAttribute; struct TranslatedAttribute;
struct TranslatedIndexData; struct TranslatedIndexData;
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
bool localShaderConstants = false; bool localShaderConstants = false;
namespace es2 namespace gl
{ {
using namespace sw; using namespace sw;
......
...@@ -19,7 +19,7 @@ namespace egl ...@@ -19,7 +19,7 @@ namespace egl
class Image; class Image;
} }
namespace es2 namespace gl
{ {
class Texture; class Texture;
class Image; class Image;
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
#include "main.h" #include "main.h"
#include "Common/Thread.hpp" #include "Common/Thread.hpp"
namespace es2 namespace gl
{ {
Fence::Fence() Fence::Fence()
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#define GL_APICALL #define GL_APICALL
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
namespace es2 namespace gl
{ {
class Fence class Fence
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#include "Texture.h" #include "Texture.h"
#include "utilities.h" #include "utilities.h"
namespace es2 namespace gl
{ {
Framebuffer::Framebuffer() Framebuffer::Framebuffer()
...@@ -245,7 +245,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples) ...@@ -245,7 +245,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples)
if(mColorbufferType == GL_RENDERBUFFER) if(mColorbufferType == GL_RENDERBUFFER)
{ {
if(!es2::IsColorRenderable(colorbuffer->getFormat())) if(!gl::IsColorRenderable(colorbuffer->getFormat()))
{ {
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT; return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
} }
...@@ -262,7 +262,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples) ...@@ -262,7 +262,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples)
return GL_FRAMEBUFFER_UNSUPPORTED; return GL_FRAMEBUFFER_UNSUPPORTED;
} }
if(es2::IsDepthTexture(format) || es2::IsStencilTexture(format)) if(gl::IsDepthTexture(format) || gl::IsStencilTexture(format))
{ {
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT; return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
} }
...@@ -297,14 +297,14 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples) ...@@ -297,14 +297,14 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples)
if(mDepthbufferType == GL_RENDERBUFFER) if(mDepthbufferType == GL_RENDERBUFFER)
{ {
if(!es2::IsDepthRenderable(depthbuffer->getFormat())) if(!gl::IsDepthRenderable(depthbuffer->getFormat()))
{ {
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT; return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
} }
} }
else if(IsTextureTarget(mDepthbufferType)) else if(IsTextureTarget(mDepthbufferType))
{ {
if(!es2::IsDepthTexture(depthbuffer->getFormat())) if(!gl::IsDepthTexture(depthbuffer->getFormat()))
{ {
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT; return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
} }
...@@ -347,7 +347,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples) ...@@ -347,7 +347,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples)
if(mStencilbufferType == GL_RENDERBUFFER) if(mStencilbufferType == GL_RENDERBUFFER)
{ {
if(!es2::IsStencilRenderable(stencilbuffer->getFormat())) if(!gl::IsStencilRenderable(stencilbuffer->getFormat()))
{ {
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT; return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
} }
...@@ -356,7 +356,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples) ...@@ -356,7 +356,7 @@ GLenum Framebuffer::completeness(int &width, int &height, int &samples)
{ {
GLenum internalformat = stencilbuffer->getFormat(); GLenum internalformat = stencilbuffer->getFormat();
if(!es2::IsStencilTexture(internalformat)) if(!gl::IsStencilTexture(internalformat))
{ {
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT; return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
} }
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
#define GL_APICALL #define GL_APICALL
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
namespace es2 namespace gl
{ {
class Renderbuffer; class Renderbuffer;
class Colorbuffer; class Colorbuffer;
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
#include "main.h" #include "main.h"
namespace es2 namespace gl
{ {
HandleAllocator::HandleAllocator() : mBaseValue(1), mNextValue(1) HandleAllocator::HandleAllocator() : mBaseValue(1), mNextValue(1)
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#include <vector> #include <vector>
namespace es2 namespace gl
{ {
class HandleAllocator class HandleAllocator
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
#include <GLES2/gl2ext.h> #include <GLES2/gl2ext.h>
namespace es2 namespace gl
{ {
static sw::Resource *getParentResource(Texture *texture) static sw::Resource *getParentResource(Texture *texture)
{ {
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
#define GL_APICALL #define GL_APICALL
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
namespace es2 namespace gl
{ {
class Texture; class Texture;
......
...@@ -25,7 +25,7 @@ namespace ...@@ -25,7 +25,7 @@ namespace
enum { INITIAL_INDEX_BUFFER_SIZE = 4096 * sizeof(GLuint) }; enum { INITIAL_INDEX_BUFFER_SIZE = 4096 * sizeof(GLuint) };
} }
namespace es2 namespace gl
{ {
IndexDataManager::IndexDataManager() IndexDataManager::IndexDataManager()
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#define GL_APICALL #define GL_APICALL
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
namespace es2 namespace gl
{ {
struct TranslatedIndexData struct TranslatedIndexData
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
#include <string> #include <string>
#include <stdlib.h> #include <stdlib.h>
namespace es2 namespace gl
{ {
unsigned int Program::currentSerial = 1; unsigned int Program::currentSerial = 1;
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
#include <vector> #include <vector>
#include <set> #include <set>
namespace es2 namespace gl
{ {
class Device; class Device;
class ResourceManager; class ResourceManager;
...@@ -163,7 +163,7 @@ namespace es2 ...@@ -163,7 +163,7 @@ namespace es2
static unsigned int issueSerial(); static unsigned int issueSerial();
private: private:
es2::Device *device; gl::Device *device;
FragmentShader *fragmentShader; FragmentShader *fragmentShader;
VertexShader *vertexShader; VertexShader *vertexShader;
......
...@@ -9,14 +9,14 @@ ...@@ -9,14 +9,14 @@
// or implied, including but not limited to any patent rights, are granted to you. // or implied, including but not limited to any patent rights, are granted to you.
// //
// Query.cpp: Implements the es2::Query class // Query.cpp: Implements the gl::Query class
#include "Query.h" #include "Query.h"
#include "main.h" #include "main.h"
#include "Common/Thread.hpp" #include "Common/Thread.hpp"
namespace es2 namespace gl
{ {
Query::Query(GLuint id, GLenum type) : RefCountObject(id) Query::Query(GLuint id, GLenum type) : RefCountObject(id)
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
// or implied, including but not limited to any patent rights, are granted to you. // or implied, including but not limited to any patent rights, are granted to you.
// //
// Query.h: Defines the es2::Query class // Query.h: Defines the gl::Query class
#ifndef LIBGL_QUERY_H_ #ifndef LIBGL_QUERY_H_
#define LIBGL_QUERY_H_ #define LIBGL_QUERY_H_
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#define GL_APICALL #define GL_APICALL
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
namespace es2 namespace gl
{ {
class Query : public gl::RefCountObject class Query : public gl::RefCountObject
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#include "Texture.h" #include "Texture.h"
#include "utilities.h" #include "utilities.h"
namespace es2 namespace gl
{ {
RenderbufferInterface::RenderbufferInterface() RenderbufferInterface::RenderbufferInterface()
{ {
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#define GL_APICALL #define GL_APICALL
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
namespace es2 namespace gl
{ {
class Texture2D; class Texture2D;
class TextureCubeMap; class TextureCubeMap;
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#include "Shader.h" #include "Shader.h"
#include "Texture.h" #include "Texture.h"
namespace es2 namespace gl
{ {
ResourceManager::ResourceManager() ResourceManager::ResourceManager()
{ {
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
#include <map> #include <map>
namespace es2 namespace gl
{ {
class Buffer; class Buffer;
class Shader; class Shader;
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
#include <string> #include <string>
namespace es2 namespace gl
{ {
bool Shader::compilerInitialized = false; bool Shader::compilerInitialized = false;
......
...@@ -32,7 +32,7 @@ namespace glsl ...@@ -32,7 +32,7 @@ namespace glsl
class OutputASM; class OutputASM;
} }
namespace es2 namespace gl
{ {
class Shader : public glsl::Shader class Shader : public glsl::Shader
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
#include <algorithm> #include <algorithm>
namespace es2 namespace gl
{ {
Texture::Texture(GLuint id) : egl::Texture(id) Texture::Texture(GLuint id) : egl::Texture(id)
...@@ -1166,7 +1166,7 @@ extern "C" ...@@ -1166,7 +1166,7 @@ extern "C"
{ {
if(config) if(config)
{ {
return new es2::Image(0, width, height, config->mAlphaSize ? GL_RGBA : GL_RGB, GL_UNSIGNED_BYTE); return new gl::Image(0, width, height, config->mAlphaSize ? GL_RGBA : GL_RGB, GL_UNSIGNED_BYTE);
} }
return 0; return 0;
...@@ -1205,7 +1205,7 @@ extern "C" ...@@ -1205,7 +1205,7 @@ extern "C"
UNREACHABLE(); UNREACHABLE();
} }
es2::Image *surface = new es2::Image(0, width, height, format, multiSampleDepth, lockable, true); gl::Image *surface = new gl::Image(0, width, height, format, multiSampleDepth, lockable, true);
if(!surface) if(!surface)
{ {
......
...@@ -33,7 +33,7 @@ class Surface; ...@@ -33,7 +33,7 @@ class Surface;
class Config; class Config;
} }
namespace es2 namespace gl
{ {
class Framebuffer; class Framebuffer;
......
...@@ -24,7 +24,7 @@ namespace ...@@ -24,7 +24,7 @@ namespace
enum {INITIAL_STREAM_BUFFER_SIZE = 1024 * 1024}; enum {INITIAL_STREAM_BUFFER_SIZE = 1024 * 1024};
} }
namespace es2 namespace gl
{ {
VertexDataManager::VertexDataManager(Context *context) : mContext(context) VertexDataManager::VertexDataManager(Context *context) : mContext(context)
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
#define GL_APICALL #define GL_APICALL
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
namespace es2 namespace gl
{ {
struct TranslatedAttribute struct TranslatedAttribute
......
...@@ -103,15 +103,15 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved ...@@ -103,15 +103,15 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved
} }
#endif #endif
namespace es2 namespace gl
{ {
es2::Context *getContext() gl::Context *getContext()
{ {
egl::Context *context = egl::getCurrentContext(); egl::Context *context = egl::getCurrentContext();
if(context && context->getClientVersion() == 2) if(context && context->getClientVersion() == 2)
{ {
return static_cast<es2::Context*>(context); return static_cast<gl::Context*>(context);
} }
return 0; return 0;
...@@ -143,7 +143,7 @@ GLint getClientVersion() ...@@ -143,7 +143,7 @@ GLint getClientVersion()
// Records an error code // Records an error code
void error(GLenum errorCode) void error(GLenum errorCode)
{ {
es2::Context *context = es2::getContext(); gl::Context *context = gl::getContext();
if(context) if(context)
{ {
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#include <GLES2/gl2.h> #include <GLES2/gl2.h>
#include <GLES2/gl2ext.h> #include <GLES2/gl2ext.h>
namespace es2 namespace gl
{ {
Context *getContext(); Context *getContext();
egl::Display *getDisplay(); egl::Display *getDisplay();
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
#include <math.h> #include <math.h>
namespace es2 namespace gl
{ {
inline bool isPow2(int x) inline bool isPow2(int x)
{ {
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#include <limits> #include <limits>
#include <stdio.h> #include <stdio.h>
namespace es2 namespace gl
{ {
int UniformComponentCount(GLenum type) int UniformComponentCount(GLenum type)
{ {
...@@ -463,7 +463,7 @@ namespace es2sw ...@@ -463,7 +463,7 @@ namespace es2sw
return sw::STENCIL_ALWAYS; return sw::STENCIL_ALWAYS;
} }
sw::Color<float> ConvertColor(es2::Color color) sw::Color<float> ConvertColor(gl::Color color)
{ {
return sw::Color<float>(color.red, color.green, color.blue, color.alpha); return sw::Color<float>(color.red, color.green, color.blue, color.alpha);
} }
...@@ -615,36 +615,36 @@ namespace es2sw ...@@ -615,36 +615,36 @@ namespace es2sw
} }
} }
bool ConvertPrimitiveType(GLenum primitiveType, GLsizei elementCount, es2::PrimitiveType &swPrimitiveType, int &primitiveCount) bool ConvertPrimitiveType(GLenum primitiveType, GLsizei elementCount, gl::PrimitiveType &swPrimitiveType, int &primitiveCount)
{ {
switch(primitiveType) switch(primitiveType)
{ {
case GL_POINTS: case GL_POINTS:
swPrimitiveType = es2::DRAW_POINTLIST; swPrimitiveType = gl::DRAW_POINTLIST;
primitiveCount = elementCount; primitiveCount = elementCount;
break; break;
case GL_LINES: case GL_LINES:
swPrimitiveType = es2::DRAW_LINELIST; swPrimitiveType = gl::DRAW_LINELIST;
primitiveCount = elementCount / 2; primitiveCount = elementCount / 2;
break; break;
case GL_LINE_LOOP: case GL_LINE_LOOP:
swPrimitiveType = es2::DRAW_LINELOOP; swPrimitiveType = gl::DRAW_LINELOOP;
primitiveCount = elementCount; primitiveCount = elementCount;
break; break;
case GL_LINE_STRIP: case GL_LINE_STRIP:
swPrimitiveType = es2::DRAW_LINESTRIP; swPrimitiveType = gl::DRAW_LINESTRIP;
primitiveCount = elementCount - 1; primitiveCount = elementCount - 1;
break; break;
case GL_TRIANGLES: case GL_TRIANGLES:
swPrimitiveType = es2::DRAW_TRIANGLELIST; swPrimitiveType = gl::DRAW_TRIANGLELIST;
primitiveCount = elementCount / 3; primitiveCount = elementCount / 3;
break; break;
case GL_TRIANGLE_STRIP: case GL_TRIANGLE_STRIP:
swPrimitiveType = es2::DRAW_TRIANGLESTRIP; swPrimitiveType = gl::DRAW_TRIANGLESTRIP;
primitiveCount = elementCount - 2; primitiveCount = elementCount - 2;
break; break;
case GL_TRIANGLE_FAN: case GL_TRIANGLE_FAN:
swPrimitiveType = es2::DRAW_TRIANGLEFAN; swPrimitiveType = gl::DRAW_TRIANGLEFAN;
primitiveCount = elementCount - 2; primitiveCount = elementCount - 2;
break; break;
default: default:
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
#include <string> #include <string>
namespace es2 namespace gl
{ {
struct Color; struct Color;
...@@ -57,7 +57,7 @@ namespace es2sw ...@@ -57,7 +57,7 @@ namespace es2sw
{ {
sw::DepthCompareMode ConvertDepthComparison(GLenum comparison); sw::DepthCompareMode ConvertDepthComparison(GLenum comparison);
sw::StencilCompareMode ConvertStencilComparison(GLenum comparison); sw::StencilCompareMode ConvertStencilComparison(GLenum comparison);
sw::Color<float> ConvertColor(es2::Color color); sw::Color<float> ConvertColor(gl::Color color);
sw::BlendFactor ConvertBlendFunc(GLenum blend); sw::BlendFactor ConvertBlendFunc(GLenum blend);
sw::BlendOperation ConvertBlendOp(GLenum blendOp); sw::BlendOperation ConvertBlendOp(GLenum blendOp);
sw::StencilOperation ConvertStencilOp(GLenum stencilOp); sw::StencilOperation ConvertStencilOp(GLenum stencilOp);
...@@ -66,7 +66,7 @@ namespace es2sw ...@@ -66,7 +66,7 @@ namespace es2sw
unsigned int ConvertColorMask(bool red, bool green, bool blue, bool alpha); unsigned int ConvertColorMask(bool red, bool green, bool blue, bool alpha);
sw::FilterType ConvertMagFilter(GLenum magFilter); sw::FilterType ConvertMagFilter(GLenum magFilter);
void ConvertMinFilter(GLenum texFilter, sw::FilterType *minFilter, sw::MipmapType *mipFilter, float maxAnisotropy); void ConvertMinFilter(GLenum texFilter, sw::FilterType *minFilter, sw::MipmapType *mipFilter, float maxAnisotropy);
bool ConvertPrimitiveType(GLenum primitiveType, GLsizei elementCount, es2::PrimitiveType &swPrimitiveType, int &primitiveCount); bool ConvertPrimitiveType(GLenum primitiveType, GLsizei elementCount, gl::PrimitiveType &swPrimitiveType, int &primitiveCount);
sw::Format ConvertRenderbufferFormat(GLenum format); sw::Format ConvertRenderbufferFormat(GLenum format);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment