aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/irrlicht-1.8/include/SIrrCreationParameters.h
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/irrlicht-1.8/include/SIrrCreationParameters.h')
-rw-r--r--libraries/irrlicht-1.8/include/SIrrCreationParameters.h301
1 files changed, 0 insertions, 301 deletions
diff --git a/libraries/irrlicht-1.8/include/SIrrCreationParameters.h b/libraries/irrlicht-1.8/include/SIrrCreationParameters.h
deleted file mode 100644
index 63395d7..0000000
--- a/libraries/irrlicht-1.8/include/SIrrCreationParameters.h
+++ /dev/null
@@ -1,301 +0,0 @@
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_IRRLICHT_CREATION_PARAMETERS_H_INCLUDED__
6#define __I_IRRLICHT_CREATION_PARAMETERS_H_INCLUDED__
7
8#include "EDriverTypes.h"
9#include "EDeviceTypes.h"
10#include "dimension2d.h"
11#include "ILogger.h"
12#include "SExposedVideoData.h"
13
14namespace irr
15{
16 class IEventReceiver;
17
18 //! Structure for holding Irrlicht Device creation parameters.
19 /** This structure is used in the createDeviceEx() function. */
20 struct SIrrlichtCreationParameters
21 {
22 //! Constructs a SIrrlichtCreationParameters structure with default values.
23 SIrrlichtCreationParameters() :
24 DeviceType(EIDT_BEST),
25 DriverType(video::EDT_BURNINGSVIDEO),
26 WindowSize(core::dimension2d<u32>(800, 600)),
27 Bits(16),
28 ZBufferBits(16),
29 Fullscreen(false),
30 Stencilbuffer(false),
31 Vsync(false),
32 AntiAlias(0),
33 HandleSRGB(false),
34 WithAlphaChannel(false),
35 Doublebuffer(true),
36 IgnoreInput(false),
37 Stereobuffer(false),
38 HighPrecisionFPU(false),
39 EventReceiver(0),
40 WindowId(0),
41 VideoData(0),
42#ifdef _DEBUG
43 LoggingLevel(ELL_DEBUG),
44#else
45 LoggingLevel(ELL_INFORMATION),
46#endif
47 DisplayAdapter(0),
48 DriverMultithreaded(false),
49 UsePerformanceTimer(true),
50 SDK_version_do_not_use(IRRLICHT_SDK_VERSION)
51 {
52 }
53
54 SIrrlichtCreationParameters(const SIrrlichtCreationParameters& other) :
55 SDK_version_do_not_use(IRRLICHT_SDK_VERSION)
56 {*this = other;}
57
58 SIrrlichtCreationParameters& operator=(const SIrrlichtCreationParameters& other)
59 {
60 DeviceType = other.DeviceType;
61 DriverType = other.DriverType;
62 WindowSize = other.WindowSize;
63 Bits = other.Bits;
64 ZBufferBits = other.ZBufferBits;
65 Fullscreen = other.Fullscreen;
66 Stencilbuffer = other.Stencilbuffer;
67 Vsync = other.Vsync;
68 AntiAlias = other.AntiAlias;
69 HandleSRGB = other.HandleSRGB;
70 WithAlphaChannel = other.WithAlphaChannel;
71 Doublebuffer = other.Doublebuffer;
72 IgnoreInput = other.IgnoreInput;
73 Stereobuffer = other.Stereobuffer;
74 HighPrecisionFPU = other.HighPrecisionFPU;
75 EventReceiver = other.EventReceiver;
76 WindowId = other.WindowId;
77 VideoData = other.VideoData;
78 LoggingLevel = other.LoggingLevel;
79 DriverMultithreaded = other.DriverMultithreaded;
80 DisplayAdapter = other.DisplayAdapter;
81 UsePerformanceTimer = other.UsePerformanceTimer;
82 return *this;
83 }
84
85 //! Type of the device.
86 /** This setting decides the windowing system used by the device, most device types are native
87 to a specific operating system and so may not be available.
88 EIDT_WIN32 is only available on Windows desktops,
89 EIDT_WINCE is only available on Windows mobile devices,
90 EIDT_COCOA is only available on Mac OSX,
91 EIDT_X11 is available on Linux, Solaris, BSD and other operating systems which use X11,
92 EIDT_SDL is available on most systems if compiled in,
93 EIDT_CONSOLE is usually available but can only render to text,
94 EIDT_BEST will select the best available device for your operating system.
95 Default: EIDT_BEST. */
96 E_DEVICE_TYPE DeviceType;
97
98 //! Type of video driver used to render graphics.
99 /** This can currently be video::EDT_NULL, video::EDT_SOFTWARE,
100 video::EDT_BURNINGSVIDEO, video::EDT_DIRECT3D8,
101 video::EDT_DIRECT3D9, and video::EDT_OPENGL.
102 Default: Software. */
103 video::E_DRIVER_TYPE DriverType;
104
105 //! Size of the window or the video mode in fullscreen mode. Default: 800x600
106 core::dimension2d<u32> WindowSize;
107
108 //! Minimum Bits per pixel of the color buffer in fullscreen mode. Ignored if windowed mode. Default: 16.
109 u8 Bits;
110
111 //! Minimum Bits per pixel of the depth buffer. Default: 16.
112 u8 ZBufferBits;
113
114 //! Should be set to true if the device should run in fullscreen.
115 /** Otherwise the device runs in windowed mode. Default: false. */
116 bool Fullscreen;
117
118 //! Specifies if the stencil buffer should be enabled.
119 /** Set this to true, if you want the engine be able to draw
120 stencil buffer shadows. Note that not all drivers are able to
121 use the stencil buffer, hence it can be ignored during device
122 creation. Without the stencil buffer no shadows will be drawn.
123 Default: false. */
124 bool Stencilbuffer;
125
126 //! Specifies vertical syncronisation.
127 /** If set to true, the driver will wait for the vertical
128 retrace period, otherwise not. May be silently ignored.
129 Default: false */
130 bool Vsync;
131
132 //! Specifies if the device should use fullscreen anti aliasing
133 /** Makes sharp/pixelated edges softer, but requires more
134 performance. Also, 2D elements might look blurred with this
135 switched on. The resulting rendering quality also depends on
136 the hardware and driver you are using, your program might look
137 different on different hardware with this. So if you are
138 writing a game/application with AntiAlias switched on, it would
139 be a good idea to make it possible to switch this option off
140 again by the user.
141 The value is the maximal antialiasing factor requested for
142 the device. The cretion method will automatically try smaller
143 values if no window can be created with the given value.
144 Value one is usually the same as 0 (disabled), but might be a
145 special value on some platforms. On D3D devices it maps to
146 NONMASKABLE.
147 Default value: 0 - disabled */
148 u8 AntiAlias;
149
150 //! Flag to enable proper sRGB and linear color handling
151 /** In most situations, it is desireable to have the color handling in
152 non-linear sRGB color space, and only do the intermediate color
153 calculations in linear RGB space. If this flag is enabled, the device and
154 driver try to assure that all color input and output are color corrected
155 and only the internal color representation is linear. This means, that
156 the color output is properly gamma-adjusted to provide the brighter
157 colors for monitor display. And that blending and lighting give a more
158 natural look, due to proper conversion from non-linear colors into linear
159 color space for blend operations. If this flag is enabled, all texture colors
160 (which are usually in sRGB space) are correctly displayed. However vertex colors
161 and other explicitly set values have to be manually encoded in linear color space.
162 Default value: false. */
163 bool HandleSRGB;
164
165 //! Whether the main framebuffer uses an alpha channel.
166 /** In some situations it might be desireable to get a color
167 buffer with an alpha channel, e.g. when rendering into a
168 transparent window or overlay. If this flag is set the device
169 tries to create a framebuffer with alpha channel.
170 If this flag is set, only color buffers with alpha channel
171 are considered. Otherwise, it depends on the actual hardware
172 if the colorbuffer has an alpha channel or not.
173 Default value: false */
174 bool WithAlphaChannel;
175
176 //! Whether the main framebuffer uses doublebuffering.
177 /** This should be usually enabled, in order to avoid render
178 artifacts on the visible framebuffer. However, it might be
179 useful to use only one buffer on very small devices. If no
180 doublebuffering is available, the drivers will fall back to
181 single buffers. Default value: true */
182 bool Doublebuffer;
183
184 //! Specifies if the device should ignore input events
185 /** This is only relevant when using external I/O handlers.
186 External windows need to take care of this themselves.
187 Currently only supported by X11.
188 Default value: false */
189 bool IgnoreInput;
190
191 //! Specifies if the device should use stereo buffers
192 /** Some high-end gfx cards support two framebuffers for direct
193 support of stereoscopic output devices. If this flag is set the
194 device tries to create a stereo context.
195 Currently only supported by OpenGL.
196 Default value: false */
197 bool Stereobuffer;
198
199 //! Specifies if the device should use high precision FPU setting
200 /** This is only relevant for DirectX Devices, which switch to
201 low FPU precision by default for performance reasons. However,
202 this may lead to problems with the other computations of the
203 application. In this case setting this flag to true should help
204 - on the expense of performance loss, though.
205 Default value: false */
206 bool HighPrecisionFPU;
207
208 //! A user created event receiver.
209 IEventReceiver* EventReceiver;
210
211 //! Window Id.
212 /** If this is set to a value other than 0, the Irrlicht Engine
213 will be created in an already existing window. For windows, set
214 this to the HWND of the window you want. The windowSize and
215 FullScreen options will be ignored when using the WindowId
216 parameter. Default this is set to 0.
217 To make Irrlicht run inside the custom window, you still will
218 have to draw Irrlicht on your own. You can use this loop, as
219 usual:
220 \code
221 while (device->run())
222 {
223 driver->beginScene(true, true, 0);
224 smgr->drawAll();
225 driver->endScene();
226 }
227 \endcode
228 Instead of this, you can also simply use your own message loop
229 using GetMessage, DispatchMessage and whatever. Calling
230 IrrlichtDevice::run() will cause Irrlicht to dispatch messages
231 internally too. You need not call Device->run() if you want to
232 do your own message dispatching loop, but Irrlicht will not be
233 able to fetch user input then and you have to do it on your own
234 using the window messages, DirectInput, or whatever. Also,
235 you'll have to increment the Irrlicht timer.
236 An alternative, own message dispatching loop without
237 device->run() would look like this:
238 \code
239 MSG msg;
240 while (true)
241 {
242 if (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE))
243 {
244 TranslateMessage(&msg);
245 DispatchMessage(&msg);
246
247 if (msg.message == WM_QUIT)
248 break;
249 }
250
251 // increase virtual timer time
252 device->getTimer()->tick();
253
254 // draw engine picture
255 driver->beginScene(true, true, 0);
256 smgr->drawAll();
257 driver->endScene();
258 }
259 \endcode
260 However, there is no need to draw the picture this often. Just
261 do it how you like. */
262 void* WindowId;
263
264 video::SExposedVideoData *VideoData;
265
266 //! Specifies the logging level used in the logging interface.
267 /** The default value is ELL_INFORMATION. You can access the ILogger interface
268 later on from the IrrlichtDevice with getLogger() and set another level.
269 But if you need more or less logging information already from device creation,
270 then you have to change it here.
271 */
272 ELOG_LEVEL LoggingLevel;
273
274 //! Allows to select which graphic card is used for rendering when more than one card is in the system.
275 /** So far only supported on D3D */
276 u32 DisplayAdapter;
277
278 //! Create the driver multithreaded.
279 /** Default is false. Enabling this can slow down your application.
280 Note that this does _not_ make Irrlicht threadsafe, but only the underlying driver-API for the graphiccard.
281 So far only supported on D3D. */
282 bool DriverMultithreaded;
283
284 //! Enables use of high performance timers on Windows platform.
285 /** When performance timers are not used, standard GetTickCount()
286 is used instead which usually has worse resolution, but also less
287 problems with speed stepping and other techniques.
288 */
289 bool UsePerformanceTimer;
290
291 //! Don't use or change this parameter.
292 /** Always set it to IRRLICHT_SDK_VERSION, which is done by default.
293 This is needed for sdk version checks. */
294 const c8* const SDK_version_do_not_use;
295 };
296
297
298} // end namespace irr
299
300#endif
301