diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index dccf5cc..1656a2c 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt @@ -16,6 +16,7 @@ set(hdrs include/pw/core/timer.hpp include/pw/core/mesh.hpp include/pw/core/globals.hpp + include/pw/core/image.hpp ) set(srcs @@ -26,6 +27,7 @@ set(srcs src/core.cpp src/serialize.cpp src/timer.cpp + src/image.cpp ${CMAKE_SOURCE_DIR}/README.md ${CMAKE_SOURCE_DIR}/LICENSE ) diff --git a/src/core/include/pw/core/image.hpp b/src/core/include/pw/core/image.hpp index 1fc9107..73ff30d 100644 --- a/src/core/include/pw/core/image.hpp +++ b/src/core/include/pw/core/image.hpp @@ -24,6 +24,7 @@ #define PW_CORE_IMAGE_HPP #include +#include namespace pw { @@ -32,11 +33,21 @@ public: image() = default; + enum image_type { + RGB8, + RGBA8, + LUM + }; + bool create(const sizei& size,); + + const uint8_t *data() const { return _data.data(); } + uint8_t *data() { return _data.data(); } protected: - std::vector _data; + sizei _size; + std::vector _data; std::string _uri; }; diff --git a/src/core/src/image.cpp b/src/core/src/image.cpp index fdd0408..e69de29 100644 --- a/src/core/src/image.cpp +++ b/src/core/src/image.cpp @@ -1,7 +0,0 @@ -#include "pw/core/image.hpp" - -namespace pw { - - - -}