mirror of
https://github.com/Jozufozu/Flywheel.git
synced 2024-11-13 05:54:01 +01:00
Revert addition of flw_vertexDiffuse and flw_fragDiffuse
This commit is contained in:
parent
21549567e7
commit
ed47aa226d
@ -13,9 +13,6 @@
|
|||||||
|
|
||||||
/*const*/ float flw_distance;
|
/*const*/ float flw_distance;
|
||||||
|
|
||||||
/*const*/ bool flw_vertexDiffuse;
|
|
||||||
|
|
||||||
bool flw_fragDiffuse;
|
|
||||||
vec4 flw_fragColor;
|
vec4 flw_fragColor;
|
||||||
ivec2 flw_fragOverlay;
|
ivec2 flw_fragOverlay;
|
||||||
vec2 flw_fragLight;
|
vec2 flw_fragLight;
|
||||||
|
@ -7,8 +7,6 @@ ivec2 flw_vertexOverlay;
|
|||||||
vec2 flw_vertexLight;
|
vec2 flw_vertexLight;
|
||||||
vec3 flw_vertexNormal;
|
vec3 flw_vertexNormal;
|
||||||
|
|
||||||
bool flw_vertexDiffuse;
|
|
||||||
|
|
||||||
/*const*/ FlwMaterial flw_material;
|
/*const*/ FlwMaterial flw_material;
|
||||||
|
|
||||||
// To be implemented by the instance shader.
|
// To be implemented by the instance shader.
|
||||||
|
@ -10,8 +10,6 @@ uniform sampler2D _flw_diffuseTex;
|
|||||||
uniform sampler2D _flw_overlayTex;
|
uniform sampler2D _flw_overlayTex;
|
||||||
uniform sampler2D _flw_lightTex;
|
uniform sampler2D _flw_lightTex;
|
||||||
|
|
||||||
flat in uint _flw_vertexDiffuse;
|
|
||||||
|
|
||||||
out vec4 _flw_outputColor;
|
out vec4 _flw_outputColor;
|
||||||
|
|
||||||
void _flw_main() {
|
void _flw_main() {
|
||||||
@ -20,16 +18,13 @@ void _flw_main() {
|
|||||||
flw_fragOverlay = flw_vertexOverlay;
|
flw_fragOverlay = flw_vertexOverlay;
|
||||||
flw_fragLight = flw_vertexLight;
|
flw_fragLight = flw_vertexLight;
|
||||||
|
|
||||||
flw_vertexDiffuse = bool(_flw_vertexDiffuse);
|
|
||||||
flw_fragDiffuse = flw_vertexDiffuse;
|
|
||||||
|
|
||||||
flw_beginFragment();
|
flw_beginFragment();
|
||||||
flw_materialFragment();
|
flw_materialFragment();
|
||||||
flw_endFragment();
|
flw_endFragment();
|
||||||
|
|
||||||
vec4 color = flw_fragColor;
|
vec4 color = flw_fragColor;
|
||||||
|
|
||||||
if (flw_fragDiffuse) {
|
if (flw_material.diffuse) {
|
||||||
float diffuseFactor;
|
float diffuseFactor;
|
||||||
if (flw_constantAmbientLight == 1u) {
|
if (flw_constantAmbientLight == 1u) {
|
||||||
diffuseFactor = diffuseNether(flw_vertexNormal);
|
diffuseFactor = diffuseNether(flw_vertexNormal);
|
||||||
|
@ -1,10 +1,6 @@
|
|||||||
#include "flywheel:internal/fog_distance.glsl"
|
#include "flywheel:internal/fog_distance.glsl"
|
||||||
|
|
||||||
flat out uint _flw_vertexDiffuse;
|
|
||||||
|
|
||||||
void _flw_main(in FlwInstance instance) {
|
void _flw_main(in FlwInstance instance) {
|
||||||
flw_vertexDiffuse = flw_material.diffuse;
|
|
||||||
|
|
||||||
_flw_layoutVertex();
|
_flw_layoutVertex();
|
||||||
flw_beginVertex();
|
flw_beginVertex();
|
||||||
flw_instanceVertex(instance);
|
flw_instanceVertex(instance);
|
||||||
@ -13,8 +9,6 @@ void _flw_main(in FlwInstance instance) {
|
|||||||
|
|
||||||
flw_vertexNormal = normalize(flw_vertexNormal);
|
flw_vertexNormal = normalize(flw_vertexNormal);
|
||||||
|
|
||||||
_flw_vertexDiffuse = uint(flw_vertexDiffuse);
|
|
||||||
|
|
||||||
flw_distance = fogDistance(flw_vertexPos.xyz, flw_cameraPos.xyz, flw_fogShape);
|
flw_distance = fogDistance(flw_vertexPos.xyz, flw_cameraPos.xyz, flw_fogShape);
|
||||||
gl_Position = flw_viewProjection * flw_vertexPos;
|
gl_Position = flw_viewProjection * flw_vertexPos;
|
||||||
}
|
}
|
||||||
|
@ -11,8 +11,6 @@ in vec3 flw_vertexNormal;
|
|||||||
|
|
||||||
in float flw_distance;
|
in float flw_distance;
|
||||||
|
|
||||||
bool flw_vertexDiffuse;
|
|
||||||
|
|
||||||
vec4 flw_sampleColor;
|
vec4 flw_sampleColor;
|
||||||
|
|
||||||
FlwMaterial flw_material;
|
FlwMaterial flw_material;
|
||||||
|
@ -12,6 +12,4 @@ out vec3 flw_vertexNormal;
|
|||||||
|
|
||||||
out float flw_distance;
|
out float flw_distance;
|
||||||
|
|
||||||
bool flw_vertexDiffuse;
|
|
||||||
|
|
||||||
FlwMaterial flw_material;
|
FlwMaterial flw_material;
|
||||||
|
Loading…
Reference in New Issue
Block a user