aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/irrlicht-1.8/source/Irrlicht/ITriangleRenderer.h
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/irrlicht-1.8/source/Irrlicht/ITriangleRenderer.h')
-rw-r--r--libraries/irrlicht-1.8/source/Irrlicht/ITriangleRenderer.h68
1 files changed, 68 insertions, 0 deletions
diff --git a/libraries/irrlicht-1.8/source/Irrlicht/ITriangleRenderer.h b/libraries/irrlicht-1.8/source/Irrlicht/ITriangleRenderer.h
new file mode 100644
index 0000000..629a736
--- /dev/null
+++ b/libraries/irrlicht-1.8/source/Irrlicht/ITriangleRenderer.h
@@ -0,0 +1,68 @@
1// Copyright (C) 2002-2012 Nikolaus Gebhardt
2// This file is part of the "Irrlicht Engine".
3// For conditions of distribution and use, see copyright notice in irrlicht.h
4
5#ifndef __I_TRIANGLE_RENDERER_H_INCLUDED__
6#define __I_TRIANGLE_RENDERER_H_INCLUDED__
7
8#include "IReferenceCounted.h"
9#include "S2DVertex.h"
10#include "rect.h"
11#include "IZBuffer.h"
12
13namespace irr
14{
15namespace video
16{
17 class IImage;
18
19 enum ETriangleRenderer
20 {
21 ETR_FLAT = 0,
22 ETR_FLAT_WIRE,
23 ETR_GOURAUD,
24 ETR_GOURAUD_WIRE,
25 ETR_TEXTURE_FLAT,
26 ETR_TEXTURE_FLAT_WIRE,
27 ETR_TEXTURE_GOURAUD,
28 ETR_TEXTURE_GOURAUD_WIRE,
29 ETR_TEXTURE_GOURAUD_NOZ,
30 ETR_TEXTURE_GOURAUD_ADD,
31 ETR_COUNT
32 };
33
34 class ITriangleRenderer : public virtual IReferenceCounted
35 {
36 public:
37
38 //! sets a render target
39 virtual void setRenderTarget(video::IImage* surface, const core::rect<s32>& viewPort) = 0;
40
41 //! en or disables the backface culling
42 virtual void setBackfaceCulling(bool enabled = true) = 0;
43
44 //! sets the Texture
45 virtual void setTexture(video::IImage* texture) = 0;
46
47 //! draws an indexed triangle list
48 virtual void drawIndexedTriangleList(S2DVertex* vertices, s32 vertexCount, const u16* indexList, s32 triangleCount) = 0;
49 };
50
51
52 ITriangleRenderer* createTriangleRendererTextureGouraud(IZBuffer* zbuffer);
53 ITriangleRenderer* createTriangleRendererTextureGouraudWire(IZBuffer* zbuffer);
54 ITriangleRenderer* createTriangleRendererGouraud(IZBuffer* zbuffer);
55 ITriangleRenderer* createTriangleRendererGouraudWire(IZBuffer* zbuffer);
56 ITriangleRenderer* createTriangleRendererTextureFlat(IZBuffer* zbuffer);
57 ITriangleRenderer* createTriangleRendererTextureFlatWire(IZBuffer* zbuffer);
58 ITriangleRenderer* createTriangleRendererFlat(IZBuffer* zbuffer);
59 ITriangleRenderer* createTriangleRendererFlatWire(IZBuffer* zbuffer);
60 ITriangleRenderer* createTriangleRendererTextureGouraudNoZ();
61 ITriangleRenderer* createTriangleRendererTextureGouraudAdd(IZBuffer* zbuffer);
62
63
64} // end namespace video
65} // end namespace irr
66
67#endif
68