optimise drawing