]> git.tdb.fi Git - libs/gui.git/blobdiff - source/graphics/videomode.h
Add decorations for things which should be exported from the library
[libs/gui.git] / source / graphics / videomode.h
index f1715c0428d6dfc49a62d5a4de71af4bf9883afe..ea69e1b8fc7dfd42545463216f33928695da6d1e 100644 (file)
@@ -1,29 +1,41 @@
 #ifndef MSP_GRAPHICS_VIDEOMODE_H_
 #define MSP_GRAPHICS_VIDEOMODE_H_
 
+#include <stdexcept>
+#include "mspgui_api.h"
+
 namespace Msp {
 namespace Graphics {
 
 struct Monitor;
 struct VideoMode;
 
-class unsupported_video_mode: public std::runtime_error
+class MSPGUI_API unsupported_video_mode: public std::runtime_error
 {
 public:
        unsupported_video_mode(const VideoMode &);
-       virtual ~unsupported_video_mode() throw () { }
 };
 
 
-struct VideoMode
+enum VideoRotation
 {
-       unsigned index;
-       const Monitor *monitor;
-       unsigned width;
-       unsigned height;
-       unsigned rate;
+       ROTATE_ANY,
+       ROTATE_NORMAL,
+       ROTATE_LEFT,
+       ROTATE_RIGHT,
+       ROTATE_INVERTED
+};
 
-       VideoMode();
+struct MSPGUI_API VideoMode
+{
+       unsigned index = 0;
+       const Monitor *monitor = nullptr;
+       unsigned width = 0;
+       unsigned height = 0;
+       float rate = 0.0f;
+       VideoRotation rotation = ROTATE_ANY;
+
+       VideoMode() = default;
        VideoMode(unsigned, unsigned);
 };