Performance improvements in drawing and animations