Blender V4.3
Freestyle::Controller Class Reference

#include <Controller.h>

Public Member Functions

 Controller ()
 
 ~Controller ()
 
void setView (AppView *iView)
 
void setRenderMonitor (RenderMonitor *iRenderMonitor)
 
void setPassDiffuse (float *buf, int width, int height)
 
void setPassZ (float *buf, int width, int height)
 
void setContext (bContext *C)
 
void init_options ()
 
int LoadMesh (Render *re, ViewLayer *view_layer, Depsgraph *depsgraph)
 
int Load3DSFile (const char *iFileName)
 
void CloseFile ()
 
void ComputeViewMap ()
 
void ComputeSteerableViewMap ()
 
void saveSteerableViewMapImages ()
 
void toggleEdgeTesselationNature (Nature::EdgeNature iNature)
 
int DrawStrokes ()
 
void ResetRenderCount ()
 
RenderRenderStrokes (Render *re, bool render)
 
void SwapStyleModules (uint i1, uint i2)
 
void InsertStyleModule (uint index, const char *iFileName)
 
void InsertStyleModule (uint index, const char *iName, const char *iBuffer)
 
void InsertStyleModule (uint index, const char *iName, struct Text *iText)
 
void AddStyleModule (const char *iFileName)
 
void RemoveStyleModule (uint index)
 
void ReloadStyleModule (uint index, const char *iFileName)
 
void Clear ()
 
void ClearRootNode ()
 
void DeleteWingedEdge ()
 
void DeleteViewMap (bool freeCache=false)
 
void toggleLayer (uint index, bool iDisplay)
 
void setModified (uint index, bool iMod)
 
void resetModified (bool iMod=false)
 
void updateCausalStyleModules (uint index)
 
void displayDensityCurves (int x, int y)
 
ViewEdgeSelectViewEdge (real x, real y)
 
FEdgeSelectFEdge (real x, real y)
 
NodeGroupBuildRep (vector< ViewEdge * >::iterator vedges_begin, vector< ViewEdge * >::iterator vedges_end)
 
void toggleVisibilityAlgo ()
 
void setVisibilityAlgo (int algo)
 
int getVisibilityAlgo ()
 
void setViewMapCache (bool iBool)
 
bool getViewMapCache () const
 
void setQuantitativeInvisibility (bool iBool)
 
bool getQuantitativeInvisibility () const
 
void setFaceSmoothness (bool iBool)
 
bool getFaceSmoothness () const
 
void setComputeRidgesAndValleysFlag (bool b)
 
bool getComputeRidgesAndValleysFlag () const
 
void setComputeSuggestiveContoursFlag (bool b)
 
bool getComputeSuggestiveContoursFlag () const
 
void setComputeMaterialBoundariesFlag (bool b)
 
bool getComputeMaterialBoundariesFlag () const
 
void setComputeSteerableViewMapFlag (bool iBool)
 
bool getComputeSteerableViewMapFlag () const
 
void setCreaseAngle (float angle)
 
float getCreaseAngle () const
 
void setSphereRadius (float s)
 
float getSphereRadius () const
 
void setSuggestiveContourKrDerivativeEpsilon (float dkr)
 
float getSuggestiveContourKrDerivativeEpsilon () const
 
void setModelsDir (const string &dir)
 
string getModelsDir () const
 
void setModulesDir (const string &dir)
 
string getModulesDir () const
 
bool hitViewMapCache ()
 
void resetInterpreter ()
 

Public Attributes

ViewMap_ViewMap
 
AppCanvas_Canvas
 

Detailed Description

Definition at line 41 of file Controller.h.

Constructor & Destructor Documentation

◆ Controller()

◆ ~Controller()

Freestyle::Controller::~Controller ( )

Definition at line 122 of file Controller.cpp.

References _Canvas, _ViewMap, and Freestyle::NodeGroup::destroy().

Member Function Documentation

◆ AddStyleModule()

void Freestyle::Controller::AddStyleModule ( const char * iFileName)

Definition at line 947 of file Controller.cpp.

◆ BuildRep()

NodeGroup * Freestyle::Controller::BuildRep ( vector< ViewEdge * >::iterator vedges_begin,
vector< ViewEdge * >::iterator vedges_end )

