Skylicht Engine
Loading...
Searching...
No Matches
CCylinder.h
1#pragma once
2
3#include "Material/CMaterial.h"
4#include "CLathe.h"
5
6namespace Skylicht
7{
22 class COMPONENT_API CCylinder : public CLathe
23 {
24 protected:
25 float m_radius;
26 float m_height;
27
28 public:
29 CCylinder();
30
31 virtual ~CCylinder();
32
33 virtual void initComponent();
34
35 virtual void updateComponent();
36
37 void init();
38
43 inline void setRadius(float r)
44 {
45 m_radius = r;
46 }
47
52 inline void setHeight(float h)
53 {
54 m_height = h;
55 }
56
61 inline float getRadius()
62 {
63 return m_radius;
64 }
65
70 inline float getHeight()
71 {
72 return m_height;
73 }
74
75 virtual CObjectSerializable* createSerializable();
76
77 virtual void loadSerializable(CObjectSerializable* object);
78
79 DECLARE_GETTYPENAME(CCylinder)
80 };
81}
Component for rendering cylinder primitives.
Definition CCylinder.h:23
void setHeight(float h)
Set the cylinder height.
Definition CCylinder.h:52
float getRadius()
Get the cylinder radius.
Definition CCylinder.h:61
void setRadius(float r)
Set the cylinder radius.
Definition CCylinder.h:43
float getHeight()
Get the cylinder height.
Definition CCylinder.h:70
void init()
Re-initialize the lathe mesh based on current parameters.
Definition CObjectSerializable.h:36
Everything in the Skylicht Engine. You can start by looking at the topics.
Definition AudioDebugLog.h:29