diff --git a/cmd/data/programs/ubershader.fs.glsl b/cmd/data/programs/ubershader.fs.glsl index bf723d8..f642a65 100644 --- a/cmd/data/programs/ubershader.fs.glsl +++ b/cmd/data/programs/ubershader.fs.glsl @@ -163,8 +163,8 @@ void main() { vec3 color_spec = NdotL_clamped * brdf_spec * (lights[i].color.rgb*(1.0-metalness) + albedo.rgb*metalness); vec3 color_diff = NdotL_clamped * diffuse_energy_ratio(f0, N, L) * albedo.rgb * lights[i].color.rgb; - float sh = shadow(vec4(position, 1.0), i); - color.rgb += (color_diff + color_spec) * sh; + float sh = 1.0;//shadow(vec4(position, 1.0), i); + color.rgb += (0.05*albedo.rgb + color_diff + color_spec) * sh; } color.a = albedo.a; diff --git a/render/opengl/texture.go b/render/opengl/texture.go index 5ad3383..259aab3 100644 --- a/render/opengl/texture.go +++ b/render/opengl/texture.go @@ -180,16 +180,7 @@ func (rs *RenderSystem) NewTexture(d core.TextureDescriptor, data []byte) core.T // set data // this texture's storage has already been allocated, just copy the data if data != nil { - gl.TexSubImage2D( - target, - 0, - 0, - 0, - int32(d.Width), - int32(d.Height), - format, - componentType, - gl.Ptr(data)) + gl.TexSubImage2D(target, 0, 0, 0, int32(d.Width), int32(d.Height), format, componentType, gl.Ptr(data)) if d.Mipmaps { gl.GenerateMipmap(target) diff --git a/render/opengl/uniform.go b/render/opengl/uniform.go index b579d5c..3cd2509 100644 --- a/render/opengl/uniform.go +++ b/render/opengl/uniform.go @@ -5,7 +5,6 @@ import ( "unsafe" "github.com/fcvarela/gosg/core" - "github.com/go-gl/gl/v3.3-core/gl" "github.com/go-gl/mathgl/mgl32" "github.com/go-gl/mathgl/mgl64"