Use local variables for quadtree bounds.

Also, limit size to [width, height].