support passing the dimensions object directly