Browse Source

fix shader marking issue

Alexander Rose 6 years ago
parent
commit
a6cfdf9fdd
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/mol-gl/shader/chunks/apply-marker-color.glsl

+ 1 - 1
src/mol-gl/shader/chunks/apply-marker-color.glsl

@@ -1,6 +1,6 @@
 // only mark elements with an alpha above the picking threshold
 if (uAlpha >= uPickingAlphaThreshold) {
-    float marker = vMarker * 255.0;
+    float marker = floor(vMarker * 255.0 + 0.5); // rounding required to work on some cards on win
     if (marker > 0.1) {
         if (intMod(marker, 2.0) > 0.1) {
             gl_FragColor.rgb = mix(uHighlightColor, gl_FragColor.rgb, 0.3);