kcc5
Class KCC_GenerateColorMap

Object
  extended by common:Generic
      extended by common:GradientWrapper
          extended by kcc5:KCC_ColorMapBase
              extended by kcc5:KCC_GenerateColorMap

class 
KCC_ColorMapBase:KCC_GenerateColorMap

Class for generating color ranges using the gradient.

This class provides options for generating color ranges from the gradient.

For an example of what this map looks like, click here.


Ultra Fractal Source

Toggle UF Source Code Display

 class KCC_GenerateColorMap( KCC_ColorMapBase ) {
 ; Class for generating color ranges using the gradient.
 ; <p>
 ; This class provides options for generating color ranges from the gradient.
 ; <p>
 ; For an example of what this map looks like,
 ; <a href="../additional/kcc5/images/Generate from Gradient Map.jpg">click here</a>.
 ;
 public:
   import "common.ulb"
 
   ; Constructor
   func KCC_GenerateColorMap( Generic pparent )
     KCC_ColorMapBase( pparent )
 
     colorRanges = @colorRanges
 
     ; Compute the color ranges using the gradient.
     int ranges = 0
     while ranges < colorRanges
       color gradientColor = gradient( ranges / @colorRanges )
       colorMap[ranges,0] = hsl( hue( gradientColor ), sat( gradientColor ), @luminanceUpper )
       colorMap[ranges,1] = hsl( hue( gradientColor ), sat( gradientColor ), @luminanceLower )
       ranges = ranges + 1
     endwhile
   endfunc
 
 private:
 
 default:
   title = "Generate Color Map"
 
   int param v_KCC_GenerateColorMap
     caption = "Version (KCC_GenerateColorMap)"
     default = 100
     hint = "This version parameter is used to detect when a change has been \
             made to the formula that is incompatible with the previous version. \
             When that happens, this field will reflect the old version number to \
             alert you to the fact that an alternate rendering is being used."
     visible = @v_KCC_GenerateColorMap < 100
   endparam
 
   int param colorRanges
     caption = "# of Ranges"
     default = 8
     min = 1
     max = 500
     hint = "The number of color ranges."
   endparam
 
   float param luminanceUpper
     caption = "Lum. Upper Value"
     default = 0.60
     min = 0.0
     max = 1.0
     hint = "The value of the Luminance component for the upper value \
             when generating the ranges from the gradient.  This value \
             is used with the brighter end of the color range."
   endparam
 
   float param luminanceLower
     caption = "Lum. Lower Value"
     default = 0.10
     min = 0.0
     max = 1.0
     hint = "The value of the Luminance component for the lower value \
             when generating the ranges from the gradient.  This value \
             is used with the darker end of the color range."
   endparam
 }
 


Constructor Summary
KCC_GenerateColorMap()
           
KCC_GenerateColorMap(Generic pparent)
          Constructor
 
Method Summary
 
Methods inherited from class kcc5:KCC_ColorMapBase
getColorChannel, perturb8RangeMap, perturbRanges
 
Methods inherited from class common:GradientWrapper
getColor
 
Methods inherited from class common:Generic
GetParent
 
Methods inherited from class Object
 

Constructor Detail

KCC_GenerateColorMap

public KCC_GenerateColorMap(Generic pparent)
Constructor


KCC_GenerateColorMap

public KCC_GenerateColorMap()