-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactoring fo envMultiply and envConst chunks #7399
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
export default /* wgsl */` | ||
#ifdef LIT_SKYBOX_INTENSITY | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It is worth having a shader variant just to avoid a multiply? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. not really, but this code is slightly more complicated than I want to handle during this conversion. Ideally we add skybox intensity to material as well, and unify it all. |
||
uniform skyboxIntensity : f32; | ||
#endif | ||
|
||
fn processEnvironment(color : vec3f) -> vec3f { | ||
#ifdef LIT_SKYBOX_INTENSITY | ||
return color * uniform.skyboxIntensity; | ||
#else | ||
return color; | ||
#endif | ||
} | ||
`; |
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
export default /* glsl */` | ||
#ifdef LIT_SKYBOX_INTENSITY | ||
uniform float skyboxIntensity; | ||
#endif | ||
|
||
vec3 processEnvironment(vec3 color) { | ||
#ifdef LIT_SKYBOX_INTENSITY | ||
return color * skyboxIntensity; | ||
#else | ||
return color; | ||
#endif | ||
} | ||
`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not 100% keen on the
envProc
naming.skybox
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we already have skybox chunk that does the skybox. This is just a small chunk used by both skybox and lit-shader