cleaned & fixed g2d matrix code; began g2d context implementation