Nebula
Toggle main menu visibility
Loading...
Searching...
No Matches
textelement.h
Go to the documentation of this file.
1
#pragma once
2
//------------------------------------------------------------------------------
12
#include "
util/string.h
"
13
#include "
math/vec4.h
"
14
#include "
math/vec2.h
"
15
#include "
threading/threadid.h
"
16
17
//------------------------------------------------------------------------------
18
namespace
CoreGraphics
19
{
20
class
TextElement
21
{
22
public
:
24
TextElement
();
26
TextElement
(
Threading::ThreadId
threadId
,
const
Util::String
&
text
,
const
Math::vec4
&
color
,
const
Math::vec2
&
pos
,
const
float
size
);
27
29
Threading::ThreadId
GetThreadId
()
const
;
31
const
Util::String
&
GetText
()
const
;
33
const
Math::vec4
&
GetColor
()
const
;
35
const
Math::vec2
&
GetPosition
()
const
;
37
const
float
GetSize
()
const
;
38
39
private
:
40
Threading::ThreadId
threadId
;
41
Util::String
text
;
42
Math::vec4
color
;
43
Math::vec2
pos
;
44
float
size
;
45
};
46
47
//------------------------------------------------------------------------------
50
inline
Threading::ThreadId
51
TextElement::GetThreadId
()
const
52
{
53
return
this->
threadId
;
54
}
55
56
//------------------------------------------------------------------------------
59
inline
const
Util::String
&
60
TextElement::GetText
()
const
61
{
62
return
this->
text
;
63
}
64
65
//------------------------------------------------------------------------------
68
inline
const
Math::vec4
&
69
TextElement::GetColor
()
const
70
{
71
return
this->
color
;
72
}
73
74
//------------------------------------------------------------------------------
77
inline
const
Math::vec2
&
78
TextElement::GetPosition
()
const
79
{
80
return
this->
pos
;
81
}
82
83
84
//------------------------------------------------------------------------------
87
inline
const
float
88
TextElement::GetSize
()
const
89
{
90
return
this->
size
;
91
}
92
93
}
// namespace CoreGraphics
94
//------------------------------------------------------------------------------
95
96
97
CoreGraphics::TextElement::TextElement
TextElement()
default constructor
Definition
textelement.cc:18
CoreGraphics::TextElement::threadId
Threading::ThreadId threadId
Definition
textelement.h:40
CoreGraphics::TextElement::GetSize
const float GetSize() const
get size
Definition
textelement.h:88
CoreGraphics::TextElement::GetColor
const Math::vec4 & GetColor() const
get color
Definition
textelement.h:69
CoreGraphics::TextElement::GetText
const Util::String & GetText() const
get text
Definition
textelement.h:60
CoreGraphics::TextElement::GetPosition
const Math::vec2 & GetPosition() const
get position
Definition
textelement.h:78
CoreGraphics::TextElement::pos
Math::vec2 pos
Definition
textelement.h:43
CoreGraphics::TextElement::GetThreadId
Threading::ThreadId GetThreadId() const
get thread id
Definition
textelement.h:51
CoreGraphics::TextElement::size
float size
Definition
textelement.h:44
CoreGraphics::TextElement::color
Math::vec4 color
Definition
textelement.h:42
CoreGraphics::TextElement::text
Util::String text
Definition
textelement.h:41
CoreGraphics
Acceleration structures are used to enable ray tracing on the GPU by dividing the scene into a BVH.
Definition
accelerationstructure.h:24
Threading::ThreadId
pthread_t ThreadId
Definition
linuxthreadid.h:15
string.h
Math::vec2
A 2-component float vector class.
Definition
vec2.h:21
Math::vec4
A 4D vector.
Definition
vec4.h:24
Util.String
Nebula's universal string class.
Definition
String.cs:8
threadid.h
vec2.h
vec4.h
code
render
coregraphics
textelement.h
Generated on
for Nebula. Dark theme by
Tilen Majerle
. All rights reserved.