summaryrefslogtreecommitdiff
path: root/include/mbgl/geometry/icon_buffer.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/mbgl/geometry/icon_buffer.hpp')
-rw-r--r--include/mbgl/geometry/icon_buffer.hpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/include/mbgl/geometry/icon_buffer.hpp b/include/mbgl/geometry/icon_buffer.hpp
new file mode 100644
index 0000000000..346b3b5f06
--- /dev/null
+++ b/include/mbgl/geometry/icon_buffer.hpp
@@ -0,0 +1,20 @@
+#ifndef MBGL_GEOMETRY_ICON_BUFFER
+#define MBGL_GEOMETRY_ICON_BUFFER
+
+#include "buffer.hpp"
+
+namespace mbgl {
+
+ class IconVertexBuffer : public Buffer<
+ 4 + // int16 x/y coordinates per vertex (== 4 bytes)
+ 4 // uint16 x/y coordinates of icon in sprite (== 4 bytes)
+ > {
+ public:
+ typedef int16_t vertex_type;
+
+ void add(vertex_type x, vertex_type y, uint16_t tx, uint16_t ty);
+ };
+
+}
+
+#endif