(self)
Initializes the shaders used to render the textures fullscreen quad.
Initializes the shaders used to render the textures fullscreen quad.
Initializes the shaders used to render the textures fullscreen quad .
def _init_shaders(self):
    """Initializes the shaders used to render the textures fullscreen quad."""
    vs = shaders.compileShader(_VERTEX_SHADER, GL.GL_VERTEX_SHADER)
    fs = shaders.compileShader(_FRAGMENT_SHADER, GL.GL_FRAGMENT_SHADER)
    self._shader = shaders.compileProgram(vs, fs)

    stride = _FLOATS_PER_VERTEX * _SIZE_OF_FLOAT
    var_position = GL.glGetAttribLocation(self._shader, _VAR_POSITION)
    GL.glVertexAttribPointer(
        var_position, 2, GL.GL_FLOAT, GL.GL_FALSE, stride, None)
    GL.glEnableVertexAttribArray(var_position)

    var_uv = GL.glGetAttribLocation(self._shader, _VAR_UV)
    uv_offset = ctypes.c_void_p(_FLOATS_PER_XY * _SIZE_OF_FLOAT)
    GL.glVertexAttribPointer(
        var_uv, 2, GL.GL_FLOAT, GL.GL_FALSE, stride, uv_offset)
    GL.glEnableVertexAttribArray(var_uv)

    self._var_texture_sampler = GL.glGetUniformLocation(
        self._shader, _VAR_TEXTURE_SAMPLER)
def _init_shaders ( self ) : vs = shaders . compileShader ( _VERTEX_SHADER , GL . GL_VERTEX_SHADER ) fs = shaders . compileShader ( _FRAGMENT_SHADER , GL . GL_FRAGMENT_SHADER ) self . _shader = shaders . compileProgram ( vs , fs ) stride = _FLOATS_PER_VERTEX * _SIZE_OF_FLOAT var_position = GL . glGetAttribLocation ( self . _shader , _VAR_POSITION ) GL . glVertexAttribPointer ( var_position , 2 , GL . GL_FLOAT , GL . GL_FALSE , stride , None ) GL . glEnableVertexAttribArray ( var_position ) var_uv = GL . glGetAttribLocation ( self . _shader , _VAR_UV ) uv_offset = ctypes . c_void_p ( _FLOATS_PER_XY * _SIZE_OF_FLOAT ) GL . glVertexAttribPointer ( var_uv , 2 , GL . GL_FLOAT , GL . GL_FALSE , stride , uv_offset ) GL . glEnableVertexAttribArray ( var_uv ) self . _var_texture_sampler = GL . glGetUniformLocation ( self . _shader , _VAR_TEXTURE_SAMPLER )