VP6 with Alpha
[Video Codecs]


Detailed Description

The VP6 codec with support for an alpha channel.

Example Usage:

   sc = Flix2_AddCodec(&codec, flix, FE2_CODEC_VP6ALPHA);
   //Use 380kbit for the video ..
   if(sc == ON2_OK)
       sc = Flix2_CodecSetParam(codec, FE2_VP6A_BITRATE, 380.0);
   //..and 68kbit for the alpha channel
   if(sc == ON2_OK)
       sc = Flix2_CodecSetParam(codec, FE2_VP6A_ALPHA_BITRATE, 68.0);

As mentioned in the VP6 section Defaults dependent on bits per pixel some of the codec parameters are determined by the bits per pixel in the output. Currently the alpha channel parameters, e.g. FE2_VP6A_ALPHA_MIN_Q, match their VP6 equivalents.


Codec name

#define FE2_CODEC_VP6ALPHA
 Codec name for use with Flix2_AddCodec().

General VP6 settings

#define FE2_VP6A_BITRATE
 Alias for FE2_CODECPARAM_BITRATE.
#define FE2_VP6A_ALPHA_BITRATE
 Compressed bitrate of the alpha channel in kbit/s.
#define FE2_VP6A_KFINTTYPE
 Alias for FE2_VP6_KFINTTYPE.
#define FE2_VP6A_KFFREQ
 Alias for FE2_VP6_KFFREQ.
#define FE2_VP6A_RC_MODE
 Alias for FE2_VCODECPARAM_RC_MODE.
#define FE2_VP6A_CXMODE
 Alias for FE2_VP6_CXMODE.
#define FE2_VP6A_SHARPNESS
 Alias for FE2_VP6_SHARPNESS.
#define FE2_VP6A_ALPHA_SHARPNESS
 Sharpness for the alpha channel.
#define FE2_VP6A_NOISE_REDUCTION
 Alias for FE2_VP6_NOISE_REDUCTION.
#define FE2_VP6A_ALPHA_NOISE_REDUCTION
 Noise reduction for the alpha channel.

Advanced VP6 settings

#define FE2_VP6A_UNDERSHOOT_PCT
 Alias for FE2_VP6_UNDERSHOOT_PCT.
#define FE2_VP6A_MIN_Q
 Alias for FE2_VP6_MIN_Q.
#define FE2_VP6A_ALPHA_MIN_Q
 Minimum quantizer for the alpha channel.
#define FE2_VP6A_MAX_Q
 Alias for FE2_VP6_MAX_Q.
#define FE2_VP6A_ALPHA_MAX_Q
 Maximum quantizer for the alpha channel.
#define FE2_VP6A_TEMPORAL_RESAMPLING
 Alias for FE2_VP6_TEMPORAL_RESAMPLING.
#define FE2_VP6A_TEMPORAL_DOWN_WATERMARK
 Alias for FE2_VP6_TEMPORAL_DOWN_WATERMARK.
#define FE2_VP6A_STREAM_PEAK_BITRATE
 Alias for FE2_VP6_STREAM_PEAK_BITRATE.
#define FE2_VP6A_STREAM_PREBUFFER
 Alias for FE2_VP6_STREAM_PREBUFFER.
#define FE2_VP6A_STREAM_OPTIMAL_BUFFER
 Alias for FE2_VP6_STREAM_OPTIMAL_BUFFER.
#define FE2_VP6A_STREAM_MAX_BUFFER
 Alias for FE2_VP6_STREAM_MAX_BUFFER.
#define FE2_VP6A_2PASS_MIN_SECTION
 Alias for FE2_VP6_2PASS_MIN_SECTION.
#define FE2_VP6A_2PASS_MAX_SECTION
 Alias for FE2_VP6_2PASS_MAX_SECTION.

Define Documentation

#define FE2_CODEC_VP6ALPHA

Codec name for use with Flix2_AddCodec().

Definition at line 56 of file vp6_alpha.h.

#define FE2_VP6A_2PASS_MAX_SECTION

Alias for FE2_VP6_2PASS_MAX_SECTION.

VBR_2PASSControl maximum section datarate

This value is given as a percentage. The highest datarate, i.e., $\textit{FE2\_VP6\_2PASS\_MAX\_SECTION}\% \times \textit{FE2\_VP6\_BITRATE}$, that can be streamed, and also the highest datarate that the encoder will allow, no matter how difficult the section is.

