You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Merge pull request #26898 from clayjohn/radiance_map_gles2
Increase size of radiance map in gles2
This commit is contained in:
@@ -1137,7 +1137,7 @@ void RasterizerStorageGLES2::sky_set_texture(RID p_sky, RID p_panorama, int p_ra
|
|||||||
glGenTextures(1, &sky->radiance);
|
glGenTextures(1, &sky->radiance);
|
||||||
glBindTexture(GL_TEXTURE_CUBE_MAP, sky->radiance);
|
glBindTexture(GL_TEXTURE_CUBE_MAP, sky->radiance);
|
||||||
|
|
||||||
int size = p_radiance_size / 4; //divide by four because its a cubemap (this is an approximation because GLES3 uses a dual paraboloid)
|
int size = p_radiance_size / 2; //divide by two because its a cubemap (this is an approximation because GLES3 uses a dual paraboloid)
|
||||||
|
|
||||||
GLenum internal_format = GL_RGB;
|
GLenum internal_format = GL_RGB;
|
||||||
GLenum format = GL_RGB;
|
GLenum format = GL_RGB;
|
||||||
@@ -1176,7 +1176,7 @@ void RasterizerStorageGLES2::sky_set_texture(RID p_sky, RID p_panorama, int p_ra
|
|||||||
int mipmaps = 6;
|
int mipmaps = 6;
|
||||||
int lod = 0;
|
int lod = 0;
|
||||||
int mm_level = mipmaps;
|
int mm_level = mipmaps;
|
||||||
size = p_radiance_size / 4;
|
size = p_radiance_size / 2;
|
||||||
shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES2::USE_SOURCE_PANORAMA, true);
|
shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES2::USE_SOURCE_PANORAMA, true);
|
||||||
shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES2::USE_DIRECT_WRITE, true);
|
shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES2::USE_DIRECT_WRITE, true);
|
||||||
shaders.cubemap_filter.bind();
|
shaders.cubemap_filter.bind();
|
||||||
|
|||||||
Reference in New Issue
Block a user