#ifndef PW_VISUAL_MESH_RENDERER_HPP
#define PW_VISUAL_MESH_RENDERER_HPP

#include <map>
#include <memory>

namespace pw {

struct geometry;

/**
 * @brief builds a renderer for geometry
 */
struct renderer final {
    renderer();
    renderer(const geometry& m);

    ~renderer();

    bool update(const geometry& m);
    void release();

    void draw();
    bool ready() const;

    uint64_t change_count() const;
    void set_change_count(uint64_t n);

  protected:
    struct impl;
    std::unique_ptr<impl> _impl;
};

} // namespace pw

#endif
