Fixed GLES2 texture format error. Fixed hdr example cube texture issue.

This commit is contained in:
bkaradzic 2013-04-06 14:03:38 -07:00
parent 84bfec136a
commit 648c8a593e
3 changed files with 3 additions and 3 deletions

View File

@ -455,7 +455,7 @@ int _main_(int /*_argc*/, char** /*_argv*/)
const bgfx::Memory* mem;
mem = loadTexture("uffizi.dds");
bgfx::TextureHandle uffizi = bgfx::createTexture(mem);
bgfx::TextureHandle uffizi = bgfx::createTexture(mem, BGFX_TEXTURE_U_CLAMP|BGFX_TEXTURE_V_CLAMP|BGFX_TEXTURE_W_CLAMP);
bgfx::UniformHandle u_time = bgfx::createUniform("u_time", bgfx::UniformType::Uniform1f);
bgfx::UniformHandle u_texCube = bgfx::createUniform("u_texCube", bgfx::UniformType::Uniform1i);

View File

@ -171,7 +171,7 @@ uniform vec4 u_viewRect;
uniform vec4 u_viewTexel;
uniform mat4 u_view;
uniform mat4 u_viewProj;
uniform mat4 u_model;
uniform mat4 u_model[64];
uniform mat4 u_modelView;
uniform mat4 u_modelViewProj;
uniform mat4 u_modelViewProjX;

View File

@ -74,7 +74,7 @@
# define glGenVertexArrays glGenVertexArraysOES
# define GL_PROGRAM_BINARY_LENGTH GL_PROGRAM_BINARY_LENGTH_OES
# define GL_HALF_FLOAT GL_HALF_FLOAT_OES
# define GL_RGBA8 GL_RGBA8_OES
# define GL_RGBA8 GL_RGBA //GL_RGBA8_OES
# define GL_RGB10_A2 GL_RGB10_A2_EXT
# define GL_R16F GL_R16F_EXT
# define GL_R32F GL_R32F_EXT