Blender  V2.93
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
Freestyle::ViewMap Class Reference

#include <ViewMap.h>

Public Types

typedef vector< ViewEdge * > viewedges_container
 
typedef vector< ViewVertex * > viewvertices_container
 
typedef vector< ViewShape * > viewshapes_container
 
typedef vector< SVertex * > svertices_container
 
typedef vector< FEdge * > fedges_container
 
typedef map< int, int > id_to_index_map
 

Public Member Functions

 ViewMap ()
 
virtual ~ViewMap ()
 
const ViewEdgegetClosestViewEdge (real x, real y) const
 
const FEdgegetClosestFEdge (real x, real y) const
 
viewshapes_containerViewShapes ()
 
viewedges_containerViewEdges ()
 
viewvertices_containerViewVertices ()
 
fedges_containerFEdges ()
 
svertices_containerSVertices ()
 
viewedges_container::iterator viewedges_begin ()
 
viewedges_container::iterator viewedges_end ()
 
int viewedges_size ()
 
ViewShapeviewShape (unsigned id)
 
id_to_index_mapshapeIdToIndexMap ()
 
BBox< Vec3rgetScene3dBBox () const
 
void AddViewShape (ViewShape *iVShape)
 
void AddViewEdge (ViewEdge *iVEdge)
 
void AddViewVertex (ViewVertex *iVVertex)
 
void AddFEdge (FEdge *iFEdge)
 
void AddSVertex (SVertex *iSVertex)
 
void setScene3dBBox (const BBox< Vec3r > &bbox)
 
TVertexCreateTVertex (const Vec3r &iA3D, const Vec3r &iA2D, FEdge *iFEdgeA, const Vec3r &iB3D, const Vec3r &iB2D, FEdge *iFEdgeB, const Id &id)
 
ViewVertexInsertViewVertex (SVertex *iVertex, vector< ViewEdge * > &newViewEdges)
 
virtual void Clean ()
 

Static Public Member Functions

static ViewMapgetInstance ()
 

Public Attributes

void * userdata
 

Detailed Description

Class defining the ViewMap.

Definition at line 60 of file ViewMap.h.

Member Typedef Documentation

◆ fedges_container

Definition at line 66 of file ViewMap.h.

◆ id_to_index_map

typedef map<int, int> Freestyle::ViewMap::id_to_index_map

Definition at line 67 of file ViewMap.h.

◆ svertices_container

Definition at line 65 of file ViewMap.h.

◆ viewedges_container

Definition at line 62 of file ViewMap.h.

◆ viewshapes_container

Definition at line 64 of file ViewMap.h.

◆ viewvertices_container

Definition at line 63 of file ViewMap.h.

Constructor & Destructor Documentation

◆ ViewMap()

Freestyle::ViewMap::ViewMap ( )
inline

Default constructor.

Definition at line 88 of file ViewMap.h.

References NULL, and userdata.

◆ ~ViewMap()

Freestyle::ViewMap::~ViewMap ( )
virtual

Destructor.

Definition at line 42 of file ViewMap.cpp.

Member Function Documentation

◆ AddFEdge()

void Freestyle::ViewMap::AddFEdge ( FEdge iFEdge)
inline

Definition at line 182 of file ViewMap.h.

Referenced by Freestyle::ViewMapIO::load().

◆ AddSVertex()

void Freestyle::ViewMap::AddSVertex ( SVertex iSVertex)
inline

Definition at line 187 of file ViewMap.h.

Referenced by CreateTVertex(), and Freestyle::ViewMapIO::load().

◆ AddViewEdge()

void Freestyle::ViewMap::AddViewEdge ( ViewEdge iVEdge)
inline

Definition at line 172 of file ViewMap.h.

Referenced by Freestyle::ViewMapIO::load().

◆ AddViewShape()

void Freestyle::ViewMap::AddViewShape ( ViewShape iVShape)

Definition at line 96 of file ViewMap.cpp.

References Freestyle::Id::getFirst(), and Freestyle::ViewShape::getId().

Referenced by Freestyle::ViewMapIO::load().

◆ AddViewVertex()

