DD::Image::Point Class Reference

Inherits DD::Image::Primitive.

List of all members.

Public Types

enum  RenderMode {
  POINT, PARTICLE, DISC, SQUARE,
  SPHERE
}

Public Member Functions

const char * Class () const
 Point (int type, float radius=1.0f, unsigned point=0)
 Point (RenderMode type, float radius=1.0f, unsigned point=0)
 Point (const Point &)
float radius () const
void radius (float v)
RenderMode render_mode () const
void render_mode (RenderMode v)
Pointoperator= (const Point &b)
const Vector4getColor (PrimitiveContext *ptx) const
Primitiveduplicate () const
Vector3 average_center (const PointList *points) const
Vector3 average_center_and_bounds (int f, const PointList *points, Vector3 &min, Vector3 &max) const
void tessellate (Scene *, PrimitiveContext *) const
unsigned faces () const
void draw_wireframe (ViewerContext *, PrimitiveContext *, Primitive *prev_prim=0) const
void draw_solid (ViewerContext *, PrimitiveContext *, Primitive *prev_prim=0) const
void draw_primitive_num (ViewerContext *, PrimitiveContext *) const
PrimitiveType getPrimitiveType () const

Protected Member Functions

void copy (const Point *)

Protected Attributes

RenderMode render_mode_
float radius_

Detailed Description

Point primitive.


Member Function Documentation

void Point::copy ( const Point b) [protected]

Destructive copy.

Primitive * Point::duplicate ( ) const [virtual]

Copy this Point into a new one, and return a pointer to it. Vertex data is duplicated, point indices are unchanged.

Implements DD::Image::Primitive.

Vector3 DD::Image::Point::average_center ( const PointList *  points) const [inline, virtual]

Returns the xyz center average of the point.

Reimplemented from DD::Image::Primitive.

Vector3 DD::Image::Point::average_center_and_bounds ( int  f,
const PointList *  points,
Vector3 min,
Vector3 max 
) const [inline, virtual]

Returns the xyz center average of the primitive, plus local space bounds.

Reimplemented from DD::Image::Primitive.

void Point::tessellate ( Scene scene,
PrimitiveContext ptx 
) const [virtual]

Push a single rPoint primitive into the rendering stream.

Implements DD::Image::Primitive.

References DD::Image::Scene::add_render_primitive(), and DD::Image::Primitive::vertex_shader().