Transforming bi-dimensional images into mono-dimensional sequences with Peano scan (PS) allows using Hidden Markov Chains (HMCs) for unsupervised image segmentation. In some situations, such methods can be competitive compared to Hidden Markov Fields (HMFs) based ones, while being much faster. We propose enriching the HMC-PS model by introducing “contextual” Peano scan (CPS). It consists in associating to each index in the HMC obtained from PS, two observations on pixels which are neighbors of the pixel considered in the image, but are not its neighbors in the HMC. This gives three observations on each point of the Peano scan, which leads to a new HMC with a more complex structure, but whose prior and posterior laws are still Markovian. Therefore we can apply the usual parameter estimation method: Stochastic Expectation-Maximization (SEM), as well as study unsupervised segmentation Marginal Posterior Mode (MPM) so obtained. The CPS based supervised and unsupervised MPM are compared to the classic scan based HMC-PS and the HMF through experiments on artificial images. They improve notably the former, and can even compete with the latter.