void Freestyle::ViewMap::AddViewVertex ( ViewVertex iVVertex)
inline

Definition at line 177 of file ViewMap.h.

Referenced by CreateTVertex(), and Freestyle::ViewMapIO::load().

◆ Clean()

void Freestyle::ViewMap::Clean ( )
virtual

Definition at line 63 of file ViewMap.cpp.

Referenced by Freestyle::Controller::DeleteViewMap().

◆ CreateTVertex()

TVertex * Freestyle::ViewMap::CreateTVertex ( const Vec3r iA3D,
const Vec3r iA2D,
FEdge iFEdgeA,
const Vec3r iB3D,
const Vec3r iB2D,
FEdge iFEdgeB,
const Id id 
)

◆ FEdges()

fedges_container& Freestyle::ViewMap::FEdges ( )
inline

◆ getClosestFEdge()

const FEdge * Freestyle::ViewMap::getClosestFEdge ( real  x,
real  y 
) const

Gets the Fedge the nearest to the 2D position specified as argument

Definition at line 102 of file ViewMap.cpp.

References A, B, Freestyle::x, and y.

◆ getClosestViewEdge()

const ViewEdge * Freestyle::ViewMap::getClosestViewEdge ( real  x,
real  y 
) const

Gets the viewedge the nearest to the 2D position specified as argument

Definition at line 121 of file ViewMap.cpp.

References A, B, Freestyle::FEdge::viewedge(), Freestyle::x, and y.

◆ getInstance()

static ViewMap* Freestyle::ViewMap::getInstance ( )
inlinestatic

The ViewMap is a singleton class. This static method returns the instance of the ViewMap.

Definition at line 105 of file ViewMap.h.

Referenced by Freestyle::Operators::reset(), and Freestyle::FEdge::z_discontinuity().

◆ getScene3dBBox()

BBox<Vec3r> Freestyle::ViewMap::getScene3dBBox ( ) const
inline

Returns the scene 3D bounding box.

Definition at line 164 of file ViewMap.h.

Referenced by Freestyle::FEdge::z_discontinuity().

◆ InsertViewVertex()

ViewVertex * Freestyle::ViewMap::InsertViewVertex ( SVertex iVertex,
vector< ViewEdge * > &  newViewEdges 
)

◆ setScene3dBBox()

void Freestyle::ViewMap::setScene3dBBox ( const BBox< Vec3r > &  bbox)
inline

Sets the scene 3D bounding box.

Definition at line 193 of file ViewMap.h.

Referenced by Freestyle::Controller::ComputeViewMap().

◆ shapeIdToIndexMap()

id_to_index_map& Freestyle::ViewMap::shapeIdToIndexMap ( )
inline

Definition at line 158 of file ViewMap.h.

Referenced by Freestyle::ViewMapIO::load(), and Freestyle::ViewMapIO::save().

◆ SVertices()

svertices_container& Freestyle::ViewMap::SVertices ( )
inline

◆ ViewEdges()

viewedges_container& Freestyle::ViewMap::ViewEdges ( )
inline

◆ viewedges_begin()

viewedges_container::iterator Freestyle::ViewMap::viewedges_begin ( )
inline

Definition at line 141 of file ViewMap.h.

◆ viewedges_end()

viewedges_container::iterator Freestyle::ViewMap::viewedges_end ( )
inline

Definition at line 146 of file ViewMap.h.

◆ viewedges_size()

int Freestyle::ViewMap::viewedges_size ( )
inline

Definition at line 151 of file ViewMap.h.

Referenced by Freestyle::Controller::ComputeViewMap().

◆ viewShape()

ViewShape * Freestyle::ViewMap::viewShape ( unsigned  id)

◆ ViewShapes()

viewshapes_container& Freestyle::ViewMap::ViewShapes ( )
inline

◆ ViewVertices()

viewvertices_container& Freestyle::ViewMap::ViewVertices ( )
inline

Member Data Documentation

◆ userdata

void* Freestyle::ViewMap::userdata

A field that can be used by the user to store any data. This field must be reset afterwards using ResetUserData().

Definition at line 85 of file ViewMap.h.

Referenced by ViewMap().


The documentation for this class was generated from the following files: