summaryrefslogtreecommitdiff
path: root/include/mbgl/shader/raster_shader.hpp
blob: 8cf97055a2a4f97f721aceddcc529276728ae73c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#ifndef MBGL_RENDERER_SHADER_RASTER
#define MBGL_RENDERER_SHADER_RASTER

#include <mbgl/shader/shader.hpp>
#include <mbgl/shader/uniform.hpp>

namespace mbgl {

class RasterShader : public Shader {
public:
    RasterShader();

    void bind(char *offset);

    UniformMatrix<4>              u_matrix            = {"u_matrix",            *this};
    Uniform<int32_t>              u_image             = {"u_image",             *this};
    Uniform<float>                u_opacity           = {"u_opacity",           *this};
    Uniform<float>                u_buffer            = {"u_buffer",            *this};
    Uniform<float>                u_brightness_low    = {"u_brightness_low",    *this};
    Uniform<float>                u_brightness_high   = {"u_brightness_high",   *this};
    Uniform<float>                u_saturation_factor = {"u_saturation_factor", *this};
    Uniform<float>                u_contrast_factor   = {"u_contrast_factor",   *this};
    Uniform<std::array<float, 3>> u_spin_weights      = {"u_spin_weights",      *this};

private:
    int32_t a_pos = -1;
};

}

#endif