INNER CODE UNIT · Python
color
mosra/magnum-examples · src/python/magnum-texturedquad.py:93
def color(self, color: Color3):
self.set_uniform(self._color_uniform, color)
color = property(None, color)
def bind_texture(self, texture: gl.Texture2D):
texture.bind(self._texture_unit)
class TexturedQuadExample(Application):
def __init__(self):
Application.__init__(self, self.Configuration(
title="Magnum Python Textured Quad Example"
))
vertices = gl.Buffer()
vertices.set_data(array.array('f', [
0.5, -0.5, 1.0, 0.0,
0.5, 0.5, 1.0, 1.0,
-0.5, -0.5, 0.0, 0.0,