A method of generating a spatial prediction of a target block of pixels in a target image includes generating a spatial vector for a target block of pixels, using the spatial vector to construct a spatial reference block, and using the spatial reference block to generate the spatial prediction of the target block.