]> git.lizzy.rs Git - irrlicht.git/blobdiff - include/IrrlichtDevice.h
Restore isDriverSupported, but in a cpp file
[irrlicht.git] / include / IrrlichtDevice.h
index ac02342b40b617705712be6d793350c083bcf42b..c6a19787859ee69ad3342effaba9348c5f0d751f 100644 (file)
 #include "EDeviceTypes.h"\r
 #include "IEventReceiver.h"\r
 #include "ICursorControl.h"\r
-#include "IVideoModeList.h"\r
 #include "ITimer.h"\r
 #include "IOSOperator.h"\r
+#include "IrrCompileConfig.h"\r
 \r
 namespace irr\r
 {\r
        class ILogger;\r
        class IEventReceiver;\r
-       class IRandomizer;\r
 \r
        namespace io {\r
                class IFileSystem;\r
@@ -36,6 +35,7 @@ namespace irr
 \r
        namespace video {\r
                class IContextManager;\r
+               extern "C" IRRLICHT_API bool IRRCALLCONV isDriverSupported(E_DRIVER_TYPE driver);\r
        } // end namespace video\r
 \r
        //! The Irrlicht device. You can create it with createDevice() or createDeviceEx().\r
@@ -111,14 +111,6 @@ namespace irr
                /** \return Pointer to the logger. */\r
                virtual ILogger* getLogger() = 0;\r
 \r
-               //! Gets a list with all video modes available.\r
-               /** You only need a null driver (ED_NULL) to access\r
-               those video modes. So you can get the available modes\r
-               before starting any other video driver.\r
-               \return Pointer to a list with all video modes supported\r
-               by the gfx adapter. */\r
-               virtual video::IVideoModeList* getVideoModeList() = 0;\r
-\r
                //! Get context manager\r
                virtual video::IContextManager* getContextManager() = 0;\r
 \r
@@ -136,22 +128,6 @@ namespace irr
                \return Pointer to the ITimer object. */\r
                virtual ITimer* getTimer() = 0;\r
 \r
-               //! Provides access to the engine's currently set randomizer.\r
-               /** \return Pointer to the IRandomizer object. */\r
-               virtual IRandomizer* getRandomizer() const =0;\r
-\r
-               //! Sets a new randomizer.\r
-               /** \param r Pointer to the new IRandomizer object. This object is\r
-               grab()'ed by the engine and will be released upon the next setRandomizer\r
-               call or upon device destruction. */\r
-               virtual void setRandomizer(IRandomizer* r) =0;\r
-\r
-               //! Creates a new default randomizer.\r
-               /** The default randomizer provides the random sequence known from previous\r
-               Irrlicht versions and is the initial randomizer set on device creation.\r
-               \return Pointer to the default IRandomizer object. */\r
-               virtual IRandomizer* createDefaultRandomizer() const =0;\r
-\r
                //! Sets the caption of the window.\r
                /** \param text: New text of the window caption. */\r
                virtual void setWindowCaption(const wchar_t* text) = 0;\r
@@ -182,6 +158,12 @@ namespace irr
                /** \return True if window is minimized. */\r
                virtual bool isWindowMinimized() const = 0;\r
 \r
+               //! Checks if the Irrlicht window is maximized\r
+               //! Only fully works on SDL. Returns false, or the last value set via\r
+               //! maximizeWindow() and restoreWindow(), on other backends.\r
+               /** \return True if window is maximized. */\r
+               virtual bool isWindowMaximized() const = 0;\r
+\r
                //! Checks if the Irrlicht window is running in fullscreen mode\r
                /** \return True if window is fullscreen. */\r
                virtual bool isFullscreen() const = 0;\r
@@ -255,8 +237,8 @@ namespace irr
                as this would consume joystick info that 3rd party libraries might rely on. Call this method to\r
                activate joystick support in Irrlicht and to receive irr::SJoystickEvent events.\r
                \param joystickInfo On return, this will contain an array of each joystick that was found and activated.\r
-               \return true if joysticks are supported on this device and _IRR_COMPILE_WITH_JOYSTICK_EVENTS_\r
-                               is defined, false if joysticks are not supported or support is compiled out.\r
+               \return true if joysticks are supported on this device, false if joysticks are not\r
+                            supported or support is compiled out.\r
                */\r
                virtual bool activateJoysticks(core::array<SJoystickInfo>& joystickInfo) =0;\r
 \r
@@ -296,14 +278,6 @@ namespace irr
         //! Is device motion available.\r
         virtual bool isDeviceMotionAvailable() = 0;\r
 \r
-               //! Set the current Gamma Value for the Display\r
-               virtual bool setGammaRamp(f32 red, f32 green, f32 blue,\r
-                                       f32 relativebrightness, f32 relativecontrast) =0;\r
-\r
-               //! Get the current Gamma Value for the Display\r
-               virtual bool getGammaRamp(f32 &red, f32 &green, f32 &blue,\r
-                                       f32 &brightness, f32 &contrast) =0;\r
-\r
                //! Set the maximal elapsed time between 2 clicks to generate doubleclicks for the mouse. It also affects tripleclick behavior.\r
                /** When set to 0 no double- and tripleclicks will be generated.\r
                \param timeMs maximal time in milliseconds for two consecutive clicks to be recognized as double click\r
@@ -338,55 +312,7 @@ namespace irr
                for a configuration requested when creating the device. */\r
                static bool isDriverSupported(video::E_DRIVER_TYPE driver)\r
                {\r
-                       switch (driver)\r
-                       {\r
-                               case video::EDT_NULL:\r
-                                       return true;\r
-                               case video::EDT_SOFTWARE:\r
-#ifdef _IRR_COMPILE_WITH_SOFTWARE_\r
-                                       return true;\r
-#else\r
-                                       return false;\r
-#endif\r
-                               case video::EDT_BURNINGSVIDEO:\r
-#ifdef _IRR_COMPILE_WITH_BURNINGSVIDEO_\r
-                                       return true;\r
-#else\r
-                                       return false;\r
-#endif\r
-                               case video::EDT_DIRECT3D9:\r
-#ifdef _IRR_COMPILE_WITH_DIRECT3D_9_\r
-                                       return true;\r
-#else\r
-                                       return false;\r
-#endif\r
-                               case video::EDT_OPENGL:\r
-#ifdef _IRR_COMPILE_WITH_OPENGL_\r
-                                       return true;\r
-#else\r
-                                       return false;\r
-#endif\r
-                               case video::EDT_OGLES1:\r
-#ifdef _IRR_COMPILE_WITH_OGLES1_\r
-                                       return true;\r
-#else\r
-                                       return false;\r
-#endif\r
-                               case video::EDT_OGLES2:\r
-#ifdef _IRR_COMPILE_WITH_OGLES2_\r
-                                       return true;\r
-#else\r
-                                       return false;\r
-#endif\r
-                               case video::EDT_WEBGL1:\r
-#ifdef _IRR_COMPILE_WITH_WEBGL1_\r
-                                       return true;\r
-#else\r
-                                       return false;\r
-#endif\r
-                               default:\r
-                                       return false;\r
-                       }\r
+                       return video::isDriverSupported(driver);\r
                }\r
        };\r
 \r