OpenBarnyard
 
Loading...
Searching...
No Matches
T2Viewport_GL.h
Go to the documentation of this file.
1#pragma once
2
4
5//-----------------------------------------------------------------------------
6// Note: This is a custom class.
7//-----------------------------------------------------------------------------
9{
10public:
11 constexpr T2Viewport(
12 TFLOAT a_fX,
13 TFLOAT a_fY,
14 TFLOAT a_fWidth,
15 TFLOAT a_fHeight,
16 TFLOAT a_fMinZ,
17 TFLOAT a_fMaxZ
18 )
19 : m_fX( a_fX )
20 , m_fY( a_fY )
21 , m_fWidth( a_fWidth )
22 , m_fHeight( a_fHeight )
23 , m_fMinZ( a_fMinZ )
24 , m_fMaxZ( a_fMaxZ )
25 {}
26
27 ~T2Viewport() = default;
28
29 TFLOAT GetX() const { return m_fX; }
30 TFLOAT GetY() const { return m_fY; }
31 TFLOAT GetWidth() const { return m_fWidth; }
32 TFLOAT GetHeight() const { return m_fHeight; }
33 TFLOAT GetMinZ() const { return m_fMinZ; }
34 TFLOAT GetMaxZ() const { return m_fMaxZ; }
35
36 void SetX( TFLOAT a_fValue ) { m_fX = a_fValue; }
37 void SetY( TFLOAT a_fValue ) { m_fY = a_fValue; }
38 void SetWidth( TFLOAT a_fValue ) { m_fWidth = a_fValue; }
39 void SetHeight( TFLOAT a_fValue ) { m_fHeight = a_fValue; }
40 void SetMinZ( TFLOAT a_fValue ) { m_fMinZ = a_fValue; }
41 void SetMaxZ( TFLOAT a_fValue ) { m_fMaxZ = a_fValue; }
42
43private:
44 TFLOAT m_fX;
45 TFLOAT m_fY;
46 TFLOAT m_fWidth;
47 TFLOAT m_fHeight;
48 TFLOAT m_fMinZ;
49 TFLOAT m_fMaxZ;
50};
51
#define TOSHI_NAMESPACE_START
Definition Defines.h:47
#define TOSHI_NAMESPACE_END
Definition Defines.h:50
float TFLOAT
Definition Typedefs.h:4
~T2Viewport()=default
void SetWidth(TFLOAT a_fValue)
void SetMinZ(TFLOAT a_fValue)
TFLOAT GetX() const
void SetHeight(TFLOAT a_fValue)
TFLOAT GetMinZ() const
TFLOAT GetWidth() const
TFLOAT GetY() const
constexpr T2Viewport(TFLOAT a_fX, TFLOAT a_fY, TFLOAT a_fWidth, TFLOAT a_fHeight, TFLOAT a_fMinZ, TFLOAT a_fMaxZ)
void SetY(TFLOAT a_fValue)
TFLOAT GetHeight() const
TFLOAT GetMaxZ() const
void SetX(TFLOAT a_fValue)
void SetMaxZ(TFLOAT a_fValue)