Jump to content

User:Regression Tester/sandbox

From Wikipedia, the free encyclopedia
FFv1
Initial release9 June 2003; 21 years ago (2003-06-09)
TypeVideo compression format

FFV1, which stands for "FF video codec 1", is a lossless intra-frame video codec. It can use either variable length coding or arithmetic coding for entropy coding. The encoder and decoder are part of the free, open-source library libavcodec in the project FFmpeg since June 2003[1]. FFV1 is also included in ffdshow, which makes the video codec available to any Microsoft Windows application that uses system-wide codecs.

Video archiving

[edit]

For long-term preservation of digital video sustainable container formats as well as audio/video codecs are necessary. The current proclaimed codecs are Motion JPEG 2000[2] and uncompressed video.

FFv1 has turned out to be a viable addition to that choice. With compression ratios comparable to JPEG 2000 lossless and its lower computing requirements, it is already being used by professional archives as their long-term storage codec. The "Österreichische Mediathek", Austria's national audio/video archive has developed DVA-Profession, a Free Software solution for archive-suitable mass video digitization, using FFv1 for storing their videos. The City of Vancouver Archives is also using FFv1 (in a Matroska container) for long-term storage[3][4].

Within the video archiving domain, the interest in FFv1 is increasing, as can be seen in a thread on the AMIA-L mailing list[5], the PrestoCentre Forum[6] or the Archivematica mailing list[7][8].

In January 2013, the possible use and adoption of FFv1 as archiving codec is addressed in the issue of PrestoCentre's "AV Insider" magazine[9]:

"FFV1 has many beneficial technical features [...], but adoption rates are relatively low compared with alternatives, for example JPEG2000. [...] But holding back too long only serves to self-perpetuate the status of FFV1. The adoption by Archivematica and the Austrian Mediathek with their active promotion of FFV1 along with others may start to break this vicious circle. This could lead to a virtuous circle of wider take-up, to shared development, to incorporation into commercial products and a host of other benefits

for the community."


Prediction process

[edit]

FFV1 is not strictly an intra-frame format; despite not using inter-frame prediction, it allows the context model to adapt over multiple frames. This can be useful for compression due to the very large size of the context table, but can be disabled to force the encoder to generate a strictly intra-frame bitstream. As the gained compression seems to decrease[10] with later versions of FFv1 (version 2,3), the use of GOP size greater than "1" might disappear in the future.

During progressive scanning of a frame, the difference between a current pixel and its predicted value, judging by neighboring pixels, is sent to the entropy-coding process. The prediction is done as follows:

Prediction = Median( Top, Left, Top + Left - TopLeft )

The third value, "Top + Left - TopLeft", is also known as the gradient, so in simple terms the prediction is the median of the top, left, and gradient prediction methods. For improved performance and simplicity, the edges of the frame are assumed to be zero to avoid special cases. The prediction in encoding and decoding is managed using a ring buffer.

Entropy coding process

[edit]

The residuals are coded using either variable-length coding or arithmetic coding. Both options use a very large context model. The "small" context model uses (11*11*11+1)/2=666 contexts based on the neighboring values of (Left-TopLeft), (TopLeft-Top), and (Top-TopRight). The "large" context model uses (11*11*5*5*5+1)/2=7563 contexts based on the same values as before, but also (TopTop - Top) and (LeftLeft-Left), where "TopTop" is the pixel two above the current one vertically, and "LeftLeft" is the pixel two to the left of the current one. In arithmetic coding, each "context" actually has 32 sub-contexts used for various portions of coding each residual, resulting in a grand total of 242,016 contexts for the "large" model. The arithmetic coder of FFV1 is very similar to (and based on) that of h.264.

Status

[edit]

On April 16, 2006, a commit-message by Michael Niedermayer confirmed that the bitstream of FFv1 (version 1) is fixed[11]:

"ffv1 and ffvhuff havnt changed since a long time and noone proposed any changes within 1 month after my warning so they are officially no longer experimental and we will gurantee decodeability of files encoded with

the currenzt ffv1/ffvhuff in the future"

Current status is that the bitstream (version 1) is fixed since April 2006[11], and the codec is no longer marked as experimental since March 2010[12]. Although its documentation remains incomplete, starting April 2012, efforts are being undertaken in order to improve its documentation. The current version of FFv1's technical specification document can be found on GitHub.

See also

[edit]


References

[edit]
  1. ^ "Repository history of FFv1's sourcecode in FFMPEG repository". Michael Niedermayer. Retrieved 21 October 2010.
  2. ^ "Motion JPEG 2000 at digitalpreservation.gov". U.S. Library of Congress. Retrieved 6 March 2013.
  3. ^ "Matroska video container information at digitalpreservation.gov". U.S. Library of Congress. Retrieved 10 May 2012.
  4. ^ "A City of Vancouver Archives' blog post mentioning their use of FFV1". City of Vancouver Archives. Retrieved 10 May 2012. {{cite web}}: External link in |publisher= (help)
  5. ^ "FFv1 discussion on AMIA-L mailing list". Association of Moving Image Archivists (AMIA). December 2012. Retrieved 6 March 2013. {{cite web}}: External link in |publisher= (help)
  6. ^ "Digital master archive format". PrestoCentre Forums. 26 October 2012. Retrieved 6 March 2013. {{cite web}}: External link in |publisher= (help)
  7. ^ "FFV1 vs other formats for preservation". Archivematica mailing list. 24 September 2012. Retrieved 6 March 2013. {{cite web}}: External link in |publisher= (help)
  8. ^ "Digital film archiving in big scale". Archivematica mailing list. 29 January 2013. Retrieved 6 March 2013. {{cite web}}: External link in |publisher= (help)
  9. ^ Addis, Matthew (2013). "Crossing the Chasm (From Research Results to Sustainable Tools and Services for AV)". AV Insider Magazine (#3). PrestoCentre: p14-15. {{cite journal}}: |pages= has extra text (help); External link in |publisher= (help)
  10. ^ "Message on FFmpeg developer mailing list about the impact of GOP size parameter of FFv1". Retrieved 10 May 2012.
  11. ^ a b "Repository commit message". Michael Niedermayer. 14 April 2006. Retrieved 8 May 2012.
  12. ^ "Repository commit message". Michael Niedermayer. 22 March 2010. Retrieved 21 October 2010.
[edit]


Category:Free codecs Category:Video codecs