| TerraLib 4.1

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files
- Examples

- File List
- File Members

Functions
E:/Projetos_Primeiro_Semestre_2012/TerraView/terralib/src/terralib/utils/TeColorUtils.cpp File Reference
`#include "TeColorUtils.h"`
`#include "../kernel/TeDatabase.h"`
`#include "../kernel/TeAsciiFile.h"`
`#include <cstring>`

## Functions

bool | getColors (std::vector< std::string > &ramps, int nc, std::vector< TeColor > &colors)
| Generates a graduated color scale following a sequence of basic colors.
void | generateColorBarMap (vector< ColorBar > &inputColorVec, int ncores, map< int, vector< TeColor > > &colorMap)
vector< TeColor > | getColors (TeColor cfrom, TeColor cto, int nc)
vector< ColorBar > | getColorBarVector (string &groupingColors, const bool &first)
vector< TeColor > | getColors (vector< ColorBar > &iVec, int ncores)
string | getColors (vector< ColorBar > &aVec, vector< ColorBar > &bVec, int groupingMode)
void | rgb2Hsv (const TeColor &c, int &h, int &s, int &v)
void | RGBtoHSV (const double &r, const double &g, const double &b, double &h, double &s, double &v)
void | hsv2Rgb (TeColor &c, const int &h, const int &s, const int &v)
void | HSVtoRGB (double &r, double &g, double &b, const double &h, const double &s, const double &v)
unsigned int | TeReadColorRampTextFile (const string &fileName, map< string, string > &colorRamps)

## Function Documentation

void generateColorBarMap | ( | vector< ColorBar > & | inputColorVec,
|  | int | ncores,
|  | map< int, vector< TeColor > > & | colorMap
| ) |  |

vector<ColorBar> getColorBarVector | ( | string & | groupingColors,
|  | const bool & | first
| ) |  |

bool getColors | ( | std::vector< std::string > & | ramps,
|  | int | nc,
|  | std::vector< TeColor > & | colors
| ) |  |

Generates a graduated color scale following a sequence of basic colors.

The possible basic colors are "RED", "GREEN", "BLUE", "YELLOW", "CYAN", "MAGENTA", "GRAY" and "BLACK"

Parameters:

  ramps | vector with the sequence color ramps used to build the scale
  nc | desired number of colors on the scale
  colors | resulting color scale

Returns:
  true if color scale was successfully generated and false otherwise

vector<TeColor> getColors | ( | vector< ColorBar > & | iVec,
|  | int | ncores
| ) |  |

vector<TeColor> getColors | ( | TeColor | cfrom,
|  | TeColor | cto,
|  | int | nc
| ) |  |

string getColors | ( | vector< ColorBar > & | aVec,
|  | vector< ColorBar > & | bVec,
|  | int | groupingMode
| ) |  |

void hsv2Rgb | ( | TeColor & | c,
|  | const int & | h,
|  | const int & | s,
|  | const int & | v
| ) |  |

void HSVtoRGB | ( | double & | r,
|  | double & | g,
|  | double & | b,
|  | const double & | h,
|  | const double & | s,
|  | const double & | v
| ) |  |

void rgb2Hsv | ( | const TeColor & | c,
|  | int & | h,
|  | int & | s,
|  | int & | v
| ) |  |

void RGBtoHSV | ( | const double & | r,
|  | const double & | g,
|  | const double & | b,
|  | double & | h,
|  | double & | s,
|  | double & | v
| ) |  |

unsigned int TeReadColorRampTextFile | ( | const string & | fileName,
|  | map< string, string > & | colorRamps
| ) |  |

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines