Fixe to direct access to GL2 objects.

Signed-off-by: Jérôme Benoit <jerome.benoit@grenouille.com>