![]() |
Lysa
0.0
Lysa 3D Engine
|
A bitmap resource, stored in GPU memory.
Inheritance diagram for Image:Public Member Functions | |
| Image (const std::shared_ptr< vireo::Image > &image, const std::string &name) | |
| auto | getWidth () const |
| auto | getHeight () const |
| auto | getSize () const |
| auto | getImage () const |
| auto | getIndex () const |
| void | save (const std::string &filepath) const |
| ~Image () override = default | |
Public Member Functions inherited from Resource | |
| Resource (const std::string &name) | |
| auto | getId () const |
| const auto & | getName () const |
| bool | operator== (const Resource &other) const |
| bool | operator< (const Resource &other) const |
| bool | operator> (const Resource &other) const |
| virtual std::shared_ptr< Resource > | duplicate () const |
Public Member Functions inherited from Object | |
| void | connect (const Signal::signal &name, const Signal::Handler &handler) |
| void | connect (const Signal::signal &name, const std::function< void ()> &handler) |
| void | emit (const Signal::signal &name, void *params=nullptr) |
| virtual std::string | toString () const |
| Object () = default | |
| virtual | ~Object () = default |
Static Public Member Functions | |
| static void | save (const std::string &filepath, const std::shared_ptr< vireo::Image > &image) |
| static std::shared_ptr< Image > | load (const std::string &filepath, vireo::ImageFormat imageFormat=vireo::ImageFormat::R8G8B8A8_SRGB) |
| static std::shared_ptr< Image > | create (const void *data, uint32 width, uint32 height, vireo::ImageFormat imageFormat=vireo::ImageFormat::R8G8B8A8_SRGB, const std::string &name="Image") |
Protected Attributes | |
| std::shared_ptr< vireo::Image > | image |
| uint32 | index |
| Image | ( | const std::shared_ptr< vireo::Image > & | image, |
| const std::string & | name | ||
| ) |
|
overridedefault |
|
static |
Load a bitmap from memory.
Supports JPEG & PNG formats.
|
inline |
Returns the height in pixels
|
inline |
|
inline |
|
inline |
Returns the size in pixels
|
inline |
Returns the width in pixels
|
static |
Load a bitmap from a file.
Supports JPEG and PNG formats
| void save | ( | const std::string & | filepath | ) | const |
|
static |
|
protected |
|
protected |