Skip to content
Snippets Groups Projects
Commit 61d617c5 authored by Alexander Rose's avatar Alexander Rose
Browse files

only mark elements with an alpha above the picking threshold

parent 667717ba
No related branches found
No related tags found
No related merge requests found
float marker = vMarker * 255.0;
if (marker > 0.1) {
if (mod(marker, 2.0) > 0.1) {
gl_FragColor.rgb = mix(uHighlightColor, gl_FragColor.rgb, 0.3);
} else {
gl_FragColor.rgb = mix(uSelectColor, gl_FragColor.rgb, 0.3);
// only mark elements with an alpha above the picking threshold
if (uAlpha >= uPickingAlphaThreshold) {
float marker = vMarker * 255.0;
if (marker > 0.1) {
if (mod(marker, 2.0) > 0.1) {
gl_FragColor.rgb = mix(uHighlightColor, gl_FragColor.rgb, 0.3);
} else {
gl_FragColor.rgb = mix(uSelectColor, gl_FragColor.rgb, 0.3);
}
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment