adding some image scaling stuff