Patent ID: 8665955

Claim:
A method of storing a picture in a memory, the picture being divided into data blocks, the method comprising the steps of: computing a transform of an input data block to produce a transformed data block comprising a set of n transformed elements, where n is an integer; entropy coding m first transformed elements of the transformed data block to produce an encoded data block, where m is an integer lower than n; computing a cost function on the basis of a weighted sum of a distortion value between the input data block and the encoded data block and a power consumption required for reading or writing the encoded data block in the memory; iterating, for a plurality of different values of m, the steps of entropy coding the transformed data block and cost function computing, wherein the step of iterating includes, for each respective value x of the plurality of different values of m, entropy coding x first transformed elements of the transformed data block for producing an encoded data block, where 1≦x≦m; and storing in the memory the encoded data block corresponding to the value of m that minimizes the cost function.