remove unbalanced matrix pop ops
fix stack depth assertions
don't expose GL constants
use correct stack