SpiecsEngine
 
Loading...
Searching...
No Matches
Spices::CameraComponent Class Reference

CameraComponent Class. This class defines the specific behaves of CameraComponent. More...

#include <CameraComponent.h>

Inheritance diagram for Spices::CameraComponent:
Spices::Component

Public Member Functions

 CameraComponent (bool isActive=false)
 Constructor Function. Init class variable. Usually call it.
 
virtual ~CameraComponent () override=default
 Destructor Function.
 
virtual void OnSerialize () override
 This interface defines how to serialize.
 
virtual void OnDeSerialize () override
 This interface defines how to deserialize.
 
virtual void DrawThis () override
 This interface defines how to draw this component to property panel.
 
void SetCamera (std::shared_ptr< Camera > camera)
 Set the camera this component handled.
 
std::shared_ptr< CameraGetCamera ()
 Get the camera variable.
 
bool IsActive () const
 Query whether this camera is primary.
 
virtual void OnComponentAdded (const entt::entity &entity)
 This interface defines the behaves on specific component added. Init with variable.
 

Protected Attributes

entt::entity m_Owner { entt::null }
 This component's Owner entity.
 

Private Attributes

std::shared_ptr< Cameram_Camera
 The camera this component handled.
 
bool m_IsActive = false
 True if the camera is primary.
 

Detailed Description

CameraComponent Class. This class defines the specific behaves of CameraComponent.

Definition at line 18 of file CameraComponent.h.


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