Fixed grid spacing bug which cause infinite cycle when render