#pragma once

#include "Shader.hpp"

namespace TSE::OpenGL
{
    class DitheringShader : public Shader
    {
    private:
        static DitheringShader* instance;

    public:
        static DitheringShader* Instance();
        static void Destroy();
        static void Init(float width, float height);
        DitheringShader(std::vector<std::unique_ptr<ShaderPart>>&& parts);

    protected:
        void OnEnable() const override;
        void OnDisable() const override;
        void OnFlush() override;
        void OnDrawCall(int indexCount) override;
        void OnSubmit(const Transformable& t, float*& target, TransformationStack& stack, void (*restartDrawcall)(IRenderer&), IRenderer& rnd) override;
    };
} // namespace TSE::OpenGL