◆ Clear()

void Freestyle::Controller::Clear ( )

Definition at line 957 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::Clear().

Referenced by FRS_end_stroke_rendering(), and FRS_init().

◆ ClearRootNode()

void Freestyle::Controller::ClearRootNode ( )

◆ CloseFile()

◆ ComputeSteerableViewMap()

◆ ComputeViewMap()

void Freestyle::Controller::ComputeViewMap ( )

Definition at line 456 of file Controller.cpp.

References _ViewMap, Freestyle::AppView::Add2DSilhouette(), Freestyle::AppView::Add2DVisibleSilhouette(), Freestyle::AppView::AddDebug(), Freestyle::BaseObject::addRef(), Freestyle::AppView::AddSilhouette(), Freestyle::ViewMapBuilder::BuildViewMap(), ComputeSteerableViewMap(), DeleteViewMap(), DeleteWingedEdge(), Freestyle::FEdgeXDetector::enableFaceSmoothness(), Freestyle::FEdgeXDetector::enableMaterialBoundaries(), Freestyle::FEdgeXDetector::enableOrthographicProjection(), Freestyle::FEdgeXDetector::enableRidgesAndValleysFlag(), Freestyle::FEdgeXDetector::enableSuggestiveContours(), G, G_DEBUG_FREESTYLE, g_freestyle, Freestyle::AppView::GetAspect(), Freestyle::AppView::GetFocalLength(), Freestyle::AppView::GetFovyRadian(), FreestyleGlobals::mv, printf, Freestyle::FEdgeXDetector::processShapes(), FreestyleGlobals::proj, resetModified(), Freestyle::FEdgeXDetector::setCreaseAngle(), Freestyle::ViewMapBuilder::setEnableQI(), Freestyle::ViewMapBuilder::setFrustum(), Freestyle::ViewMapBuilder::setGrid(), Freestyle::ViewMapTesselator::setNature(), Freestyle::FEdgeXDetector::setRenderMonitor(), Freestyle::ViewMapBuilder::setRenderMonitor(), Freestyle::ViewMap::setScene3dBBox(), Freestyle::FEdgeXDetector::setSphereRadius(), Freestyle::FEdgeXDetector::setSuggestiveContourKrDerivativeEpsilon(), Freestyle::ViewMapBuilder::setTransform(), Freestyle::FEdgeXDetector::setViewpoint(), Freestyle::ViewMapBuilder::setViewpoint(), Freestyle::Chronometer::start(), Freestyle::Chronometer::stop(), Freestyle::ViewMapTesselator::Tesselate(), Freestyle::RenderMonitor::testBreak(), UNPACK3, Freestyle::ViewMap::viewedges_size(), FreestyleGlobals::viewpoint, FreestyleGlobals::viewport, Freestyle::AppView::zfar(), and Freestyle::AppView::znear().

Referenced by prepare(), and toggleEdgeTesselationNature().

◆ DeleteViewMap()

void Freestyle::Controller::DeleteViewMap ( bool freeCache = false)

◆ DeleteWingedEdge()

void Freestyle::Controller::DeleteWingedEdge ( )

Definition at line 392 of file Controller.cpp.

References Freestyle::FastGrid::clear().

Referenced by CloseFile(), ComputeViewMap(), and LoadMesh().

◆ displayDensityCurves()

◆ DrawStrokes()

◆ getComputeMaterialBoundariesFlag()

bool Freestyle::Controller::getComputeMaterialBoundariesFlag ( ) const

Definition at line 850 of file Controller.cpp.

Referenced by prepare().

◆ getComputeRidgesAndValleysFlag()

bool Freestyle::Controller::getComputeRidgesAndValleysFlag ( ) const

Definition at line 830 of file Controller.cpp.

Referenced by prepare().

◆ getComputeSteerableViewMapFlag()

bool Freestyle::Controller::getComputeSteerableViewMapFlag ( ) const

Definition at line 860 of file Controller.cpp.

◆ getComputeSuggestiveContoursFlag()

bool Freestyle::Controller::getComputeSuggestiveContoursFlag ( ) const

Definition at line 840 of file Controller.cpp.

Referenced by prepare().

◆ getCreaseAngle()

