Added image dimension support