Note:
Default: 400

Definition at line 202 of file vp6_alpha.h.

#define FE2_VP6A_2PASS_MIN_SECTION

Alias for FE2_VP6_2PASS_MIN_SECTION.

VBR_2PASSControl minimum section datarate

This value is given as a percentage. The lowest datarate, i.e., $\textit{FE2\_VP6\_2PASS\_MIN\_SECTION}\% \times \textit{FE2\_VP6\_BITRATE}$, that the encoder will allow for any section, no matter how easy the section is. This value is used to prevent difficult sections from stealing too many bits from easy sections.

Note:
Default: 40

Definition at line 196 of file vp6_alpha.h.

#define FE2_VP6A_ALPHA_BITRATE

Compressed bitrate of the alpha channel in kbit/s.

Note:
Default: 68 (15% of default 448kbps)

Definition at line 74 of file vp6_alpha.h.

#define FE2_VP6A_ALPHA_MAX_Q

Maximum quantizer for the alpha channel.

See also:
FE2_VP6A_MAX_Q

Definition at line 154 of file vp6_alpha.h.

#define FE2_VP6A_ALPHA_MIN_Q

Minimum quantizer for the alpha channel.

See also:
FE2_VP6A_MIN_Q

Definition at line 143 of file vp6_alpha.h.

#define FE2_VP6A_ALPHA_NOISE_REDUCTION

Noise reduction for the alpha channel.

See also:
FE2_VP6A_NOISE_REDUCTION

Definition at line 120 of file vp6_alpha.h.

#define FE2_VP6A_ALPHA_SHARPNESS

Sharpness for the alpha channel.

See also:
FE2_VP6A_SHARPNESS

Definition at line 109 of file vp6_alpha.h.

#define FE2_VP6A_BITRATE

Alias for FE2_CODECPARAM_BITRATE.

Codec parameter for stream bitrate.

Compressed stream bitrate in kbits/sec.

Note:
Default: 380

Definition at line 69 of file vp6_alpha.h.

#define FE2_VP6A_CXMODE

Alias for FE2_VP6_CXMODE.

VP6 compress mode.

Valid values are defined by FE2_CompressMode

Note:
Default: COMPRESSMODE_GOOD

Definition at line 98 of file vp6_alpha.h.

#define FE2_VP6A_KFFREQ

Alias for FE2_VP6_KFFREQ.

Alias for FE2_VCODECPARAM_KFFREQ.

Video codec parameter for keyframe frequency.

Value is in video frames. The interpretation depends on the setting of FE2_VCODECPARAM_KFINTTYPE

See also:
FE2_VideoKeyframeTypes
Note:
Default: $12.0 \times output_fps$ or 360 frames if the framerate is unknown

Definition at line 86 of file vp6_alpha.h.

#define FE2_VP6A_KFINTTYPE

Alias for FE2_VP6_KFINTTYPE.

Alias for FE2_VCODECPARAM_KFINTTYPE.

Video codec parameter for the keyframe interval type.

Valid values are defined by FE2_VideoKeyframeTypes.

Note:
Default: MAX_KEYFRAMES

Definition at line 80 of file vp6_alpha.h.

#define FE2_VP6A_MAX_Q

Alias for FE2_VP6_MAX_Q.

Codec parameter for maximum quantizer.

Determines the quality of the output. A lower maximum number produces higher quality output.

Note:
Valid range: [0,63]
Default: Bits per pixel dependent
Attention:
Setting this value too low will likely cause the encoder to miss (i.e., overshoot) the target datarate specified by FE2_VP6_BITRATE and, should FE2_VP6_TEMPORAL_RESAMPLING be enabled, result in a large amount of dropped frames. The table mentioned above should be used as a guide in choosing a reasonable value based on the bitrate.

Definition at line 149 of file vp6_alpha.h.

#define FE2_VP6A_MIN_Q

Alias for FE2_VP6_MIN_Q.

Codec parameter for minimum quantizer.

Determines the quality of the output. A lower minimum number produces higher quality output.

Note:
Valid range: [0,63]
Default: Bits per pixel dependent

Definition at line 138 of file vp6_alpha.h.

#define FE2_VP6A_NOISE_REDUCTION

Alias for FE2_VP6_NOISE_REDUCTION.

Codec parameter for noise reduction.

