summaryrefslogtreecommitdiff
path: root/kms++/drmobject.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kms++/drmobject.cpp')
-rw-r--r--kms++/drmobject.cpp34
1 files changed, 34 insertions, 0 deletions
diff --git a/kms++/drmobject.cpp b/kms++/drmobject.cpp
new file mode 100644
index 0000000..8abecc7
--- /dev/null
+++ b/kms++/drmobject.cpp
@@ -0,0 +1,34 @@
+#include <string.h>
+#include <iostream>
+#include <stdexcept>
+
+#include <xf86drm.h>
+#include <xf86drmMode.h>
+
+#include "kms++.h"
+
+using namespace std;
+
+namespace kms
+{
+
+DrmObject::DrmObject(Card& card, uint32_t object_type)
+ :m_card(card), m_id(-1), m_object_type(object_type), m_idx(0)
+{
+}
+
+DrmObject::DrmObject(Card& card, uint32_t id, uint32_t object_type, uint32_t idx)
+ :m_card(card), m_id(id), m_object_type(object_type), m_idx(idx)
+{
+}
+
+DrmObject::~DrmObject()
+{
+
+}
+
+void DrmObject::set_id(uint32_t id)
+{
+ m_id = id;
+}
+}