linux-wallpaperengine/wallpaperengine/image.h
Alexis Maiquez 2be1bffb6f - Removed all the contents of the res folder as those weren't needed anymore
+ Added basic, single-pass-effects parsing
- Removed duplicated code for effect parsing
+ Added support for shader loading and applying to materials (might not work with every shader, still needs some more investigation)
+ Added support for TEXB0001 containers to be able to load images from the wallpaperengine original files

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-04-05 08:34:53 +02:00

37 lines
820 B
C++

#ifndef WALLENGINE_MODEL_H
#define WALLENGINE_MODEL_H
#include <nlohmann/json.hpp>
#include <irrlicht/irrlicht.h>
#include <wallpaperengine/fs/utils.h>
#include <wallpaperengine/texture.h>
namespace wp
{
using json = nlohmann::json;
class image : public object3d
{
public:
image(json json_data, wp::object* parent);
irr::video::SMaterial& getMaterial ();
void setFlag(irr::video::E_MATERIAL_FLAG flag, bool newvalue);
void setType(irr::video::E_MATERIAL_TYPE newType);
void render ();
private:
bool m_visible;
irr::video::S3DVertex m_vertices [4];
irr::video::SMaterial m_material;
irr::io::path m_file;
std::string m_content;
std::vector<wp::texture*> m_textures;
};
};
#endif //WALLENGINE_MODEL_H