vcg::tri::UpdateColor< UpdateMeshType > Class Template Reference
[Trimesh]

Generation of per-vertex and per-face colors according to various strategy. More...

#include <vcg/complex/trimesh/update/color.h>

List of all members.

Classes

class  ColorAvgInfo

Public Types

enum  DesaturationMethods { M_LIGHTNESS = 0, M_LUMINOSITY = 1, M_AVERAGE = 2 }
typedef
UpdateMeshType::FaceIterator 
FaceIterator
typedef UpdateMeshType::FacePointer FacePointer
typedef UpdateMeshType::FaceType FaceType
typedef UpdateMeshType MeshType
enum  rgbChMask {
  ALL_CHANNELS = 7, RED_CHANNEL = 4, GREEN_CHANNEL = 2, BLUE_CHANNEL = 1,
  NO_CHANNELS = 0
}
typedef
UpdateMeshType::VertexIterator 
VertexIterator
typedef
UpdateMeshType::VertexPointer 
VertexPointer
typedef UpdateMeshType::VertexType VertexType

Static Public Member Functions

static int Brighting (UpdateMeshType &m, float amount, const bool ProcessSelected=false)
static int BrightnessContrast (UpdateMeshType &m, float brightness, float contrast, const bool ProcessSelected=false)
static Color4b ColorApplyDiff (Color4b old_color, Color4b new_color, float intensity)
static Color4b ColorBrightnessContrast (Color4b c, float brightness, float contrast)
static Color4b ColorDesaturate (Color4b c, int method)
static Color4b ColorEqualize (Color4b c, int cdf_l[256], int cdf_r[256], int cdf_g[256], int cdf_b[256], unsigned int rgbMask)
static Color4b ColorInvert (Color4b c)
static Color4b ColorLevels (Color4b c, float gamma, float in_min, float in_max, float out_min, float out_max, unsigned char rgbMask)
static Color4b ColorMul (Color4b c, float factor)
static void ColorNoise (MeshType &m, int noiseBits)
static Color4b ColorPow (Color4b c, float exponent)
static Color4b ColorWhiteBalance (Color4b c, Color4b unbalancedWhite)
static int Colourisation (UpdateMeshType &m, Color4b c, float intensity, const bool ProcessSelected=false)
static float ComputeAvgLightness (Color4b c)
static float ComputeLightness (Color4b c)
static float ComputeLuminosity (Color4b c)
static int Contrast (UpdateMeshType &m, float factor, const bool ProcessSelected=false)
static int Desaturation (UpdateMeshType &m, int method, const bool ProcessSelected=false)
static int Equalize (UpdateMeshType &m, unsigned int rgbMask, const bool ProcessSelected=false)
static void FaceBF (UpdateMeshType &m, Color4b vn=Color4b::White, Color4b vb=Color4b::Blue, Color4b vc=Color4b::Red, Color4b vs=Color4b::LightBlue)
static void FaceColorStrip (UpdateMeshType &m, std::vector< FacePointer > &TStripF)
static void FaceConstant (UpdateMeshType &m, Color4b c=Color4b::White)
static void FaceFromVertex (UpdateMeshType &m)
static void FaceQualityGray (UpdateMeshType &m)
static void FaceQualityGray (UpdateMeshType &m, float minq, float maxq)
static void FaceQualityRamp (UpdateMeshType &m, float minq, float maxq, bool selected=false)
static void FaceQualityRamp (UpdateMeshType &m, bool selected=false)
static int FaceSelected (UpdateMeshType &m, Color4b vs=Color4b::LightBlue)
static int Filling (UpdateMeshType &m, Color4b c, const bool ProcessSelected=false)
static int Gamma (UpdateMeshType &m, float gamma, const bool ProcessSelected=false)
static int Invert (UpdateMeshType &m, const bool ProcessSelected=false)
static int Levels (UpdateMeshType &m, float gamma, float in_min, float in_max, float out_min, float out_max, unsigned char rgbMask, const bool ProcessSelected=false)
static void MultiFaceRandom (UpdateMeshType &m)
static void PerlinColor (MeshType &m, Box3f bbox, float freq, Point3i channelOffsets)
static int Thresholding (UpdateMeshType &m, float threshold, Color4b c1=Color4< unsigned char >::Black, Color4b c2=Color4< unsigned char >::White, const bool ProcessSelected=false)
static int ValueApplyDiff (int old_value, int new_value, float intensity)
static int ValueBrightnessContrast (unsigned char ivalue, float brightness, float contrast)
static int ValueEqualize (int cdfValue, int cdfMin, int cdfMax)
static int ValueInvert (int value)
static int ValueLevels (int value, float gamma, float in_min, float in_max, float out_min, float out_max)
static int ValueMul (int value, float factor)
static float ValuePow (float value, float exponent)
static void VertexBorderFlag (UpdateMeshType &m, Color4b BorderColor=Color4b::Blue, Color4b InternalColor=Color4b::White, Color4b MixColor=Color4b::Cyan)
 Color the vertexes of the mesh that are on the border.
