Main Page | Modules | Data Structures | File List | Data Fields | Globals | Related Pages

colour_coding.c File Reference

#include <volume_io/internal_volume_io.h>
#include <bicpl/vols.h>

Include dependency graph for colour_coding.c:

Include dependency graph

Go to the source code of this file.

Functions

private void interpolate_colours (colour_point *p1, colour_point *p2, Real pos, Real *r, Real *g, Real *b, Real *a)
private void recreate_piecewise_function (colour_coding_struct *colour_coding, Colour_coding_types type, BOOLEAN set_user_defined)
public void initialize_colour_coding (colour_coding_struct *colour_coding, Colour_coding_types type, Colour under_colour, Colour over_colour, Real min_value, Real max_value)
public void delete_colour_coding (colour_coding_struct *colour_coding)
public void set_colour_coding_type (colour_coding_struct *colour_coding, Colour_coding_types type)
public Colour_coding_types get_colour_coding_type (colour_coding_struct *colour_coding)
public void set_colour_coding_min_max (colour_coding_struct *colour_coding, Real min_value, Real max_value)
public void get_colour_coding_min_max (colour_coding_struct *colour_coding, Real *min_value, Real *max_value)
public Colour get_colour_coding_under_colour (colour_coding_struct *colour_coding)
public void set_colour_coding_under_colour (colour_coding_struct *colour_coding, Colour under_colour)
public Colour get_colour_coding_over_colour (colour_coding_struct *colour_coding)
public void set_colour_coding_over_colour (colour_coding_struct *colour_coding, Colour over_colour)
public BOOLEAN define_colour_coding_user_defined (colour_coding_struct *colour_code, int n_colours, Colour colours[], Real positions[], Colour_spaces interpolation_space)
public Colour get_colour_code (colour_coding_struct *colour_coding, Real value)


Function Documentation

public BOOLEAN define_colour_coding_user_defined colour_coding_struct colour_code,
int  n_colours,
Colour  colours[],
Real  positions[],
Colour_spaces  interpolation_space
 

Definition at line 454 of file colour_coding.c.

References colour_point::a, colour_point::b, FALSE, colour_point::g, get_colour_coding_type(), colour_point::interpolation_space, colour_point::position, colour_point::r, recreate_piecewise_function(), TRUE, USER_DEFINED_COLOUR_MAP, colour_coding_struct::user_defined_colour_points, and colour_coding_struct::user_defined_n_colour_points.

Referenced by input_user_defined_colour_coding().

public void delete_colour_coding colour_coding_struct colour_coding  ) 
 

Definition at line 85 of file colour_coding.c.

References colour_coding_struct::colour_points, colour_coding_struct::n_colour_points, colour_coding_struct::user_defined_colour_points, and colour_coding_struct::user_defined_n_colour_points.

public Colour get_colour_code colour_coding_struct colour_coding,
Real  value
 

Definition at line 540 of file colour_coding.c.

References colour_coding_struct::colour_points, interpolate_colours(), colour_coding_struct::max_value, colour_coding_struct::min_value, colour_coding_struct::n_colour_points, colour_coding_struct::over_colour, colour_point::position, and colour_coding_struct::under_colour.

Referenced by colour_code_points().

public void get_colour_coding_min_max colour_coding_struct colour_coding,
Real *  min_value,
Real *  max_value
 

Definition at line 174 of file colour_coding.c.

References colour_coding_struct::max_value, and colour_coding_struct::min_value.

public Colour get_colour_coding_over_colour colour_coding_struct colour_coding  ) 
 

Definition at line 236 of file colour_coding.c.

References colour_coding_struct::over_colour.

public Colour_coding_types get_colour_coding_type colour_coding_struct colour_coding  ) 
 

Definition at line 130 of file colour_coding.c.

References Colour_coding_types, and colour_coding_struct::type.

Referenced by define_colour_coding_user_defined(), and set_colour_coding_over_colour().

public Colour get_colour_coding_under_colour colour_coding_struct colour_coding  ) 
 

Definition at line 196 of file colour_coding.c.

References colour_coding_struct::under_colour.

public void initialize_colour_coding colour_coding_struct colour_coding,
Colour_coding_types  type,
Colour  under_colour,
Colour  over_colour,
Real  min_value,
Real  max_value
 

Definition at line 53 of file colour_coding.c.

References GRAY_SCALE, colour_coding_struct::n_colour_points, recreate_piecewise_function(), set_colour_coding_min_max(), set_colour_coding_over_colour(), set_colour_coding_type(), set_colour_coding_under_colour(), TRUE, and colour_coding_struct::user_defined_n_colour_points.

private void interpolate_colours colour_point p1,
colour_point p2,
Real  pos,
Real *  r,
Real *  g,
Real *  b,
Real *  a
 

Definition at line 603 of file colour_coding.c.

References colour_point::a, colour_point::b, colour_point::g, HSL_SPACE, hsl_to_rgb(), colour_point::interpolation_space, colour_point::position, colour_point::r, and rgb_to_hsl().

Referenced by get_colour_code().

private void recreate_piecewise_function colour_coding_struct colour_coding,
Colour_coding_types  type,
BOOLEAN  set_user_defined
 

Definition at line 289 of file colour_coding.c.

References BLUE_COLOUR_MAP, colour_coding_struct::colour_points, CONTOUR_COLOUR_MAP, GRAY_SCALE, GREEN_COLOUR_MAP, HOT_METAL, colour_coding_struct::n_colour_points, colour_coding_struct::over_colour, RED_COLOUR_MAP, RGB_SPACE, SINGLE_COLOUR_SCALE, SPECTRAL, USER_DEFINED_COLOUR_MAP, colour_coding_struct::user_defined_colour_points, and colour_coding_struct::user_defined_n_colour_points.

Referenced by define_colour_coding_user_defined(), initialize_colour_coding(), set_colour_coding_over_colour(), and set_colour_coding_type().

public void set_colour_coding_min_max colour_coding_struct colour_coding,
Real  min_value,
Real  max_value
 

Definition at line 151 of file colour_coding.c.

References colour_coding_struct::max_value, and colour_coding_struct::min_value.

Referenced by initialize_colour_coding().

public void set_colour_coding_over_colour colour_coding_struct colour_coding,
Colour  over_colour
 

Definition at line 256 of file colour_coding.c.

References FALSE, get_colour_coding_type(), colour_coding_struct::over_colour, recreate_piecewise_function(), and SINGLE_COLOUR_SCALE.

Referenced by initialize_colour_coding().

public void set_colour_coding_type colour_coding_struct colour_coding,
Colour_coding_types  type
 

Definition at line 108 of file colour_coding.c.

References FALSE, recreate_piecewise_function(), and colour_coding_struct::type.

Referenced by initialize_colour_coding().

public void set_colour_coding_under_colour colour_coding_struct colour_coding,
Colour  under_colour
 

Definition at line 216 of file colour_coding.c.

References colour_coding_struct::under_colour.

Referenced by initialize_colour_coding().


Generated on Wed Jul 28 09:11:01 2004 for BICPL by doxygen 1.3.7