Buckets rendering is added but the repainting of the image is very slow