DD::Image::rPoint Class Reference

Inherits DD::Image::rPrimitive.

List of all members.

Public Member Functions

const char * Class ()
 rPoint (const GeoInfo *info, const Primitive *p, Point::RenderMode mode, float r)
 rPoint (const GeoInfo *info, const Primitive *p, int mode, float r)
 rPoint (const GeoInfo *info, const Primitive *p, Point::RenderMode mode, const Vector4 &color, float r)
 rPoint (const GeoInfo *info, const Primitive *p, int mode, const Vector4 &color, float r)
 rPoint (const rPoint &)
bool add_to_render (Scene *, PrimitiveContext *)
bool intersect (float x, float y) const
bool intersect (float x, float y, float *dist) const
bool intersect_dist_squared (float x, float y, float *dist_squared) const
bool intersect_scanline (float y, int &X, int &R, VArray &out, VArray &du, VArray &dv) const
rPrimitiveType getPrimitiveType () const
float trace (Scene *)
float distance (float x, float y) const
float distance_squared (float x, float y) const

Public Attributes

VArray v
Point::RenderMode render_mode
float radius
Vector4 _color


Detailed Description

Renderable point primitive.

Member Function Documentation

bool rPoint::add_to_render ( Scene scene,
PrimitiveContext ptx 
) [virtual]

bool rPoint::intersect_scanline ( float  y,
int &  X,
int &  R,
VArray out,
VArray du,
VArray dv 
) const [virtual]

Intersect the point with a scanline. Return whether it was successful and the left and right intersection vertices.

Implements DD::Image::rPrimitive.

References DD::Image::VArray::channels, DD::Image::Box3::f(), DD::Image::VArray::UV(), DD::Image::VArray::x(), and DD::Image::VArray::y().

float rPoint::trace ( Scene scene  )  [virtual]

Not implemented yet.

Implements DD::Image::rPrimitive.

float rPoint::distance ( float  x,
float  y 
) const [virtual]

Distance the given screen-space point is away from the object. Returns 0 or negative if inside the object.

Implements DD::Image::rPrimitive.

References DD::Image::VArray::P(), DD::Image::Vector4::x, and DD::Image::Vector4::y.

float rPoint::distance_squared ( float  x,
float  y 
) const [virtual]

Square of the distance to the nearest edge the object in screen-space. Returns 0 or negative if inside the object.

Implements DD::Image::rPrimitive.

References DD::Image::Box3::d().



©2009 The Foundry Visionmongers, Ltd. All Rights Reserved.
www.thefoundry.co.uk