This repository has been archived on 2023-10-09. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
blender-archive/source/blender/draw/modes/shaders/sculpt_mask_vert.glsl
Clément Foucault 1381a4a948 Sculpt Overlay: Fix mask drawn as flat shaded when smooth shading enabled
Removes the flat shader variant since the attrib is specified for each vert
loop in flat shaded mode. It was something leftover from the previous
implementation.
2019-02-22 04:03:59 +01:00

16 lines
243 B
GLSL

uniform mat4 ModelViewProjectionMatrix;
in vec3 pos;
in float msk;
out vec4 finalColor;
void main()
{
gl_Position = ModelViewProjectionMatrix * vec4(pos, 1.0);
float mask = 1.0 - msk * 0.75;
finalColor = vec4(mask, mask, mask, 1.0);
}