Winnow Video

From MultimediaWiki
(Redirected from WNV1)
Jump to navigation Jump to search

Winnov Video 1 (FOURCC: WNV1)

Another hardware codec like ATI VCR1, Indeo 2 or Video XL. It uses YUYV format and stores deltas with static code.

Codes used really are simple unary codes with following sign bit and 11111111 code used as escape.

Each component may be decoded this way:

 code = get_code();
 if(code == ESCAPE)
   newval = code;
 else
   newval = oldval + (code << SHIFT);

SHIFT = 6 (may be another, but no samples with another value are known), ESCAPE = 15 (code for ESCAPE is mentioned above)

Winnov Video 2 (FOURCC: WINX)

This one is slightly more advanced codec that codes YUY2 data in 8x8 tiles.

The bitstream is LSB first and has no special header. Each tile is prefixed by coded flag (0 means that the tile is skipped) and 4-bit mode (for coded tiles only).

Supported tile modes

  • 1 - 5-bit raw deltas and codebook deltas shifted by 4 bits;
  • 3 - 6-bit raw deltas and codebook deltas shifted by 5 bits;
  • 15 - end of stream.

Each tile is coded as a sequence of deltas to the previous component value. If the delta value is not "escape" then it should be shifted by the amount of bits defined by the tile mode and added to the previous value, otherwise raw delta value should be read and added instead.

Codebook

The codes are represented here in reversed form for clarity (in reality e.g. -3 is stored as 0x17).

 111111100 -  7
 11111100  -  6
 1111100   -  5
 111100    -  4
 11100     -  3
 1100      -  2
 100       -  1
 0         -  0
 101       - -1
 1101      - -2
 11101     - -3
 111101    - -4
 1111101   - -5
 11111101  - -6
 111111101 - -7
 11111111  - escape