float Freestyle::Controller::getCreaseAngle ( ) const
inline

Definition at line 130 of file Controller.h.

Referenced by prepare().

◆ getFaceSmoothness()

bool Freestyle::Controller::getFaceSmoothness ( ) const

Definition at line 820 of file Controller.cpp.

Referenced by prepare().

◆ getModelsDir()

string Freestyle::Controller::getModelsDir ( ) const

Definition at line 1023 of file Controller.cpp.

◆ getModulesDir()

string Freestyle::Controller::getModulesDir ( ) const

Definition at line 1035 of file Controller.cpp.

◆ getQuantitativeInvisibility()

bool Freestyle::Controller::getQuantitativeInvisibility ( ) const

Definition at line 810 of file Controller.cpp.

◆ getSphereRadius()

float Freestyle::Controller::getSphereRadius ( ) const
inline

Definition at line 138 of file Controller.h.

Referenced by prepare().

◆ getSuggestiveContourKrDerivativeEpsilon()

float Freestyle::Controller::getSuggestiveContourKrDerivativeEpsilon ( ) const
inline

Definition at line 146 of file Controller.h.

Referenced by prepare().

◆ getViewMapCache()

bool Freestyle::Controller::getViewMapCache ( ) const

Definition at line 800 of file Controller.cpp.

◆ getVisibilityAlgo()

◆ hitViewMapCache()

bool Freestyle::Controller::hitViewMapCache ( )

Definition at line 210 of file Controller.cpp.

References _ViewMap, Freestyle::SceneHash::match(), and Freestyle::SceneHash::store().

Referenced by LoadMesh(), and prepare().

◆ init_options()

◆ InsertStyleModule() [1/3]

void Freestyle::Controller::InsertStyleModule ( uint index,
const char * iFileName )

Definition at line 924 of file Controller.cpp.

References _Canvas, BLI_path_extension_check(), and Freestyle::Canvas::InsertStyleModule().

Referenced by prepare().

◆ InsertStyleModule() [2/3]

void Freestyle::Controller::InsertStyleModule ( uint index,
const char * iName,
const char * iBuffer )

Definition at line 935 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::InsertStyleModule().

◆ InsertStyleModule() [3/3]

void Freestyle::Controller::InsertStyleModule ( uint index,
const char * iName,
struct Text * iText )

Definition at line 941 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::InsertStyleModule().

◆ Load3DSFile()

int Freestyle::Controller::Load3DSFile ( const char * iFileName)

◆ LoadMesh()

◆ ReloadStyleModule()

void Freestyle::Controller::ReloadStyleModule ( uint index,
const char * iFileName )

Definition at line 962 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::ReplaceStyleModule().

◆ RemoveStyleModule()

void Freestyle::Controller::RemoveStyleModule ( uint index)

Definition at line 952 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::RemoveStyleModule().

◆ RenderStrokes()

◆ resetInterpreter()

void Freestyle::Controller::resetInterpreter ( )

Definition at line 1042 of file Controller.cpp.

References Freestyle::Interpreter::reset().

◆ resetModified()

void Freestyle::Controller::resetModified ( bool iMod = false)

Definition at line 995 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::resetModified().

Referenced by ComputeViewMap(), and DrawStrokes().

◆ ResetRenderCount()

void Freestyle::Controller::ResetRenderCount ( )

Definition at line 887 of file Controller.cpp.

Referenced by FRS_init_stroke_renderer().

◆ saveSteerableViewMapImages()

void Freestyle::Controller::saveSteerableViewMapImages ( )

◆ SelectFEdge()

FEdge * Freestyle::Controller::SelectFEdge ( real x,
real y )

◆ SelectViewEdge()

ViewEdge * Freestyle::Controller::SelectViewEdge ( real x,
real y )

◆ setComputeMaterialBoundariesFlag()

void Freestyle::Controller::setComputeMaterialBoundariesFlag ( bool b)

Definition at line 845 of file Controller.cpp.

References b.

Referenced by prepare().

◆ setComputeRidgesAndValleysFlag()

void Freestyle::Controller::setComputeRidgesAndValleysFlag ( bool b)

Definition at line 825 of file Controller.cpp.

References b.

Referenced by prepare().

◆ setComputeSteerableViewMapFlag()

