/******************************************************************************
*	File		-	image.h
*	Author		-	Joey Pollack
*	Date		-	2022/11/28 (y/m/d)
*	Mod Date	-	2022/11/28 (y/m/d)
*	Description	-	The editor warpper for an Image asset
******************************************************************************/

#ifndef LUNARIUM_EDITOR_TEXTURE_H_
#define LUNARIUM_EDITOR_TEXTURE_H_


#include "editor_asset.h"
#include <utils/uuid.h>

namespace lunarium
{
    class Texture;
}

namespace lunarium { namespace editor {

    class Image : public EditorAsset
    {
    public:
        Image();
        ~Image();

        [[nodiscard]] virtual OpRes LoadRawFile();
        [[nodiscard]] virtual OpRes Serialize(nlohmann::ordered_json& node);
        [[nodiscard]] virtual OpRes Deserialize(nlohmann::ordered_json& node);
        [[nodiscord]] virtual bool IsValidNode(nlohmann::ordered_json& node);
        [[nodiscard]] virtual nlohmann::ordered_json AsJSON();

        bool DrawProperties();

        lunarium::Texture* GetImage() const;

    private:
        lunarium::Texture* mpImage;
    };

}}


#endif	// LUNARIUM_EDITOR_TEXTURE_H_