
#ifndef TDECO_H_INCLUDED
#define TDECO_H_INCLUDED

/*
OBJET       classe d'une decoration/objet statique

DATE        04/2025

AUTEUR      philippe Thebaud

COMMENTAIRE
*/

#include <GL/glew.h>
#include <string>
#include <fstream>
#include <vector>
#include <deque>

#include "../ECO/OUtils.h"
#include "../ECO/OMesh_obj.h"
#include "../ECO/defered/ODshGeo.h"
#include "../ECO/shader/OShGlow.h"

#include "common.h"



class Tdeco
{
public:
	Tdeco();
	~Tdeco();

    void        addModel(std::string flux);

    void        create(std::string flux);

	void        draw(ODshGeo& dshGeo);
	void        draw_emissive(OShGlow& shGlow);

	uint32_t    getId_diffuseMap(size_t part);
	uint32_t    getId_normalMap(size_t part);
	OMat4&      getModel(size_t part);
	size_t      getPart_size();
    bool        getSelect();

private:

    void        _composition();

	void		_setModel(size_t idx);

private:

    std::string m_code, m_path, m_file;
	bool        m_cull_face;
	OMesh_obj   mesh;

    std::vector<OMat4>      m_model;
	std::vector<OMat4>      m_model_multi;
    std::vector<OVec3_f>    m_pos;
    std::vector<OVec3_f>    m_rot;
    std::vector<OVec3_f>    m_scale;

};

#endif
