This repository has been archived on 2023-10-09. You can view files and clone it, but cannot push or open issues or pull requests.
Files
blender-archive/source/blender/draw/modes/shaders/edit_lattice_overlay_frag.glsl

23 lines
353 B
GLSL
Raw Normal View History

2017-04-13 23:29:45 +10:00
flat in int vertFlag;
#define VERTEX_SELECTED (1 << 0)
#define VERTEX_ACTIVE (1 << 1)
2017-04-13 23:29:45 +10:00
2017-05-17 10:46:42 +10:00
out vec4 FragColor;
2017-04-13 23:29:45 +10:00
void main()
{
/* TODO: vertex size */
if ((vertFlag & VERTEX_SELECTED) != 0) {
FragColor = colorVertexSelect;
}
else if ((vertFlag & VERTEX_ACTIVE) != 0) {
FragColor = colorEditMeshActive;
}
else {
FragColor = colorVertex;
}
}