Package sc.fiji.snt.util
Class ColorMaps
java.lang.Object
sc.fiji.snt.util.ColorMaps
Utilities for colormaps and IJ lookup tables
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidapplyPlasma(ij.ImagePlus imp) Applies the "plasma" colormap to the specified (non-RGB) imagestatic voidapplyPlasma(ij.ImagePlus imp, int backgroundGray, boolean inverted) Applies the "plasma" colormap to the specified (non-RGB) imagestatic voidapplyViridis(ij.ImagePlus imp) Applies the "viridis" colormap to the specified (non-RGB) imagestatic voidapplyViridis(ij.ImagePlus imp, int backgroundGray, boolean inverted) Applies the "viridis" colormap to the specified (non-RGB) imagestatic org.scijava.util.ColorRGB[]discreteColors(net.imglib2.display.ColorTable colorTable, int n) static Color[]discreteColorsAWT(net.imglib2.display.ColorTable colorTable, int n) static net.imglib2.display.ColorTableReturns a 'core' color table from its titlestatic Color[]glasbeyColorsAWT(int n)
-
Field Details
-
ICE
public static final net.imglib2.display.ColorTable ICE -
VIRIDIS
public static final net.imglib2.display.ColorTable VIRIDIS -
PLASMA
public static final net.imglib2.display.ColorTable PLASMA
-
-
Constructor Details
-
ColorMaps
public ColorMaps()
-
-
Method Details
-
applyViridis
public static void applyViridis(ij.ImagePlus imp) Applies the "viridis" colormap to the specified (non-RGB) image- Parameters:
imp- A non-RGB image
-
applyViridis
public static void applyViridis(ij.ImagePlus imp, int backgroundGray, boolean inverted) Applies the "viridis" colormap to the specified (non-RGB) image- Parameters:
imp- A non-RGB imagebackgroundGray- The gray value (8-bit scale) to be used as the first entry of the LUT. It is ignored if negative.inverted- If the LUT should be inverted
-
applyPlasma
public static void applyPlasma(ij.ImagePlus imp) Applies the "plasma" colormap to the specified (non-RGB) image- Parameters:
imp- A non-RGB image
-
applyPlasma
public static void applyPlasma(ij.ImagePlus imp, int backgroundGray, boolean inverted) Applies the "plasma" colormap to the specified (non-RGB) image- Parameters:
imp- A non-RGB imagebackgroundGray- The gray value (8-bit scale) to be used as the first entry of the LUT. It is ignored if negative.inverted- If the LUT should be inverted
-
get
Returns a 'core' color table from its title- Parameters:
name- the color table name (e.g., "fire", "viridis", etc)- Returns:
- the color table
-
discreteColors
public static org.scijava.util.ColorRGB[] discreteColors(net.imglib2.display.ColorTable colorTable, int n) -
discreteColorsAWT
-
glasbeyColorsAWT
-