Fixed a bug in the scaling and offsetting code.  Getting close...