summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2019-06-07 13:07:57 -0300
committerJuan Linietsky <reduzio@gmail.com>2020-02-11 11:53:26 +0100
commitfd188ddd5176390efb22ed041d8aedad25d81dee (patch)
tree18766edace54f7e3e5ed5c1efe1223de163cad86 /core
parent3e3f8a47616327d7faeb17f558bb81a943385e82 (diff)
Initial work on Vulkan:
-Added VulkanContext -Added an X11 implementation -Added a rendering device abstraction -added a Vulkan rendering device abstraction -Engine does not work, only shows Godot logo (run it from bin/)
Diffstat (limited to 'core')
-rw-r--r--core/oa_hash_map.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/core/oa_hash_map.h b/core/oa_hash_map.h
index 7407c52816..182ed8b116 100644
--- a/core/oa_hash_map.h
+++ b/core/oa_hash_map.h
@@ -240,6 +240,22 @@ public:
return false;
}
+ /**
+ * returns true if the value was found, false otherwise.
+ *
+ * if r_data is not NULL then the value will be written to the object
+ * it points to.
+ */
+ TValue *lookup_ptr(const TKey &p_key) const {
+ uint32_t pos = 0;
+ bool exists = _lookup_pos(p_key, pos);
+
+ if (exists) {
+ return &values[pos];
+ }
+ return NULL;
+ }
+
_FORCE_INLINE_ bool has(const TKey &p_key) const {
uint32_t _pos = 0;
return _lookup_pos(p_key, _pos);