MetaObject Class Reference
A MetaObject exerts a positive or negative 'charge' in a scalar field, whose isocontours (level sets) define blobby surfaces with different threshold values corresponding to the contour level. MetaObjects positively or negatively affect their neighboring MetaObjects depending on their 'strength' and 'negative' attributes. 'strength' defines the initial charge of the object, and 'negative' is a boolean which defaults to false, denoting whether or not this MetaObject has a positive or a negative impact on surrounding MetaObjects. MetaObject is an abstract class, and specific implementations define how its initial charge dissipates throughout the field. More...
#include <MetaObject.h>

Public Member Functions | |
Constructors | |
| MetaObject (real_t strength=1.0, bool negative=false) | |
| virtual | ~MetaObject () |
Core functionality | |
| virtual void | init () |
| Performs any initialization which may be necessary before calling getAABB or evaluate. | |
| virtual AABB | getAABB () const =0 |
| virtual real_t | evaluate (const Point3 &pt) const =0 |
Accessors / Mutators | |
| real_t | getStrength () const |
| void | setStrength (real_t strength) |
| sets the initial charge of this object | |
| bool | isNegative () const |
| void | setIsNegative (bool negative) |
Protected Attributes | |
| real_t | m_strength |
| bool | m_isNegative |
Detailed Description
A MetaObject exerts a positive or negative 'charge' in a scalar field, whose isocontours (level sets) define blobby surfaces with different threshold values corresponding to the contour level. MetaObjects positively or negatively affect their neighboring MetaObjects depending on their 'strength' and 'negative' attributes. 'strength' defines the initial charge of the object, and 'negative' is a boolean which defaults to false, denoting whether or not this MetaObject has a positive or a negative impact on surrounding MetaObjects. MetaObject is an abstract class, and specific implementations define how its initial charge dissipates throughout the field.
- Date:
- Spring 2008
- Parameters:
-
strength - initial charge of object (defaults to 1.0) negative - whether or not this metaobject has a positive or negative impact on surrounding MetaObjects (defaults to false)
Definition at line 36 of file MetaObject.h.
Constructor & Destructor Documentation
| MetaObject::MetaObject | ( | real_t | strength = 1.0, |
|
| bool | negative = false | |||
| ) | [inline] |
Definition at line 41 of file MetaObject.h.
| virtual MetaObject::~MetaObject | ( | ) | [inline, virtual] |
Definition at line 46 of file MetaObject.h.
Member Function Documentation
| void MetaObject::init | ( | ) | [virtual] |
Performs any initialization which may be necessary before calling getAABB or evaluate.
- Note:
- Implementations will likely want to precompute their AABB in init and store it for later since getAABB may be called often
Default implementation synchs parameters from PropertyMap
Reimplemented in Blob, and MetaBall.
Definition at line 31 of file MetaObject.cpp.
| virtual AABB MetaObject::getAABB | ( | ) | const [pure virtual] |
- Returns:
- the bounding box of influence which bounds the range in which this MetaObject may have a non-zero charge
Implements ScalarField.
- Returns:
- this MetaObject's charge at the given point
- Note:
- If the given point is outside of this MetaObject's AABB, evaluate is assumed to return zero
Implements ScalarField.
| real_t MetaObject::getStrength | ( | ) | const [inline] |
| void MetaObject::setStrength | ( | real_t | strength | ) | [inline] |
| bool MetaObject::isNegative | ( | ) | const [inline] |
- Returns:
- whether or not this MetaObject has a positive or negative influence on surrounding MetaObjects
Definition at line 100 of file MetaObject.h.
| void MetaObject::setIsNegative | ( | bool | negative | ) | [inline] |
sets whether or not this MetaObject has a positive or negative influence on surrounding MetaObjects
Definition at line 106 of file MetaObject.h.
Member Data Documentation
real_t MetaObject::m_strength [protected] |
Definition at line 114 of file MetaObject.h.
bool MetaObject::m_isNegative [protected] |
Definition at line 115 of file MetaObject.h.
The documentation for this class was generated from the following files:
Generated on 28 Feb 2009 for Milton by
1.5.6