Fixed reversed image.scale in macos

image.scale has its parameters reverse on MacOSX. This makes the captured image all black.