danini-the-panini/mittsu-opengl

View on GitHub
lib/mittsu/opengl_implementation/materials/line_basic_material.rb

Summary

Maintainability
A
0 mins
Test Coverage
A
100%
module Mittsu
  class LineBasicMaterial
    def refresh_uniforms(uniforms)
      uniforms['diffuse'].value = color
      uniforms['opacity'].value = opacity
    end

    def init_shader
      @shader = OpenGL::Shader::Lib.create_shader(shader_id)
    end

    def shader_id
      :basic
    end
  end
end