summaryrefslogtreecommitdiff
path: root/libkms++/modedb.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libkms++/modedb.cpp')
-rw-r--r--libkms++/modedb.cpp42
1 files changed, 0 insertions, 42 deletions
diff --git a/libkms++/modedb.cpp b/libkms++/modedb.cpp
deleted file mode 100644
index 53dcfcf..0000000
--- a/libkms++/modedb.cpp
+++ /dev/null
@@ -1,42 +0,0 @@
-#include <xf86drm.h>
-#include <stdexcept>
-
-#include "modedb.h"
-#include "videomode.h"
-
-using namespace std;
-
-namespace kms
-{
-
-static const Videomode& find_from_table(const Videomode* modes, uint32_t width, uint32_t height, uint32_t refresh, bool ilace)
-{
- for (unsigned i = 0; modes[i].clock; ++i) {
- const Videomode& m = modes[i];
-
- if (m.hdisplay != width || m.vdisplay != height)
- continue;
-
- if (refresh && m.vrefresh != refresh)
- continue;
-
- if (ilace != !!(m.flags & DRM_MODE_FLAG_INTERLACE))
- continue;
-
- return m;
- }
-
- throw invalid_argument("mode not found");
-}
-
-const Videomode& find_dmt(uint32_t width, uint32_t height, uint32_t refresh, bool ilace)
-{
- return find_from_table(dmt_modes, width, height, refresh, ilace);
-}
-
-const Videomode& find_cea(uint32_t width, uint32_t height, uint32_t refresh, bool ilace)
-{
- return find_from_table(cea_modes, width, height, refresh, ilace);
-}
-
-}