Fix for image scaling