# Update Controls for Annotation Rendering

### 1. Go to the rendering panel in the annotation layer

![](https://2926737796-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-Ld57Fj27nUB-NnjPb7c%2F-MDKw6j9TUDUX-khnzab%2F-MDKwmUiIxNsi-d6LbhQ%2Fimage.png?alt=media\&token=57afdbe6-e641-4c4f-87d6-2aca5a6cb57d)

### 2. Replace the text in the `Annotation shader` box with new code

{% tabs %}
{% tab title="Recommended sample shader code" %}

```
#uicontrol vec3 falseSplitColor color(default="#F08040")
#uicontrol vec3 falseMergeColor color(default="#F040F0")
#uicontrol vec3 checkedColor color(default="green")
#uicontrol vec3 borderColor color(default="black")
#uicontrol float pointRadius slider(min=3, max=20, step=1, default=10)
#uicontrol float lineEndRadius slider(min=3, max=20, step=1, default=10)
#uicontrol float lineWidth slider(min=1, max=10, step=1, default=1)
#uicontrol float opacity slider(min=0, max=1, step=0.1, default=1)
#uicontrol float opacity3D slider(min=0, max=1, step=0.1, default=0.2)
#uicontrol vec3 defaultPointColor color(default="#FF0000")
#uicontrol vec3 lineColor color(default="#FF0000")
#uicontrol vec3 sphereColor color(default="red")
#uicontrol float sphereAnnotationOpacity slider(min=0, max=1, step=0.1, default=1)
void main() {
  setPointMarkerSize(pointRadius);
  setEndpointMarkerSize(lineEndRadius);
  setLineWidth(lineWidth);
  float finalOpacity = PROJECTION_VIEW ? opacity3D : opacity;
  setPointMarkerBorderColor(vec4(borderColor, finalOpacity));
  if (prop_rendering_attribute() == 1) {
    setColor(vec4(checkedColor, finalOpacity));
  } else if (prop_rendering_attribute() == 2) {    
    setColor(vec4(falseSplitColor, finalOpacity));
  } else if (prop_rendering_attribute() == 3)  {
    setColor(vec4(falseMergeColor, finalOpacity));
  } else {
 	setColor(vec4(defaultPointColor, finalOpacity));
  }
  setLineColor(lineColor, lineColor);
  setEndpointMarkerColor(lineColor);
  float finalSphereAnnotationOpacity = sphereAnnotationOpacity;
  if (prop_rendering_attribute() != 11) {
    finalSphereAnnotationOpacity = 1.0;
  }
  setSphereColor(vec4(sphereColor, finalSphereAnnotationOpacity));
  setAxisColor(vec4(sphereColor, finalSphereAnnotationOpacity));
  setAxisEndpointMarkerColor(vec4(sphereColor, finalSphereAnnotationOpacity));
}
```

{% endtab %}
{% endtabs %}

### 3. Click outside of the box
