Cumulia Illustrator Rendering Engine v1.0.0
A Rendering engine for industrial CAD/CAE model and optimized for greatest performance
 
Loading...
Searching...
No Matches
cil::LocatorPass Class Reference

The LocatorPass class inheriting from EventWatcher class and Pass class, representing a rendering pass specifically for Locator objects. More...

#include <locatorpass.h>

Inheritance diagram for cil::LocatorPass:
cil::EventWatcher cil::Pass cil::Object

Public Member Functions

 LocatorPass (const std::shared_ptr< Background > &background, const std::shared_ptr< Camera > &camera)
 
virtual ~LocatorPass ()
 
void add (const std::shared_ptr< AbstractLocator > &locator) const
 Adds a locator to this rendering pass.
 
void remove (const std::shared_ptr< AbstractLocator > &locator) const
 Removes a locator from this rendering pass.
 
void clear () const
 
bool begin (const Ray &r, Modifier modifier=Modifier::None)
 Initiates the update process if there exists highlighted handler in this locator pass.
 
bool update (const Ray &r)
 Synchronizes the locator pass's active locator and highlighted handler with the cursor position.
 
bool end (const Ray &r)
 Ends the update process.
 
- Public Member Functions inherited from cil::EventWatcher
 EventWatcher ()
 
virtual ~EventWatcher ()
 
void bind (const std::string &name, EventCallback callback)
 Binds a callback function to a specific event name.
 
void send (const std::string &name)
 Triggers an event by its name.
 
- Public Member Functions inherited from cil::Pass
 Pass ()
 
void update (UpdateMode mode=UpdateMode::All)
 
void updateAsset ()
 
void updateBatch ()
 
void updateTrans ()
 
- Public Member Functions inherited from cil::Object
 Object ()
 
virtual ~Object ()
 

Additional Inherited Members

- Public Types inherited from cil::Pass
enum class  UpdateMode {
  None = 0 , Asset = 1 , Batch = 2 , Trans = 4 ,
  All = Asset | Batch | Trans
}
 
- Public Attributes inherited from cil::Pass
std::string name
 This memeber stores the name of the pass.
 
bool enabled
 This member indicates whether the pass is currently enabled. Disabled passes are skipped during rendering.
 
std::shared_ptr< Backgroundbackground
 This member holds a shared pointer to a Background object which defines the scene background.
 
std::shared_ptr< Cameracamera
 This member holds a shared pointer to a Camera object which the current pass uses for rendering.
 
std::shared_ptr< Nodenode
 This member holds a shared pointer to a Node object which represents the rendering objects of the current pass.
 
std::shared_ptr< Targettarget
 This member holds a shared pointer to a Target object which stores the rendering results, such as a buffer or texture.
 
int assetVersion
 
int batchVersion
 
int transVersion
 

Detailed Description

The LocatorPass class inheriting from EventWatcher class and Pass class, representing a rendering pass specifically for Locator objects.

Constructor & Destructor Documentation

◆ LocatorPass()

cil::LocatorPass::LocatorPass ( const std::shared_ptr< Background > & background,
const std::shared_ptr< Camera > & camera )

◆ ~LocatorPass()

virtual cil::LocatorPass::~LocatorPass ( )
virtual

Member Function Documentation

◆ add()

void cil::LocatorPass::add ( const std::shared_ptr< AbstractLocator > & locator) const

Adds a locator to this rendering pass.

◆ begin()

bool cil::LocatorPass::begin ( const Ray & r,
Modifier modifier = Modifier::None )

Initiates the update process if there exists highlighted handler in this locator pass.

Parameters
rA Ray object that originates from the cursor position on the 2D screen and extends into 3D space.
Returns
Returns a boolean indicating whether the active locator exists.

◆ clear()

void cil::LocatorPass::clear ( ) const

◆ end()

bool cil::LocatorPass::end ( const Ray & r)

Ends the update process.

◆ remove()

void cil::LocatorPass::remove ( const std::shared_ptr< AbstractLocator > & locator) const

Removes a locator from this rendering pass.

◆ update()

bool cil::LocatorPass::update ( const Ray & r)

Synchronizes the locator pass's active locator and highlighted handler with the cursor position.