Resolve null reference error
Added centerTransform flag