static void VertexBorderManifoldFlag (UpdateMeshType &m, Color4b vn=Color4b::White, Color4b vb=Color4b::Blue, Color4b vc=Color4b::Red)
static void VertexConstant (UpdateMeshType &m, Color4b c=Color4b::White)
static void VertexFromFace (UpdateMeshType &m)
static void VertexQualityGray (UpdateMeshType &m)
static void VertexQualityGray (UpdateMeshType &m, const float minq, const float maxq)
static void VertexQualityRamp (UpdateMeshType &m)
static void VertexQualityRamp (UpdateMeshType &m, float minq, float maxq)
static int VertexSelected (UpdateMeshType &m, Color4b vs=Color4b::LightBlue)
static int WhiteBalance (UpdateMeshType &m, bool automatic, Color4b userColor, const bool ProcessSelected=false)

Detailed Description

template<class UpdateMeshType>
class vcg::tri::UpdateColor< UpdateMeshType >

Generation of per-vertex and per-face colors according to various strategy.

This class is used to compute per face or per vertex color with respect to for example Border (UpdateColor::VertexBorderFlag), Selection (UpdateColor::FaceSelected), Quality .

Definition at line 86 of file color.h.


Member Typedef Documentation

template<class UpdateMeshType >
typedef UpdateMeshType::FaceIterator vcg::tri::UpdateColor< UpdateMeshType >::FaceIterator

Definition at line 95 of file color.h.

template<class UpdateMeshType >
typedef UpdateMeshType::FacePointer vcg::tri::UpdateColor< UpdateMeshType >::FacePointer

Definition at line 94 of file color.h.

template<class UpdateMeshType >
typedef UpdateMeshType::FaceType vcg::tri::UpdateColor< UpdateMeshType >::FaceType

Definition at line 93 of file color.h.

template<class UpdateMeshType >
typedef UpdateMeshType vcg::tri::UpdateColor< UpdateMeshType >::MeshType

Definition at line 89 of file color.h.

template<class UpdateMeshType >
typedef UpdateMeshType::VertexIterator vcg::tri::UpdateColor< UpdateMeshType >::VertexIterator

Definition at line 92 of file color.h.

template<class UpdateMeshType >
typedef UpdateMeshType::VertexPointer vcg::tri::UpdateColor< UpdateMeshType >::VertexPointer

Definition at line 91 of file color.h.

template<class UpdateMeshType >
typedef UpdateMeshType::VertexType vcg::tri::UpdateColor< UpdateMeshType >::VertexType

Definition at line 90 of file color.h.


Member Enumeration Documentation

template<class UpdateMeshType >
enum vcg::tri::UpdateColor::DesaturationMethods
Enumerator:
M_LIGHTNESS 
M_LUMINOSITY 
M_AVERAGE 

Definition at line 680 of file color.h.

