Refactored TextureCubeMap, separated out D3D logic
BUG=angle:688
Change-Id: I2300aaad4fab25df484e0bc3613ac3b176addc93
Reviewed-on: https://chromium-review.googlesource.com/208191
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Tested-by: Brandon Jones <bajones@chromium.org>
diff --git a/src/libGLESv2/Context.cpp b/src/libGLESv2/Context.cpp
index 8b1d660..8c0e413 100644
--- a/src/libGLESv2/Context.cpp
+++ b/src/libGLESv2/Context.cpp
@@ -69,7 +69,7 @@
// objects all of whose names are 0.
mTexture2DZero.set(new Texture2D(mRenderer->createTexture2D(), 0));
- mTextureCubeMapZero.set(new TextureCubeMap(mRenderer, 0));
+ mTextureCubeMapZero.set(new TextureCubeMap(mRenderer->createTextureCube(), 0));
mTexture3DZero.set(new Texture3D(mRenderer, 0));
mTexture2DArrayZero.set(new Texture2DArray(mRenderer, 0));
@@ -2159,7 +2159,7 @@
case TEXTURE_CUBE:
{
- TextureCubeMap *incompleteCube = new TextureCubeMap(mRenderer, Texture::INCOMPLETE_TEXTURE_ID);
+ TextureCubeMap *incompleteCube = new TextureCubeMap(mRenderer->createTextureCube(), Texture::INCOMPLETE_TEXTURE_ID);
incompleteCube->setImagePosX(0, 1, 1, GL_RGBA, GL_RGBA, GL_UNSIGNED_BYTE, incompleteUnpackState, color);
incompleteCube->setImageNegX(0, 1, 1, GL_RGBA, GL_RGBA, GL_UNSIGNED_BYTE, incompleteUnpackState, color);