Determines the level of noise filtering to apply in the preprocessor. 0 is no preprocessing, 6 is extreme preprocessing.

Note:
Valid range: [0,6]
Setting this value to anything but 0 will result in slowing down the compression speed.
Default: Bits per pixel dependent

Definition at line 115 of file vp6_alpha.h.

#define FE2_VP6A_RC_MODE

Alias for FE2_VCODECPARAM_RC_MODE.

Note:
Default: VBR_2PASSControl

Definition at line 92 of file vp6_alpha.h.

#define FE2_VP6A_SHARPNESS

Alias for FE2_VP6_SHARPNESS.

Codec parameter for sharpness.

Controls the sharpness of the image in the output. This setting does not impact any other setting and is largely a matter of personal preference. A low sharpness setting will result in fewer visible artifacts but may blur the image somewhat; a high sharpness will result in a sharper image but may result in more visible artifacts.

Note:
Valid range: [0,7]
Default: Bits per pixel dependent

Definition at line 104 of file vp6_alpha.h.

#define FE2_VP6A_STREAM_MAX_BUFFER

Alias for FE2_VP6_STREAM_MAX_BUFFER.

The maximum size of the buffer, in seconds.

Attention:
Valid for CBR only

Definition at line 190 of file vp6_alpha.h.

#define FE2_VP6A_STREAM_OPTIMAL_BUFFER

Alias for FE2_VP6_STREAM_OPTIMAL_BUFFER.

Buffer size that the encoder strives to reach or maintain in case of specific frame overshoots.

Note:
Default: 10
Attention:
Valid for CBR only

Definition at line 184 of file vp6_alpha.h.

#define FE2_VP6A_STREAM_PEAK_BITRATE

Alias for FE2_VP6_STREAM_PEAK_BITRATE.

The maximum bitrate allowed in the stream.

This value is given as a percentage. The peak bitrate is calculated as follows: $\textit{FE2\_VP6\_STREAM\_PEAK\_BITRATE}\% \times \textit{FE2\_VP6\_BITRATE}$

Note:
Default: 100
Attention:
Valid for CBR only

Definition at line 172 of file vp6_alpha.h.

#define FE2_VP6A_STREAM_PREBUFFER

Alias for FE2_VP6_STREAM_PREBUFFER.

Seconds of preload that are necessary before starting playback.

The buffer is used to maintain a consistent datarate and minimize playback interruption.

Note:
Default: 6
Attention:
Valid for CBR only

Definition at line 178 of file vp6_alpha.h.

#define FE2_VP6A_TEMPORAL_DOWN_WATERMARK

Alias for FE2_VP6_TEMPORAL_DOWN_WATERMARK.

Codec parameter for temporal down watermark percentage.

Specifies the percentage of the datarate buffer remaining below which the encoder is allowed to start dropping frames. Only used if FE2_VP6_TEMPORAL_RESAMPLING is enabled.

Note:
Default: 20
A larger percentage will make it more likely frames will be dropped to achieve the requested FE2_VP6_BITRATE. The converse is also true.

Definition at line 166 of file vp6_alpha.h.

#define FE2_VP6A_TEMPORAL_RESAMPLING

Alias for FE2_VP6_TEMPORAL_RESAMPLING.

Codec parameter for temporal resampling.

In particularly difficult regions, if enabled, the encoder will drop frames to achieve the target the data rate. The value of FE2_VP6_TEMPORAL_DOWN_WATERMARK determines the percentage of the datarate buffer below which the encoder is enabled to start dropping frames.

Note:
Default: Bits per pixel dependent
Attention:
Setting FE2_VP6_RC_MODE to CBR_1PASSControl or CBR_2PASSControl will unconditionally set this value to 1. In this case adjusting FE2_VP6_TEMPORAL_DOWN_WATERMARK may improve results.

Definition at line 160 of file vp6_alpha.h.

#define FE2_VP6A_UNDERSHOOT_PCT

Alias for FE2_VP6_UNDERSHOOT_PCT.

Codec parameter for undershoot percentage.

This value is given as a percentage. Creates output that targets a slightly lower datarate so there are bits available in the buffer to improve difficult sections.

Note:
Default: 90

Definition at line 132 of file vp6_alpha.h.


On2 Technologies, Inc Flix Engine Linux documentation, generated on Tue Nov 2 16:53:00 2010 by doxygen 1.5.5