Implement propagation of offsets

still cannot reconstract input image.
(to be continued....)