aboutsummaryrefslogtreecommitdiff
path: root/src/device_context.hh
diff options
context:
space:
mode:
authorNicolas James <nj3ahxac@gmail.com>2026-02-10 10:49:17 +1100
committerNicolas James <nj3ahxac@gmail.com>2026-02-10 10:49:17 +1100
commit77e2be172718878b38999efc247ce7571435fcc8 (patch)
tree557344a614dd89ecec3ac5dbcd83dbcc1375bf55 /src/device_context.hh
parent5ab5046b643b04b9c31fd41cdfca39b9d5f6b99e (diff)
cleanup, wip
Diffstat (limited to 'src/device_context.hh')
-rw-r--r--src/device_context.hh35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/device_context.hh b/src/device_context.hh
new file mode 100644
index 0000000..a936d6d
--- /dev/null
+++ b/src/device_context.hh
@@ -0,0 +1,35 @@
+#ifndef DEVICE_CONTEXT_HH_
+#define DEVICE_CONTEXT_HH_
+
+#include <memory>
+#include <unordered_map>
+
+#include <vulkan/utility/vk_dispatch_table.h>
+#include <vulkan/vulkan.hpp>
+
+#include "instance_context.hh"
+
+namespace low_latency {
+
+class QueueContext;
+
+struct DeviceContext {
+ InstanceContext& instance;
+
+ const VkDevice device;
+ const VkuDeviceDispatchTable vtable;
+
+ std::unordered_map<VkQueue, std::unique_ptr<QueueContext>> queue_contexts;
+
+ public:
+ DeviceContext(InstanceContext& parent_instance, const VkDevice& device,
+ VkuDeviceDispatchTable&& vtable);
+ DeviceContext(const DeviceContext&) = delete;
+ DeviceContext(DeviceContext&&) = delete;
+ DeviceContext operator==(const DeviceContext&) = delete;
+ DeviceContext operator==(DeviceContext&&) = delete;
+};
+
+}; // namespace low_latency
+
+#endif \ No newline at end of file