[FFmpeg-devel] [PATCH] add encode options to libvpxenc
James Zern
jzern
Thu May 20 03:38:45 CEST 2010
On Wed, May 19, 2010 at 17:51, Alexander Strange <astrange at ithinksw.com> wrote:
>
> On May 19, 2010, at 2:39 PM, James Zern wrote:
>
>> As mentioned in '[PATCH] VP8 de/encode via libvpx' this patch adds
>> fuller option support to libvpxenc. An attempt was made to try to
>> minimize new options, but in those cases some of the mappings may be
>> incorrect.
>> <avcodec-AVCodecContext_add_VP8_specifics.diff>
>
>> + ? ?/**
>> + ? ? * Enable spatial resampling
>> + ? ? *
>> + ? ? * Spatial resampling allows the codec to compress a lower resolution
>> + ? ? * version of the frame, which is then upscaled by the encoder to the
>> + ? ? * correct presentation resolution. This increases visual quality at low
>> + ? ? * data rates, at the expense of CPU time on the encoder/decoder.
>> + ? ? * - encoding: Set by user.
>> + ? ? * - decoding: unused
>> + ? ? *
>> + ? ? * ?\attention VP8 specific
>> + ? ? */
>> + ? ?int spatial_rsmpl;
>
>
> Is this a boolean? If so, it could go in CODEC_FLAGS2.
> I remember Xvid supported this once, but it seems like it was never exposed here.
>
> I think "resample" is better than "rsmpl".
>
Yes it is a boolean, so if it fits better there I can look into that.
The naming change is fine as it was produced after a cursory
inspection of other available options and an attempt at some of their
abbreviation.
>> + ? ? * Spatial resampling up watermark.
>> + ? ? * Spatial resampling down watermark.
>
> "watermark" made me think it had to do with watermarking.
> Maybe "high-water mark" and "low-water mark"?
> Of course, matching the library documentation is probably the most important thing here.
>
Most of the lines do come from the SDK, but this is all iterative, so
it if helps convey the meaning then I'm fine changing it.
>> + ? ? * Two-pass mode CBR/VBR bias.
>
> This sounds like bit_rate_tolerance (x264 ratetol).
>
>> + ? ? * Bias, expressed on a scale of 0 to 100, for determining target size for
>> + ? ? * the current frame. The value 0 indicates the optimal CBR mode value
>> + ? ? * should be used. The value 100 indicates the optimal VBR mode value
>> + ? ? * should be used. Values in between indicate which way the encoder should
>> + ? ? * "lean." RC mode bias between CBR and VBR(0-100: 0->CBR, 100->VBR)
>
>
> The last sentence doesn't fit the rest of it.
>
>> + ? ? * Allow lagged encoding.
>
> This is rc_lookahead.
>
OK. This came in after the initial internal add so I didn't keep a
good eye on what was available.
>> + ? ? * Control sharpness preprocessing
>> + ? ? *
>> + ? ? * 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.
>> + ? ? * Valid Range: [0,7]
>
> The documentation mostly uses noun phrases "level of sharpness preprocessing" instead of "control sharpness preprocessing".
> "Valid Range" should be a sentence.
>
>> + ? ? * Allow encoder to automatically set and use alternate reference frame.
>
> "the".
> Is this a boolean? Maybe it can be a codec flag too if so.
>
Yes boolean again.
>> + ? ? * Set the max number of frames blurred creating the alternate reference frame.
>
> "when creating"
>
>> + ? ? * Set the type of filter to use for the alternate reference frame.
>
> What are the filter types?
>
>> + ? ? * Set the filter strength for the alternate reference frame.
>
> What are the range of values?
>
>> + ? ? * Set the threshold for macroblocks treated as static.
>
> Same.
>
More docs to update, will get back on this.
More information about the ffmpeg-devel
mailing list