Video compression has been investigated by means of analysis-synthesis, and more particularly by means of inpainting. The first part of our approach has been to develop the inpainting of DCT coefficients in an image. This has shown good results for image compression without overpassing todays compression standards like JPEG. We then looked at integrating the same approach in a video coder, and in particular in the widely used H264 AVC standard coder, but the same approach can be used in the framework of HEVC. The originality of this work consists in cancelling at the coder, then automatically restoring, at the decoder, some well chosen DCT residual coefficients. For this purpose, we have developed a restoration model of transformed coefficients. By using a total variation based model, we derive conditions for the reconstruction of transformed coefficients that have been suppressed or altered. The main purpose here, in a video coding context, is to improve the ratedistortion performance of existing coders. To this end DCT restoration is used as an additional prediction step to the spatial prediction of the transformed coefficients, based on an image regularization process. The method has been successfully tested with the H.264 AVC video codec standard.