mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-06-03 02:23:44 +00:00
more conversion operator to avoid extracting data methods
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
#include <raylib.h>
|
||||
#include <string>
|
||||
#include "Canvas.hpp"
|
||||
#include "Texture.hpp"
|
||||
#include "IRessource.hpp"
|
||||
|
||||
namespace RAY
|
||||
@@ -25,6 +26,10 @@ namespace RAY
|
||||
//! @param filename: path to file to load
|
||||
Image(const std::string &filename);
|
||||
|
||||
//! @brief Create an image, using data from a texure
|
||||
//! @param texture: texture to extract data from
|
||||
Image(Texture &texture);
|
||||
|
||||
//! @brief A default copy constructor
|
||||
Image(const Image &image) = default;
|
||||
|
||||
@@ -49,7 +54,8 @@ namespace RAY
|
||||
bool unload() override;
|
||||
|
||||
//! @brief get image
|
||||
::Image &getImage(void);
|
||||
operator ::Image() const;
|
||||
operator ::Image *();
|
||||
|
||||
//! @brief draw drawable
|
||||
void draw(Drawables::ADrawable2D &);
|
||||
|
||||
Reference in New Issue
Block a user