#include <brush.h>
Data Structures | |
class | TypeCasts |
Public Types | |
typedef LazyStatic< TypeCasts > | StaticTypeCasts |
typedef MemberCaller < BrushInstance,&BrushInstance::lightsChanged > | LightsChangedCaller |
typedef MemberCaller1 < BrushInstance, const Selectable &,&BrushInstance::selectedChanged > | SelectedChangedCaller |
typedef MemberCaller1 < BrushInstance, const Selectable &,&BrushInstance::selectedChangedComponent > | SelectedChangedComponentCaller |
typedef MemberCaller < BrushInstance,&BrushInstance::applyTransform > | ApplyTransformCaller |
Public Member Functions | |
void | lightsChanged () |
STRING_CONSTANT (Name,"BrushInstance") | |
BrushInstance (const scene::Path &path, scene::Instance *parent, Brush &brush) | |
~BrushInstance () | |
Brush & | getBrush () |
const Brush & | getBrush () const |
Bounded & | get (NullType< Bounded >) |
Cullable & | get (NullType< Cullable >) |
Transformable & | get (NullType< Transformable >) |
void | selectedChanged (const Selectable &selectable) |
void | selectedChangedComponent (const Selectable &selectable) |
const BrushInstanceVisitor & | forEachFaceInstance (const BrushInstanceVisitor &visitor) |
void | clear () |
void | reserve (std::size_t size) |
void | push_back (Face &face) |
void | pop_back () |
void | erase (std::size_t index) |
void | connectivityChanged () |
void | edge_clear () |
void | edge_push_back (SelectableEdge &edge) |
void | vertex_clear () |
void | vertex_push_back (SelectableVertex &vertex) |
void | DEBUG_verify () const |
bool | isSelected () const |
void | setSelected (bool select) |
void | update_selected () const |
void | evaluateViewDependent (const VolumeTest &volume, const Matrix4 &localToWorld) const |
void | renderComponentsSelected (Renderer &renderer, const VolumeTest &volume, const Matrix4 &localToWorld) const |
void | renderComponents (Renderer &renderer, const VolumeTest &volume) const |
void | renderClipPlane (Renderer &renderer, const VolumeTest &volume) const |
void | renderCommon (Renderer &renderer, const VolumeTest &volume) const |
void | renderSolid (Renderer &renderer, const VolumeTest &volume, const Matrix4 &localToWorld) const |
void | renderWireframe (Renderer &renderer, const VolumeTest &volume, const Matrix4 &localToWorld) const |
void | renderSolid (Renderer &renderer, const VolumeTest &volume) const |
void | renderWireframe (Renderer &renderer, const VolumeTest &volume) const |
void | viewChanged () const |
void | testSelect (Selector &selector, SelectionTest &test) |
bool | isSelectedComponents () const |
void | setSelectedComponents (bool select, SelectionSystem::EComponentMode mode) |
void | testSelectComponents (Selector &selector, SelectionTest &test, SelectionSystem::EComponentMode mode) |
void | selectPlanes (Selector &selector, SelectionTest &test, const PlaneCallback &selectedPlaneCallback) |
void | selectReversedPlanes (Selector &selector, const SelectedPlanes &selectedPlanes) |
void | transformComponents (const Matrix4 &matrix) |
const AABB & | getSelectedComponentsBounds () const |
void | snapComponents (float snap) |
void | evaluateTransform () |
void | applyTransform () |
void | setClipPlane (const Plane3 &plane) |
Static Public Member Functions | |
static void | constructStatic () |
static void | destroyStatic () |
Static Public Attributes | |
static Counter * | m_counter |
Private Types | |
typedef std::vector< EdgeInstance > | EdgeInstances |
typedef std::vector < VertexInstance > | VertexInstances |
Private Member Functions | |
BrushInstance (const BrushInstance &other) | |
BrushInstance & | operator= (const BrushInstance &other) |
Private Attributes | |
Brush & | m_brush |
FaceInstances | m_faceInstances |
EdgeInstances | m_edgeInstances |
VertexInstances | m_vertexInstances |
ObservedSelectable | m_selectable |
RenderableWireframe | m_render_wireframe |
RenderablePointVector | m_render_selected |
AABB | m_aabb_component |
Array< PointVertex > | m_faceCentroidPointsCulled |
RenderablePointArray | m_render_faces_wireframe |
bool | m_viewChanged |
BrushClipPlane | m_clipPlane |
const LightList * | m_lightList |
TransformModifier | m_transform |
Static Private Attributes | |
static Shader * | m_state_selpoint |
Definition at line 2905 of file brush.h.
typedef MemberCaller<BrushInstance, &BrushInstance::applyTransform> BrushInstance::ApplyTransformCaller |
typedef std::vector<EdgeInstance> BrushInstance::EdgeInstances [private] |
typedef MemberCaller<BrushInstance, &BrushInstance::lightsChanged> BrushInstance::LightsChangedCaller |
typedef MemberCaller1<BrushInstance, const Selectable&, &BrushInstance::selectedChanged> BrushInstance::SelectedChangedCaller |
typedef MemberCaller1<BrushInstance, const Selectable&, &BrushInstance::selectedChangedComponent> BrushInstance::SelectedChangedComponentCaller |
typedef LazyStatic<TypeCasts> BrushInstance::StaticTypeCasts |
typedef std::vector<VertexInstance> BrushInstance::VertexInstances [private] |
BrushInstance::BrushInstance | ( | const BrushInstance & | other | ) | [private] |
BrushInstance::BrushInstance | ( | const scene::Path & | path, | |
scene::Instance * | parent, | |||
Brush & | brush | |||
) | [inline] |
Definition at line 2981 of file brush.h.
References Brush::attach(), Brush::instanceAttach(), m_brush, m_counter, m_lightList, and Brush::m_lightsChanged.
BrushInstance::~BrushInstance | ( | ) | [inline] |
Definition at line 2996 of file brush.h.
References Brush::detach(), Brush::instanceDetach(), m_brush, m_counter, and Brush::m_lightsChanged.
void BrushInstance::applyTransform | ( | ) | [inline] |
Definition at line 3374 of file brush.h.
References evaluateTransform(), Brush::freezeTransform(), m_brush, and Brush::revertTransform().
void BrushInstance::clear | ( | ) | [inline, virtual] |
void BrushInstance::connectivityChanged | ( | ) | [inline, virtual] |
Implements BrushObserver.
Definition at line 3087 of file brush.h.
References i, and m_faceInstances.
static void BrushInstance::constructStatic | ( | ) | [inline, static] |
Definition at line 3055 of file brush.h.
References m_state_selpoint.
void BrushInstance::DEBUG_verify | ( | ) | const [inline, virtual] |
Implements BrushObserver.
Definition at line 3112 of file brush.h.
References Brush::DEBUG_size(), m_brush, and m_faceInstances.
static void BrushInstance::destroyStatic | ( | ) | [inline, static] |
void BrushInstance::edge_clear | ( | ) | [inline, virtual] |
void BrushInstance::edge_push_back | ( | SelectableEdge & | edge | ) | [inline, virtual] |
Implements BrushObserver.
Definition at line 3098 of file brush.h.
References m_edgeInstances, and m_faceInstances.
void BrushInstance::erase | ( | std::size_t | index | ) | [inline, virtual] |
void BrushInstance::evaluateTransform | ( | ) | [inline] |
Definition at line 3364 of file brush.h.
References m_brush, m_transform, Brush::transform(), and transformComponents().
Referenced by applyTransform().
void BrushInstance::evaluateViewDependent | ( | const VolumeTest & | volume, | |
const Matrix4 & | localToWorld | |||
) | const [inline] |
Definition at line 3136 of file brush.h.
References i, m_brush, m_faceCentroidPointsCulled, m_faceInstances, m_render_wireframe, m_viewChanged, Brush::update_faces_wireframe(), and Brush::update_wireframe().
Referenced by renderComponents(), and renderWireframe().
const BrushInstanceVisitor& BrushInstance::forEachFaceInstance | ( | const BrushInstanceVisitor & | visitor | ) | [inline] |
Definition at line 3047 of file brush.h.
References i, m_faceInstances, and BrushInstanceVisitor::visit().
Referenced by Brush_forEachFace(), Brush_ForEachFaceInstance(), and BrushForEachFace::operator()().
Transformable& BrushInstance::get | ( | NullType< Transformable > | ) | [inline] |
Definition at line 3025 of file brush.h.
References m_transform.
Definition at line 3017 of file brush.h.
References m_brush.
Referenced by BrushVisibleSelectedVisitor< Functor >::visit().
const Brush& BrushInstance::getBrush | ( | ) | const [inline] |
Brush& BrushInstance::getBrush | ( | ) | [inline] |
Definition at line 3008 of file brush.h.
References m_brush.
Referenced by CExportFormatWavefront::visit().
const AABB& BrushInstance::getSelectedComponentsBounds | ( | ) | const [inline] |
Definition at line 3347 of file brush.h.
References i, m_aabb_component, and m_faceInstances.
bool BrushInstance::isSelected | ( | ) | const [inline, virtual] |
Implements Selectable.
Definition at line 3117 of file brush.h.
References m_selectable.
Referenced by renderClipPlane(), and renderCommon().
bool BrushInstance::isSelectedComponents | ( | ) | const [inline] |
Definition at line 3270 of file brush.h.
References i, and m_faceInstances.
void BrushInstance::lightsChanged | ( | ) | [inline] |
Definition at line 2973 of file brush.h.
References m_lightList.
BrushInstance& BrushInstance::operator= | ( | const BrushInstance & | other | ) | [private] |
void BrushInstance::pop_back | ( | ) | [inline, virtual] |
void BrushInstance::push_back | ( | Face & | face | ) | [inline, virtual] |
void BrushInstance::renderClipPlane | ( | Renderer & | renderer, | |
const VolumeTest & | volume | |||
) | const [inline] |
Definition at line 3184 of file brush.h.
References SelectionSystem::eClip, GlobalSelectionSystem(), isSelected(), m_clipPlane, and BrushClipPlane::render().
Referenced by renderSolid(), and renderWireframe().
void BrushInstance::renderCommon | ( | Renderer & | renderer, | |
const VolumeTest & | volume | |||
) | const [inline] |
Definition at line 3191 of file brush.h.
References SelectionSystem::eComponent, Renderer::eFace, Renderer::ePrimitive, GlobalSelectionSystem(), Renderer::Highlight(), isSelected(), SelectionSystem::Mode(), and renderComponents().
void BrushInstance::renderComponents | ( | Renderer & | renderer, | |
const VolumeTest & | volume | |||
) | const [inline, virtual] |
Reimplemented from Renderable.
Definition at line 3167 of file brush.h.
References Renderer::addRenderable(), SelectionSystem::ComponentMode(), SelectionSystem::eFace, Renderer::eFullMaterials, Brush::evaluateBRep(), evaluateViewDependent(), Renderer::eWireframeOnly, VolumeTest::fill(), GlobalSelectionSystem(), m_brush, m_render_faces_wireframe, Brush::m_state_point, Brush::renderComponents(), and Renderer::SetState().
Referenced by renderCommon().
void BrushInstance::renderComponentsSelected | ( | Renderer & | renderer, | |
const VolumeTest & | volume, | |||
const Matrix4 & | localToWorld | |||
) | const [inline] |
Definition at line 3154 of file brush.h.
References Renderer::addRenderable(), Renderer::eFullMaterials, Renderer::ePrimitive, Brush::evaluateBRep(), Renderer::eWireframeOnly, Renderer::Highlight(), m_brush, m_render_selected, m_state_selpoint, Renderer::SetState(), and update_selected().
Referenced by renderSolid(), and renderWireframe().
void BrushInstance::renderSolid | ( | Renderer & | renderer, | |
const VolumeTest & | volume | |||
) | const [inline, virtual] |
Submit renderable geometry when rendering takes place in Solid mode.
Implements Renderable.
Definition at line 3234 of file brush.h.
References Brush::evaluateBRep(), m_brush, renderClipPlane(), and renderSolid().
void BrushInstance::renderSolid | ( | Renderer & | renderer, | |
const VolumeTest & | volume, | |||
const Matrix4 & | localToWorld | |||
) | const [inline] |
Definition at line 3207 of file brush.h.
References i, m_faceInstances, m_lightList, renderComponentsSelected(), and Renderer::setLights().
Referenced by renderSolid().
void BrushInstance::renderWireframe | ( | Renderer & | renderer, | |
const VolumeTest & | volume | |||
) | const [inline, virtual] |
Submit renderable geometry when rendering takes place in Wireframe mode
Implements Renderable.
Definition at line 3243 of file brush.h.
References Brush::evaluateBRep(), m_brush, renderClipPlane(), and renderWireframe().
void BrushInstance::renderWireframe | ( | Renderer & | renderer, | |
const VolumeTest & | volume, | |||
const Matrix4 & | localToWorld | |||
) | const [inline] |
Definition at line 3221 of file brush.h.
References Renderer::addRenderable(), evaluateViewDependent(), m_render_wireframe, RenderableWireframe::m_size, and renderComponentsSelected().
Referenced by renderWireframe().
void BrushInstance::reserve | ( | std::size_t | size | ) | [inline, virtual] |
void BrushInstance::selectedChanged | ( | const Selectable & | selectable | ) | [inline] |
Definition at line 3030 of file brush.h.
References SelectionSystem::ePrimitive, SelectionSystem::getObserver(), GlobalSelectionSystem(), and SelectionSystem::onSelectedChanged().
void BrushInstance::selectedChangedComponent | ( | const Selectable & | selectable | ) | [inline] |
Definition at line 3039 of file brush.h.
References SelectionSystem::eComponent, SelectionSystem::getObserver(), GlobalSelectionSystem(), and SelectionSystem::onComponentSelection().
void BrushInstance::selectPlanes | ( | Selector & | selector, | |
SelectionTest & | test, | |||
const PlaneCallback & | selectedPlaneCallback | |||
) | [inline, virtual] |
Implements PlaneSelectable.
Definition at line 3319 of file brush.h.
References Brush::begin(), SelectionTest::BeginMesh(), Brush::end(), SelectionTest::getFar(), SelectionTest::getNear(), i, m_brush, and m_faceInstances.
void BrushInstance::selectReversedPlanes | ( | Selector & | selector, | |
const SelectedPlanes & | selectedPlanes | |||
) | [inline, virtual] |
Implements PlaneSelectable.
Definition at line 3334 of file brush.h.
References i, and m_faceInstances.
void BrushInstance::setClipPlane | ( | const Plane3 & | plane | ) | [inline] |
Definition at line 3382 of file brush.h.
References m_brush, m_clipPlane, and BrushClipPlane::setPlane().
void BrushInstance::setSelected | ( | bool | select | ) | [inline, virtual] |
void BrushInstance::setSelectedComponents | ( | bool | select, | |
SelectionSystem::EComponentMode | mode | |||
) | [inline] |
Definition at line 3279 of file brush.h.
References i, and m_faceInstances.
void BrushInstance::snapComponents | ( | float | snap | ) | [inline] |
Definition at line 3358 of file brush.h.
References i, and m_faceInstances.
BrushInstance::STRING_CONSTANT | ( | Name | , | |
"BrushInstance" | ||||
) |
void BrushInstance::testSelect | ( | Selector & | selector, | |
SelectionTest & | test | |||
) | [inline, virtual] |
Implements SelectionTestable.
Definition at line 3257 of file brush.h.
References Selector::addIntersection(), SelectionTest::BeginMesh(), i, m_faceInstances, and SelectionIntersection::valid().
void BrushInstance::testSelectComponents | ( | Selector & | selector, | |
SelectionTest & | test, | |||
SelectionSystem::EComponentMode | mode | |||
) | [inline] |
Definition at line 3285 of file brush.h.
References SelectionTest::BeginMesh(), SelectionSystem::eEdge, SelectionSystem::eFace, SelectionSystem::eVertex, VolumeTest::fill(), SelectionTest::getVolume(), i, m_edgeInstances, m_faceInstances, and m_vertexInstances.
void BrushInstance::transformComponents | ( | const Matrix4 & | matrix | ) | [inline] |
Definition at line 3341 of file brush.h.
References i, and m_faceInstances.
Referenced by evaluateTransform().
void BrushInstance::update_selected | ( | ) | const [inline] |
Definition at line 3126 of file brush.h.
References i, m_faceInstances, and m_render_selected.
Referenced by renderComponentsSelected().
void BrushInstance::vertex_clear | ( | ) | [inline, virtual] |
void BrushInstance::vertex_push_back | ( | SelectableVertex & | vertex | ) | [inline, virtual] |
Implements BrushObserver.
Definition at line 3107 of file brush.h.
References m_faceInstances, and m_vertexInstances.
void BrushInstance::viewChanged | ( | ) | const [inline, virtual] |
AABB BrushInstance::m_aabb_component [mutable, private] |
Definition at line 2953 of file brush.h.
Referenced by getSelectedComponentsBounds().
Brush& BrushInstance::m_brush [private] |
Definition at line 2940 of file brush.h.
Referenced by applyTransform(), BrushInstance(), DEBUG_verify(), evaluateTransform(), evaluateViewDependent(), get(), getBrush(), renderComponents(), renderComponentsSelected(), renderSolid(), renderWireframe(), selectPlanes(), setClipPlane(), and ~BrushInstance().
BrushClipPlane BrushInstance::m_clipPlane [private] |
Definition at line 2958 of file brush.h.
Referenced by renderClipPlane(), and setClipPlane().
Counter* BrushInstance::m_counter [static] |
Definition at line 2969 of file brush.h.
Referenced by BrushInstance(), and ~BrushInstance().
EdgeInstances BrushInstance::m_edgeInstances [private] |
Definition at line 2945 of file brush.h.
Referenced by edge_clear(), edge_push_back(), and testSelectComponents().
Array<PointVertex> BrushInstance::m_faceCentroidPointsCulled [mutable, private] |
Definition at line 2954 of file brush.h.
Referenced by evaluateViewDependent().
FaceInstances BrushInstance::m_faceInstances [private] |
Definition at line 2942 of file brush.h.
Referenced by clear(), connectivityChanged(), DEBUG_verify(), edge_push_back(), erase(), evaluateViewDependent(), forEachFaceInstance(), getSelectedComponentsBounds(), isSelectedComponents(), pop_back(), push_back(), renderSolid(), reserve(), selectPlanes(), selectReversedPlanes(), setSelectedComponents(), snapComponents(), testSelect(), testSelectComponents(), transformComponents(), update_selected(), and vertex_push_back().
const LightList* BrushInstance::m_lightList [private] |
Definition at line 2962 of file brush.h.
Referenced by BrushInstance(), lightsChanged(), and renderSolid().
RenderablePointArray BrushInstance::m_render_faces_wireframe [private] |
Definition at line 2955 of file brush.h.
Referenced by renderComponents().
RenderablePointVector BrushInstance::m_render_selected [mutable, private] |
Definition at line 2952 of file brush.h.
Referenced by renderComponentsSelected(), and update_selected().
RenderableWireframe BrushInstance::m_render_wireframe [mutable, private] |
Definition at line 2951 of file brush.h.
Referenced by evaluateViewDependent(), and renderWireframe().
ObservedSelectable BrushInstance::m_selectable [private] |
Definition at line 2949 of file brush.h.
Referenced by isSelected(), and setSelected().
Shader* BrushInstance::m_state_selpoint [static, private] |
Definition at line 2960 of file brush.h.
Referenced by constructStatic(), and renderComponentsSelected().
TransformModifier BrushInstance::m_transform [private] |
Definition at line 2964 of file brush.h.
Referenced by evaluateTransform(), and get().
Definition at line 2947 of file brush.h.
Referenced by testSelectComponents(), vertex_clear(), and vertex_push_back().
bool BrushInstance::m_viewChanged [mutable, private] |
Definition at line 2956 of file brush.h.
Referenced by evaluateViewDependent(), and viewChanged().