mirror of
https://github.com/PAMGuard/PAMGuard.git
synced 2024-11-22 07:02:29 +00:00
Fix for colour limits on DL prediction pane
This commit is contained in:
parent
7be2e4eeed
commit
9e65fb18f4
@ -207,12 +207,24 @@ public class DLSymbolOptionPanel implements PamDialogPanel, ActionListener {
|
||||
*/
|
||||
private void setPredictionColParams(DLSymbolModifierParams symbolOptions) {
|
||||
|
||||
|
||||
//just incasesettings have messed up
|
||||
if (symbolOptions.clims[0]==symbolOptions.clims[1]) {
|
||||
symbolOptions.clims[0]=Math.max(0.,symbolOptions.clims[1]-0.1);
|
||||
symbolOptions.clims[1]=Math.min(1.,symbolOptions.clims[1]+0.1);
|
||||
}
|
||||
|
||||
//now set frequency parameters
|
||||
colorRangeSlider.setValue((int) symbolOptions.clims[0]*100);
|
||||
colorRangeSlider.setUpperValue((int) symbolOptions.clims[1]*100);
|
||||
// System.out.println("Set colour limits: " + symbolOptions.clims[0] + " " + symbolOptions.clims[1] + " " + colorRangeSlider.getMaximum());
|
||||
|
||||
//careful of casting to int here or else end up with setting the two thumbs in the same place.
|
||||
colorRangeSlider.setColourMap(PamUtilsFX.fxColArray2Swing(symbolOptions.colArray));
|
||||
|
||||
colorRangeSlider.setValue((int) (symbolOptions.clims[0]*100.));
|
||||
|
||||
colorRangeSlider.setUpperValue((int) (symbolOptions.clims[1]*100.));
|
||||
// colorRangeSlider.setColourArrayType( symbolOptions.colArray);
|
||||
|
||||
colorRangeSlider.setColourMap(PamUtilsFX.fxColArray2Swing(symbolOptions.colArray));
|
||||
|
||||
|
||||
int nClass = checkClassNamesBox( symbolOptions, classNameBox);
|
||||
|
Loading…
Reference in New Issue
Block a user