Index

C++ Code Documentation

geom::surface::Material

Children: geom::surfacegl::Material

File: GEOM/geom/surface/Material.H

Materials for an OpenGL drawable surface, such as color and shininess.

public:
  • Material();
    void constructor
  • ~Material();
    destructor.
  • Material( Material const & );
    copy constructor
  • Material &operator=( Material const & );
    assignment operator
  • void copy( Material const & );
  • void reset();
    returns: false if object is invisible either because show==false or size is too small true otherwise
  • void dump( ::io::Ostream &o ) const;
  • bool const &enable() const;
  • base::Color4 const &color() const;
  • base::Color3 const &ambient() const;
  • base::Color4 const &diffuse() const;
  • base::Color3 const &specular() const;
  • base::Color3 const &emissive() const;
  • float const &shininess() const;
  • float const &element_size() const;
  • base::ArrayX<float,2U> const &gap() const;
  • uint const &model() const;
  • bool const &shademodel() const;
  • base::ArrayX<float,2U> const &nudge() const;
  • base::ArrayX<uint,2U>const &side() const;
  • bool const &lit() const;
  • bool const &transparent() const;
  • bool const &custom_color() const;
  • void enable( bool a );
  • void color( base::Color4 const &a );
  • void ambient( base::Color3 const &a );
  • void diffuse( base::Color4 const &a );
  • void specular( base::Color3 const &a );
  • void emissive( base::Color3 const &a );
  • void shininess( float a );
  • void element_size( float a );
  • void gap( base::ArrayX<float,2U> const &a );
  • void model( uint const &a );
  • void shademodel( bool a );
  • void nudge( base::ArrayX<float,2U> const &a );
  • void side( base::ArrayX<uint,2U> const &a );
  • void lit( bool a );
  • void transparent( bool a );
  • void custom_color( bool a );
protected:
  • bool _enable;
    false means don't draw the object
  • base::Color4 _color;
    material attributes colors are in RGB or RGBA format
  • base::Color3 _ambient;
  • base::Color4 _diffuse;
  • base::Color3 _specular;
  • base::Color3 _emissive;
  • float _shininess;
  • float _element_size;
    size: size of element (point size, line width, face size)
  • base::ArrayX<float,2U> _gap;
  • uint _model;
    material model: 0 = GL_FALSE 1 = GL_AMBIENT 2 = GL_DIFFUSE 3 = GL_AMBIENT_AND_DIFFUSE 4 = GL_SPECULAR 5 = GL_EMISSION
  • bool _custom_color;
  • bool _shademodel;
    what shademodel to draw the surface 0 = GL_FLAT 1 = GL_SMOOTH
  • base::ArrayX<float,2U> _nudge;
    used by glPolygonOffset
  • base::ArrayX<uint,2U> _side;
    which sides to sho 0=none, 1=point 2=line 3=fill
  • bool _lit;
  • bool _transparent;
  • static GLenum const material_model[6];
  • static GLenum const polygon_mode[3];
  • static GLenum const polygon_offset[3];
private:


geom::surface::Material GANG