-
Notifications
You must be signed in to change notification settings - Fork 18
ref_iface_IVDXVideoDecoder_GetDecodePadding
VirtualDub Plugin SDK 1.2
IVDXVideoDecoder interface
Returns the amount of padding at the end of samples required by the decoder.
uint32 GetDecodePadding();
This method is not thread-safe.
Errors may not be returned from this function (see SetError()).
The number of bytes of padding to be added to the sample buffer beyond the data length. Generally, this should be a small number, around 16 bytes or less.
Padding at the end of a sample makes it easier for some types of
decoders, especially those that deal with bit encodings. For instance,
it is common for decoders that read variable length codes (VLC) to read
up to three bytes beyond the end of the coded stream. A small amount of
padding can make such decoders more efficient by not requiring onerous
bounds checking code. For instance, a 1024 byte sample would arrive at
the bottom of a 1028 byte buffer if GetDecodePadding() returned 4.
However, some checking must still be implemented to avoid crashing on
bad data.
Every sample that is buffered in the host is enlarged by this amount, so it is best not to request large amounts of padding. Requesting 1K of padding for each sample, for instance, could result in a substantial amount of extra memory being allocated.
The amount of padding must always be the same for a particular decoder object.
Copyright (C) 2007-2012 Avery Lee.
Setting up your development environment
Conventions
Plugin initialization
Dynamic loading
Reference counting
Using CPU extensions
Introduction
What's new
Breaking changes
Gotchas
Deprecated features
Migrating from the old Filter SDK
Programming model
Handling bitmaps
Creating a video filter
Setting filter parameters
Processing video frames
Managing filter data
Creating time-varying filters
Handling aspect ratio
Prefetching multiple source frames
Handling multiple sources
Making a filter configurable
Scripting support
CPU dependent optimization
VDXA index omitted
Getting started
Writing the module entry point
Creating a video filter
Adding configurability
Adding script support
Introduction
What's new
Autodetect
Direct mode
Video frames vs. samples
Video decodint model
Video decoder