xoreos
0.0.5
src
graphics
aurora
borderquad.h
Go to the documentation of this file.
1
/* xoreos - A reimplementation of BioWare's Aurora engine
2
*
3
* xoreos is the legal property of its developers, whose names
4
* can be found in the AUTHORS file distributed with this source
5
* distribution.
6
*
7
* xoreos is free software; you can redistribute it and/or
8
* modify it under the terms of the GNU General Public License
9
* as published by the Free Software Foundation; either version 3
10
* of the License, or (at your option) any later version.
11
*
12
* xoreos is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with xoreos. If not, see <http://www.gnu.org/licenses/>.
19
*/
20
26
#ifndef GRAPHICS_AURORA_BORDERQUAD_H
27
#define GRAPHICS_AURORA_BORDERQUAD_H
28
29
#include "
src/graphics/renderable.h
"
30
31
#include "
src/graphics/aurora/texture.h
"
32
#include "
src/graphics/aurora/texturehandle.h
"
33
34
namespace
Graphics
{
35
36
namespace
Aurora
{
37
38
class
BorderQuad
:
public
Renderable
{
39
public
:
40
BorderQuad
(
const
Common::UString
&edge,
const
Common::UString
&corner,
float
x,
float
y,
float
w,
float
h,
41
int
dimension = 0);
42
44
void
setColor
(
float
r,
float
g,
float
b,
float
a = 1.0f);
45
46
void
setPosition
(
float
x,
float
y,
float
z);
47
void
getPosition
(
float
&x,
float
&y,
float
&z);
48
void
setSize
(
float
w,
float
h);
49
void
getSize
(
float
&w,
float
&h)
const
;
50
51
virtual
void
calculateDistance
();
52
53
void
render
(
RenderPass
pass
);
54
55
private
:
56
TextureHandle
_edge
,
_corner
;
57
58
bool
_verticalCut
;
59
60
int
_edgeWidth
,
_edgeHeight
;
61
int
_cornerWidth
,
_cornerHeight
;
62
63
float
_r
;
64
float
_g
;
65
float
_b
;
66
float
_a
;
67
68
float
_x
;
69
float
_y
;
70
float
_w
;
71
float
_h
;
72
};
73
74
}
// End of namespace Aurora
75
76
}
// End of namespace Engines
77
78
#endif // GRAPHICS_AURORA_BORDERQUAD_H
Graphics::Aurora::BorderQuad::_edgeHeight
int _edgeHeight
Definition:
borderquad.h:60
Graphics::Aurora::BorderQuad::_edgeWidth
int _edgeWidth
Definition:
borderquad.h:60
Common::UString
A class holding an UTF-8 string.
Definition:
ustring.h:48
Graphics::Aurora::BorderQuad::_y
float _y
Definition:
borderquad.h:69
Graphics::Aurora::BorderQuad::_h
float _h
Definition:
borderquad.h:71
Graphics::Aurora::BorderQuad::BorderQuad
BorderQuad(const Common::UString &edge, const Common::UString &corner, float x, float y, float w, float h, int dimension=0)
Definition:
borderquad.cpp:35
texturehandle.h
A handle to an Aurora texture.
Graphics::Aurora::BorderQuad::calculateDistance
virtual void calculateDistance()
Calculate the object's distance.
Definition:
borderquad.cpp:112
Graphics::Aurora::BorderQuad::_edge
TextureHandle _edge
Definition:
borderquad.h:56
Graphics::RenderPass
RenderPass
Definition:
types.h:97
Aurora
Definition:
2dafile.cpp:51
Graphics::Aurora::BorderQuad::setPosition
void setPosition(float x, float y, float z)
Definition:
borderquad.cpp:79
Graphics::Aurora::BorderQuad::_x
float _x
Definition:
borderquad.h:68
Graphics::Aurora::BorderQuad::_r
float _r
Definition:
borderquad.h:63
Graphics::Aurora::BorderQuad::render
void render(RenderPass pass)
Render the object.
Definition:
borderquad.cpp:115
Graphics::Aurora::BorderQuad::_corner
TextureHandle _corner
Definition:
borderquad.h:56
Graphics::Aurora::BorderQuad::_cornerHeight
int _cornerHeight
Definition:
borderquad.h:61
Graphics::Renderable
An object that can be displayed by the graphics manager.
Definition:
renderable.h:42
Graphics::Aurora::BorderQuad::setColor
void setColor(float r, float g, float b, float a=1.0f)
Set the color of the border quad.
Definition:
borderquad.cpp:72
Graphics::Aurora::BorderQuad::_cornerWidth
int _cornerWidth
Definition:
borderquad.h:61
Graphics::Aurora::BorderQuad::_g
float _g
Definition:
borderquad.h:64
Graphics::Aurora::BorderQuad::_a
float _a
Definition:
borderquad.h:66
texture.h
A texture as used in the Aurora engines.
Graphics::Aurora::BorderQuad::getPosition
void getPosition(float &x, float &y, float &z)
Definition:
borderquad.cpp:90
Graphics::Aurora::BorderQuad::_b
float _b
Definition:
borderquad.h:65
pass
#define pass
Definition:
fft.cpp:257
Graphics
Definition:
loadprogress.h:33
Graphics::Aurora::BorderQuad
Definition:
borderquad.h:38
Graphics::Aurora::BorderQuad::_w
float _w
Definition:
borderquad.h:70
Graphics::Aurora::TextureHandle
A handle to a texture.
Definition:
texturehandle.h:51
renderable.h
An object that can be displayed by the graphics manager.
Graphics::Aurora::BorderQuad::_verticalCut
bool _verticalCut
Definition:
borderquad.h:58
Graphics::Aurora::BorderQuad::getSize
void getSize(float &w, float &h) const
Definition:
borderquad.cpp:107
Graphics::Aurora::BorderQuad::setSize
void setSize(float w, float h)
Definition:
borderquad.cpp:96
Generated on Sun Nov 18 2018 15:13:41 for xoreos by
1.8.14