- if (predefinedColours)
- {
- return currentColour;
- }
- }
- if (aboveAnnotationThreshold == NO_THRESHOLD
- || (annotationThreshold != null
- && aboveAnnotationThreshold == ABOVE_THRESHOLD && annotation.annotations[j].value >= annotationThreshold.value)
- || (annotationThreshold != null
- && aboveAnnotationThreshold == BELOW_THRESHOLD && annotation.annotations[j].value <= annotationThreshold.value))
- {
-
- float range = 1f;
- if (thresholdIsMinMax
- && annotation.threshold != null
- && aboveAnnotationThreshold == ABOVE_THRESHOLD
- && annotation.annotations[j].value >= annotation.threshold.value)
- {
- range = (annotation.annotations[j].value - annotation.threshold.value)
- / (annotation.graphMax - annotation.threshold.value);
- }
- else if (thresholdIsMinMax && annotation.threshold != null
- && aboveAnnotationThreshold == BELOW_THRESHOLD
- && annotation.annotations[j].value >= annotation.graphMin)
- {
- range = (annotation.annotations[j].value - annotation.graphMin)
- / (annotation.threshold.value - annotation.graphMin);
- }
- else
- {
- range = (annotation.annotations[j].value - annotation.graphMin)
- / (annotation.graphMax - annotation.graphMin);
- }
-
- if (colourScheme != null)