Инструменты пользователя

Инструменты сайта


codecs:lossless:wavpack

WavPack

WavPack — свободный open source кодек сжатия без потерь, разработанный David Bryant.

Описание

WavPack («wave-pack») позволяет сжимать аудиоданные PCM, включая целочисленные 8, 16, и 24-битные; 32-битные с плавающей точкой; моно, стерео и многоканальные данные; частота дискредитации от 6 до 192 kHz. Как и в других схемах сжатия без потерь, эффективность сжатия зависит от источника, но обычно она варьируется между 25% и 50% для обычной популярной музыки, а для классической музыки и других композиций с бОльшим динамическим диапазоном эффективность может быть выше.

У WavPack есть уникальный гибридный («hybrid») режим, в котором сочетаются все прелести сжатия без потерь и новые, оригинальные возможности. Этот режим создает не один файл, а два — выскокачественный, относительно небольшой по размеру файл сжатый с потерями, который можно слушать отдельно, и так называемый «коррекционный» файл, который в комбинации с файлом, сжатым с потерями, позволяет получить качество без потерь. Это значит, что для некоторых пользователей полностью отпадает проблема выбора между сжатием с потерями и без!

Характеристики

  • Быстрое и эффективное кодирование и декодирование
  • Open source под лицензией BSDish
  • Мультиплатформенность
  • Аппаратная поддержка
  • Устойчивость к ошибкам
  • Потоковая поддержка
  • Поддержка многоконального аудио и высокие разрешения
  • Режим Hybrid/lossy
  • Поддержка тегов (ID3v1, APE)
  • Поддержка RIFF chunks
  • Поддержка внедренных CUE sheets
  • Включение MD5 быстрого внутреннего контроля
  • Способность создавать самораспаковывающиеся файлы на платформе Win32
  • Совместимость с ReplayGain

Программная поддержка

Плееры

  • NullSoft Winamp (плагин с поддержкой ReplayGain & Media Library) и Winamp-совместимые плееры
  • Foobar2000 Advanced Audio Player (официальный компонент ждя кодирования/декодиования, с поддержкой ReplayGain & Cuesheets)
  • VUPlayer (официальный плагин, поддерживает кодирование)
  • Windows Media Player и другие плееры на базе directshow (MPC, TCMP, RadLight) (с directshow-фильтром CoreWavPack)
  • Apollo Audio Player (плагин с поддержкой ReplayGain)
  • XMplay (официальный плагин)
  • Cog Audio player для MacOS X.
  • XMMS (с плагином Kuniklo)
  • LAMIP (официальный плагин)
  • MPXplay для DOS!

Фронтэнды

Конвертеры

Примечание: некоторые плееры, такие как foobar2000 и VUplayer, могут конвертировать в WavPack)

  • dBpowerAMP Music Converter / Audio Player / CD Writer (официальный плагин)
  • GX:Transcoder Music converter

Редакторы

  • Adobe Audition и Cool Edit (фильтр с поддержкой 32-bit floats & extra info save)

CD райтеры/рипперы

Теггеры

Другие утилиты

Аппаратная поддержка

Описание технологии

To ensure high-speed operation, WavPack uses a very simple predictor that is implemented entirely in integer math. In its «fast» mode the prediction is simply the arithmetic extrapolation of the previous two samples. For example, if the previous two samples were -10 and 20, then the prediction would be 50. For the default mode a simple adaptive factor is added to weigh the influence of the earlier sample on the prediction. In our example the resulting prediction could then vary between 20 for no influence to 50 for full influence. This weight factor is constantly updated based on the audio data's changing spectral characteristics, which is why it is called «adaptive».

The prediction generated is then subtracted from the actual sample to be encoded to generate the error value. In mono mode this value is sent directly to the coder. However, stereo signals tend to have some correlation between the two channels that can be further exploited. Therefore, two error values are calculated that represent the difference and average of the left and right error values. In the «fast» mode of operation these two new values are simply sent to the coder instead of the left and right values. In the default mode, the difference value is always sent to the coder along with one of the other three values (average, left, or right). An adaptive algorithm continuously determines the most efficient of the three to send based on the changing balance of the channels.

The developer has developed a unique data encoder for WavPack that he believes is better than Rice coding in two different areas. It is impossible to encode more efficiently than Rice coding because it represents the optimal bit coding (sometimes known as the Huffman code) for this type of data. WavPack's encoder is slightly less efficient than this, but only by about 0.15 bits/sample (or less than 1% for 16-bit data). The first advantage of WavPack's coder is that it does not require the data to be buffered ahead of encoding, instead it converts each sample directly to bitcodes. This is more computationally efficient and it is better in some applications where coding delay is critical. The second advantage is that it is easily adaptable to lossy encoding because all significant bits (except the implied «one» MSB) are transmitted directly. In this way it is possible to only transmit, for example, the 3 most significant bits (with sign) of each sample. In fact, it is possible to transmit only the sign and implied MSB for each sample with an average of only 3.65 bits/sample.

This coding scheme is used to implement the «lossy» mode of WavPack. In the «fast» mode the output of the non-adaptive decorrelator is simply rounded to the nearest codable value for the specified number of bits. In the default mode the adaptive decorrelator is used (which reduces the average noise about 1 dB) and also both the current and the next sample are considered in choosing the better of the two available codes (which reduces noise another 1 dB).

The developer has decided to not use any floating-point arithmetic in WavPack's data path because he believes that integer operations are less susceptible to subtle chip to chip variations that could corrupt the lossless nature of the compression, the Pentium floating point bug being a blatant example of this. It is possible that a lossless compressor that used floating-point math could generate different output when running on that faulty Pentium. Even disregarding actual bugs, floating-point math is complicated enough that there could be subtle differences between «correct» implementations that could cause trouble for this type of application. To further ensure confidence in the integrity of WavPack's compression, the encoder includes a 32-bit error detection code to the generated streams.

WavPack source code is very portable. It has been compiled on several Unices (Linux, Mac OS X, Solaris, FreeBSD, OpenBSD, NetBSD, Compaq Tru64, HP-UX…) as well as Windows, DOS and OpenVMS. It works on architectures such as x86, ARM, PowerPC, SPARC, DEC Alpha, PA-RISC, MIPS, Motorola 68k…

Внешние ссылки

codecs/lossless/wavpack.txt · Последние изменения: 2007/03/23 12:10 (внешнее изменение)