DivXNetworks, Inc.
Main Page | Namespace List | Data Structures | Directories | File List | Namespace Members | Data Fields | Globals | Related Pages

API documentation

Introduction

This documentation describes the DivX Codec's native API. There are two main parts to this document:

As a prerequisite, it is recommended that the reader is familiar with encoding and decoding DivX video using an application such as Virtual Dub.

General

Re-entrancy and Multithreading Considerations

The DivX codec is fully re-entrant allowing multiple encoder and decoder instance within the same executable environment. It has no concept of SMP or multithreading so calls to any particular encoder or decoder instance must be serialized by the caller (e.g. using a mutex or critical section).

Decoder Operation

The DivX decoder has a C-language API. It can therefore be accessed by C or C++ calling code. The API comprises one header file:

This header file is dependent on three other header files in the SDK.

The first step of decoding is to find an appropriate decoder for the job. There are multiple decoders within the DivX codec, each designed for a different compressed format. A call to getDecore() will return a pointer to a "decore" function designed for the specified source format.

See the documentation of LibQDecoreFunction for example usage of the decoder API.

Encoder Operation

The DivX encoder has a C++ API. It can be used by C++ calling code. The API comprises three header files:

EncoderInterface.h

These are dependent on these further SDK header files:

The first step of encoding is to create an encoder instance using EncoderInterface::create(). Note that the object created by this function must later be destroyed by calling EncoderInterface::destroy().

Encoder settings are handled via a separate API. See the documentation of the Settings interface for more information.

See the documentation of EncoderInterface for example usage of the encoder API.


Generated on Tue Jan 24 16:43:33 2006 for DivX Codec API Documentation.