org.geotools.renderer.lite.gridcoverage2d
Class RasterSymbolizerSupport

java.lang.Object
  extended by org.geotools.renderer.lite.gridcoverage2d.RasterSymbolizerSupport

public final class RasterSymbolizerSupport
extends Object

A helper class for GridCoverage objects rendering SLD stylers support.

Author:
Alessio Fabiani, Simone Giannecchini

Nested Class Summary
static class RasterSymbolizerSupport.RECOLOR_MODE_TYPE
          Types for the recoloring process.
 
Field Summary
static RasterSymbolizerSupport.RECOLOR_MODE_TYPE RECOLOR_MODE
          The way the recoloring is processed.
 
Constructor Summary
RasterSymbolizerSupport(RasterSymbolizer symbolizer)
          Constructor
 
Method Summary
static Category createNoDataCategory(int value, double geoValue)
          Creates a Category for a NoData-value, which will be displayed transparently.
 Map getCategories(int band)
           
 Color[] getColors(int band)
           
 String[] getLabels(int band)
           
 float getOpacity()
          HELPER FUNCTIONS
 GridCoverage recolorCoverage(GridCoverage grid)
           
static Color toColor(Expression exp, double opacity)
           
static double toOpacity(Expression opacity)
           
static double toQuantiy(Expression quantity)
          Transforms an Expression to a double value.
 GridSampleDimension transformColormap(GridSampleDimension dimension, RasterSymbolizer symbolizer)
           
 SampleDimension transformColormap(int band, SampleDimension dimension, Map[] colorMaps)
          Transform the supplied RGB colors.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RECOLOR_MODE

public static RasterSymbolizerSupport.RECOLOR_MODE_TYPE RECOLOR_MODE
The way the recoloring is processed.

Constructor Detail

RasterSymbolizerSupport

public RasterSymbolizerSupport(RasterSymbolizer symbolizer)
Constructor

Parameters:
symbolizer -
Method Detail

recolorCoverage

public GridCoverage recolorCoverage(GridCoverage grid)
                             throws IllegalArgumentException
Throws:
IllegalArgumentException

getOpacity

public float getOpacity()
HELPER FUNCTIONS


getCategories

public Map getCategories(int band)

getLabels

public String[] getLabels(int band)

getColors

public Color[] getColors(int band)

toColor

public static Color toColor(Expression exp,
                            double opacity)

toOpacity

public static double toOpacity(Expression opacity)

toQuantiy

public static double toQuantiy(Expression quantity)
Transforms an Expression to a double value.


transformColormap

public GridSampleDimension transformColormap(GridSampleDimension dimension,
                                             RasterSymbolizer symbolizer)

createNoDataCategory

public static Category createNoDataCategory(int value,
                                            double geoValue)
Creates a Category for a NoData-value, which will be displayed transparently.

Parameters:
value - sample value
geoValue - geophysics value representing the NoData

transformColormap

public SampleDimension transformColormap(int band,
                                         SampleDimension dimension,
                                         Map[] colorMaps)
Transform the supplied RGB colors.