Files
MapLibreParticleLab/src/mbgl/shader/raster_shader.cpp
2015-12-10 11:59:51 -08:00

18 lines
492 B
C++

#include <mbgl/shader/raster_shader.hpp>
#include <mbgl/shader/raster.vertex.hpp>
#include <mbgl/shader/raster.fragment.hpp>
#include <mbgl/platform/gl.hpp>
#include <cstdio>
using namespace mbgl;
RasterShader::RasterShader()
: Shader("raster", shaders::raster::vertex, shaders::raster::fragment) {
}
void RasterShader::bind(GLbyte* offset) {
MBGL_CHECK_ERROR(glEnableVertexAttribArray(a_pos));
MBGL_CHECK_ERROR(glVertexAttribPointer(a_pos, 2, GL_SHORT, false, 0, offset));
}