drawing performance optimisations