Some sort of graphics state handling.