change the drawing method to canvas instead of DOM because its faster.