template<class UpdateMeshType >
enum vcg::tri::UpdateColor::rgbChMask
Enumerator:
ALL_CHANNELS 
RED_CHANNEL 
GREEN_CHANNEL 
BLUE_CHANNEL 
NO_CHANNELS 

Definition at line 602 of file color.h.


Member Function Documentation

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Brighting ( UpdateMeshType &  m,
float  amount,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 446 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::BrightnessContrast ( UpdateMeshType &  m,
float  brightness,
float  contrast,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 500 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorApplyDiff ( Color4b  old_color,
Color4b  new_color,
float  intensity 
) [inline, static]

Definition at line 669 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorBrightnessContrast ( Color4b  c,
float  brightness,
float  contrast 
) [inline, static]

Definition at line 521 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorDesaturate ( Color4b  c,
int  method 
) [inline, static]

Definition at line 702 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorEqualize ( Color4b  c,
int  cdf_l[256],
int  cdf_r[256],
int  cdf_g[256],
int  cdf_b[256],
unsigned int  rgbMask 
) [inline, static]

Definition at line 784 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorInvert ( Color4b  c  )  [inline, static]

Definition at line 557 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorLevels ( Color4b  c,
float  gamma,
float  in_min,
float  in_max,
float  out_min,
float  out_max,
unsigned char  rgbMask 
) [inline, static]

Definition at line 626 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorMul ( Color4b  c,
float  factor 
) [inline, static]

Definition at line 489 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::ColorNoise ( MeshType m,
int  noiseBits 
) [inline, static]

Definition at line 880 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorPow ( Color4b  c,
float  exponent 
) [inline, static]

Definition at line 587 of file color.h.

template<class UpdateMeshType >
static Color4b vcg::tri::UpdateColor< UpdateMeshType >::ColorWhiteBalance ( Color4b  c,
Color4b  unbalancedWhite 
) [inline, static]

Definition at line 849 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Colourisation ( UpdateMeshType &  m,
Color4b  c,
float  intensity,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 650 of file color.h.

template<class UpdateMeshType >
static float vcg::tri::UpdateColor< UpdateMeshType >::ComputeAvgLightness ( Color4b  c  )  [inline, static]

Definition at line 722 of file color.h.

template<class UpdateMeshType >
static float vcg::tri::UpdateColor< UpdateMeshType >::ComputeLightness ( Color4b  c  )  [inline, static]

Definition at line 436 of file color.h.

template<class UpdateMeshType >
static float vcg::tri::UpdateColor< UpdateMeshType >::ComputeLuminosity ( Color4b  c  )  [inline, static]

Definition at line 728 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Contrast ( UpdateMeshType &  m,
float  factor,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 469 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Desaturation ( UpdateMeshType &  m,
int  method,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 683 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Equalize ( UpdateMeshType &  m,
unsigned int  rgbMask,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 735 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceBF ( UpdateMeshType &  m,
Color4b  vn = Color4b::White,
Color4b  vb = Color4b::Blue,
Color4b  vc = Color4b::Red,
Color4b  vs = Color4b::LightBlue 
) [inline, static]

Definition at line 210 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceColorStrip ( UpdateMeshType &  m,
std::vector< FacePointer > &  TStripF 
) [inline, static]

Definition at line 254 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceConstant ( UpdateMeshType &  m,
Color4b  c = Color4b::White 
) [inline, static]

Definition at line 296 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceFromVertex ( UpdateMeshType &  m  )  [inline, static]

Definition at line 138 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceQualityGray ( UpdateMeshType &  m  )  [inline, static]

Definition at line 333 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceQualityGray ( UpdateMeshType &  m,
float  minq,
float  maxq 
) [inline, static]

Definition at line 326 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceQualityRamp ( UpdateMeshType &  m,
float  minq,
float  maxq,
bool  selected = false 
) [inline, static]

Definition at line 356 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::FaceQualityRamp ( UpdateMeshType &  m,
bool  selected = false 
) [inline, static]

Definition at line 339 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::FaceSelected ( UpdateMeshType &  m,
Color4b  vs = Color4b::LightBlue 
) [inline, static]

Definition at line 242 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Filling ( UpdateMeshType &  m,
Color4b  c,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 395 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Gamma ( UpdateMeshType &  m,
float  gamma,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 567 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Invert ( UpdateMeshType &  m,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 538 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Levels ( UpdateMeshType &  m,
float  gamma,
float  in_min,
float  in_max,
float  out_min,
float  out_max,
unsigned char  rgbMask,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 607 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::MultiFaceRandom ( UpdateMeshType &  m  )  [inline, static]

This function colores the face of a mesh randomly. The faux bit is used to color polygonal faces uniformly

Definition at line 190 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::PerlinColor ( MeshType m,
Box3f  bbox,
float  freq,
Point3i  channelOffsets 
) [inline, static]

Definition at line 863 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::Thresholding ( UpdateMeshType &  m,
float  threshold,
Color4b  c1 = Color4<unsigned char>::Black,
Color4b  c2 = Color4<unsigned char>::White,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 414 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::ValueApplyDiff ( int  old_value,
int  new_value,
float  intensity 
) [inline, static]

Definition at line 674 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::ValueBrightnessContrast ( unsigned char  ivalue,
float  brightness,
float  contrast 
) [inline, static]

Definition at line 528 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::ValueEqualize ( int  cdfValue,
int  cdfMin,
int  cdfMax 
) [inline, static]

Definition at line 799 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::ValueInvert ( int  value  )  [inline, static]

Definition at line 562 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::ValueLevels ( int  value,
float  gamma,
float  in_min,
float  in_max,
float  out_min,
float  out_max 
) [inline, static]

Definition at line 636 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::ValueMul ( int  value,
float  factor 
) [inline, static]

Definition at line 494 of file color.h.

template<class UpdateMeshType >
static float vcg::tri::UpdateColor< UpdateMeshType >::ValuePow ( float  value,
float  exponent 
) [inline, static]

Definition at line 596 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexBorderFlag ( UpdateMeshType &  m,
Color4b  BorderColor = Color4b::Blue,
Color4b  InternalColor = Color4b::White,
Color4b  MixColor = Color4b::Cyan 
) [inline, static]

Color the vertexes of the mesh that are on the border.

It uses the information in the Vertex flags, and not any topology. So it just require that you have correctly computed the flags;

Definition at line 164 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexBorderManifoldFlag ( UpdateMeshType &  m,
Color4b  vn = Color4b::White,
Color4b  vb = Color4b::Blue,
Color4b  vc = Color4b::Red 
) [inline, static]

Definition at line 303 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexConstant ( UpdateMeshType &  m,
Color4b  c = Color4b::White 
) [inline, static]

Definition at line 289 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexFromFace ( UpdateMeshType &  m  )  [inline, static]

Definition at line 109 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexQualityGray ( UpdateMeshType &  m  )  [inline, static]

Definition at line 388 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexQualityGray ( UpdateMeshType &  m,
const float  minq,
const float  maxq 
) [inline, static]

Definition at line 379 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexQualityRamp ( UpdateMeshType &  m  )  [inline, static]

Definition at line 373 of file color.h.

template<class UpdateMeshType >
static void vcg::tri::UpdateColor< UpdateMeshType >::VertexQualityRamp ( UpdateMeshType &  m,
float  minq,
float  maxq 
) [inline, static]

Definition at line 364 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::VertexSelected ( UpdateMeshType &  m,
Color4b  vs = Color4b::LightBlue 
) [inline, static]

Definition at line 277 of file color.h.

template<class UpdateMeshType >
static int vcg::tri::UpdateColor< UpdateMeshType >::WhiteBalance ( UpdateMeshType &  m,
bool  automatic,
Color4b  userColor,
const bool  ProcessSelected = false 
) [inline, static]

Definition at line 806 of file color.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


vcglib
Author(s): Christian Bersch
autogenerated on Fri Jan 11 09:23:36 2013