conform to Cg spec about matrices