sponza debugging and fixes

This commit is contained in:
Lauri Räsänen 2022-10-06 00:20:18 +03:00
parent 708c46adc7
commit e39ea0b80b
9 changed files with 64 additions and 34 deletions

View file

@ -28,7 +28,7 @@ struct VertexOutput {
fn vs_main(
model: VertexInput,
) -> VertexOutput {
let scale = 0.25;
let scale = 0.01;
var out: VertexOutput;
out.clip_position = camera.proj * camera.view * vec4<f32>(model.position * scale + light.position, 1.0);
out.color = light.color;

View file

@ -94,7 +94,7 @@ fn fs_main(in: VertexOutput) -> @location(0) vec4<f32> {
let half_dir = normalize(view_dir + light_dir);
// ambient
let ambient_strength = 0.05;
let ambient_strength = 0.025;
let ambient_color = light.color * ambient_strength;
// diffuse