void Freestyle::Controller::setComputeSteerableViewMapFlag ( bool iBool)

Definition at line 855 of file Controller.cpp.

Referenced by init_options().

◆ setComputeSuggestiveContoursFlag()

void Freestyle::Controller::setComputeSuggestiveContoursFlag ( bool b)

Definition at line 835 of file Controller.cpp.

References b.

Referenced by prepare().

◆ setContext()

void Freestyle::Controller::setContext ( bContext * C)

Definition at line 204 of file Controller.cpp.

References Freestyle::PythonInterpreter::setContext().

Referenced by FRS_set_context().

◆ setCreaseAngle()

void Freestyle::Controller::setCreaseAngle ( float angle)
inline

Definition at line 126 of file Controller.h.

References angle().

Referenced by prepare().

◆ setFaceSmoothness()

void Freestyle::Controller::setFaceSmoothness ( bool iBool)

Definition at line 815 of file Controller.cpp.

Referenced by prepare().

◆ setModelsDir()

void Freestyle::Controller::setModelsDir ( const string & dir)

Definition at line 1018 of file Controller.cpp.

◆ setModified()

void Freestyle::Controller::setModified ( uint index,
bool iMod )

◆ setModulesDir()

void Freestyle::Controller::setModulesDir ( const string & dir)

Definition at line 1030 of file Controller.cpp.

◆ setPassDiffuse()

void Freestyle::Controller::setPassDiffuse ( float * buf,
int width,
int height )

Definition at line 190 of file Controller.cpp.

References _Canvas, BLI_assert, and Freestyle::AppCanvas::setPassDiffuse().

Referenced by CloseFile(), init_options(), and prepare().

◆ setPassZ()

void Freestyle::Controller::setPassZ ( float * buf,
int width,
int height )

Definition at line 197 of file Controller.cpp.

References _Canvas, BLI_assert, and Freestyle::AppCanvas::setPassZ().

Referenced by CloseFile(), init_options(), and prepare().

◆ setQuantitativeInvisibility()

void Freestyle::Controller::setQuantitativeInvisibility ( bool iBool)

Definition at line 805 of file Controller.cpp.

Referenced by init_options().

◆ setRenderMonitor()

void Freestyle::Controller::setRenderMonitor ( RenderMonitor * iRenderMonitor)

Definition at line 185 of file Controller.cpp.

Referenced by FRS_do_stroke_rendering().

◆ setSphereRadius()

void Freestyle::Controller::setSphereRadius ( float s)
inline

Definition at line 134 of file Controller.h.

Referenced by prepare().

◆ setSuggestiveContourKrDerivativeEpsilon()

void Freestyle::Controller::setSuggestiveContourKrDerivativeEpsilon ( float dkr)
inline

Definition at line 142 of file Controller.h.

Referenced by prepare().

◆ setView()

void Freestyle::Controller::setView ( AppView * iView)

Definition at line 175 of file Controller.cpp.

References _Canvas, and Freestyle::AppCanvas::setViewer().

Referenced by FRS_init().

◆ setViewMapCache()

void Freestyle::Controller::setViewMapCache ( bool iBool)

Definition at line 795 of file Controller.cpp.

Referenced by FRS_do_stroke_rendering().

◆ setVisibilityAlgo()

◆ SwapStyleModules()

void Freestyle::Controller::SwapStyleModules ( uint i1,
uint i2 )

Definition at line 968 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::SwapStyleModules().

◆ toggleEdgeTesselationNature()

void Freestyle::Controller::toggleEdgeTesselationNature ( Nature::EdgeNature iNature)

Definition at line 1012 of file Controller.cpp.

References ComputeViewMap().

◆ toggleLayer()

void Freestyle::Controller::toggleLayer ( uint index,
bool iDisplay )

Definition at line 973 of file Controller.cpp.

References _Canvas, and Freestyle::Canvas::setVisible().

Referenced by prepare().

◆ toggleVisibilityAlgo()

void Freestyle::Controller::toggleVisibilityAlgo ( )

◆ updateCausalStyleModules()

void Freestyle::Controller::updateCausalStyleModules ( uint index)

Member Data Documentation

◆ _Canvas

◆ _ViewMap


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