trying to remove gl calls