only call patch_sampler if width and is larger than 0.