Class pyglet.graphics.TextureGroup

Group --+
        |
       TextureGroup

A group that enables and binds a texture.

Texture groups are equal if their textures' targets and names are equal.

Methods

  __init__(self, texture, parent=None)
Create a texture group.
  set_state(self)
Apply the OpenGL state change.
  unset_state(self)
Repeal the OpenGL state change.
  __hash__(self)
  __eq__(self, other)
  __repr__(self)
  set_state_recursive(self)
Set this group and its ancestry.
(Inherited from pyglet.graphics.Group)
  unset_state_recursive(self)
Unset this group and its ancestry.
(Inherited from pyglet.graphics.Group)

Method Details

__init__

(Constructor) __init__(self, texture, parent=None)
Create a texture group.
Parameters:
texture : Texture
Texture to bind.
parent : Group
Parent group.
Overrides:
Group.__init__

set_state

set_state(self)

Apply the OpenGL state change.

The default implementation does nothing.

Overrides:
Group.set_state

unset_state

unset_state(self)

Repeal the OpenGL state change.

The default implementation does nothing.

Overrides:
Group.unset_state