Removes mConfig from Context, as it was only used for setting unused default values.

TRAC #21819 Signed-off-by: Daniel Koch Author: Shannon Woods git-svn-id: https://angleproject.googlecode.com/svn/branches/dx11proto@1345 736b8ea6-26fd-11df-bfd4-992fa37f6226
parent 4cfba2a9
......@@ -462,9 +462,7 @@ EGLContext Display::createContext(EGLConfig configHandle, const gl::Context *sha
return NULL;
}
const egl::Config *config = mConfigSet.get(configHandle);
gl::Context *context = glCreateContext(config, shareContext, notifyResets, robustAccess);
gl::Context *context = glCreateContext(shareContext, notifyResets, robustAccess);
mContextSet.insert(context);
return context;
......
......@@ -35,7 +35,7 @@
namespace gl
{
Context::Context(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess) : mConfig(config)
Context::Context(const gl::Context *shareContext, bool notifyResets, bool robustAccess)
{
ASSERT(robustAccess == false); // Unimplemented
......@@ -96,15 +96,15 @@ Context::Context(const egl::Config *config, const gl::Context *shareContext, boo
mState.viewportX = 0;
mState.viewportY = 0;
mState.viewportWidth = config->mDisplayMode.Width;
mState.viewportHeight = config->mDisplayMode.Height;
mState.viewportWidth = 0;
mState.viewportHeight = 0;
mState.zNear = 0.0f;
mState.zFar = 1.0f;
mState.scissorX = 0;
mState.scissorY = 0;
mState.scissorWidth = config->mDisplayMode.Width;
mState.scissorHeight = config->mDisplayMode.Height;
mState.scissorWidth = 0;
mState.scissorHeight = 0;
mState.colorMaskRed = true;
mState.colorMaskGreen = true;
......@@ -4394,9 +4394,9 @@ void VertexDeclarationCache::markStateDirty()
extern "C"
{
gl::Context *glCreateContext(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess)
gl::Context *glCreateContext(const gl::Context *shareContext, bool notifyResets, bool robustAccess)
{
return new gl::Context(config, shareContext, notifyResets, robustAccess);
return new gl::Context(shareContext, notifyResets, robustAccess);
}
void glDestroyContext(gl::Context *context)
......
......@@ -35,7 +35,6 @@ namespace egl
{
class Display;
class Surface;
class Config;
}
namespace gl
......@@ -281,7 +280,7 @@ class VertexDeclarationCache
class Context
{
public:
Context(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess);
Context(const gl::Context *shareContext, bool notifyResets, bool robustAccess);
~Context();
......@@ -544,7 +543,6 @@ class Context
void initExtensionString();
void initRendererString();
const egl::Config *const mConfig;
egl::Display *mDisplay;
IDirect3DDevice9 *mDevice;
renderer::Renderer *mRenderer;
......@@ -669,7 +667,7 @@ class Context
extern "C"
{
// Exported functions for use by EGL
gl::Context *glCreateContext(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess);
gl::Context *glCreateContext(const gl::Context *shareContext, bool notifyResets, bool robustAccess);
void glDestroyContext(gl::Context *context);
void glMakeCurrent(gl::Context *context, egl::Display *display, egl::Surface *surface);
gl::Context *glGetCurrentContext();
......
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