16.01.2015 Views

NVIDIA CUDA VIDEO ENCODER - CUDA Toolkit Documentation

NVIDIA CUDA VIDEO ENCODER - CUDA Toolkit Documentation

NVIDIA CUDA VIDEO ENCODER - CUDA Toolkit Documentation

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>ENCODER</strong> INTERFACES<br />

C-LIBRARY<br />

API<br />

The <strong>NVIDIA</strong> <strong>CUDA</strong> Video Encoder is also exposed as a C-library interface (API) to<br />

application. Following sections describe this API and different related structures in<br />

depth. Application programmer needs to be aware that the actual encoding APIs of this<br />

library have asynchronous operation to facilitate better utilization of CPU and GPU<br />

resources. The feedback mechanism to the application is through the callback functions<br />

that the application provides to the library at start of operation. See API Callback on<br />

page 24 section to find more details on callback mechanism.<br />

API Function Interface<br />

Table4.<br />

C-library API Functions<br />

Methods<br />

NvGetHWEncodeCaps<br />

NVCreateEncoder<br />

NVIsSupportedCodec<br />

NVIsSupportedCodecProfile<br />

NVSetCodec<br />

NVGetCodec<br />

NVIsSupportedParam<br />

NVSetParamValue<br />

NVGetParamValue<br />

NVSetDefaultParam<br />

NVCreateHWEncoder<br />

NVGetSPSPPS<br />

NVEncodeFrame<br />

NVRegisterCB<br />

NVDestroyEncoder<br />

Description<br />

Query if the GPU supports the <strong>NVIDIA</strong> <strong>CUDA</strong> Video encoder<br />

Creates the <strong>NVIDIA</strong> <strong>CUDA</strong> Video Encoder library object for<br />

encoding<br />

Query if the codec format is supported<br />

Query if the codec profile is supported<br />

Set the type of compression codec<br />

Get the type of compression codec<br />

Query if the parameter type is supported<br />

Set the value of the specified parameter type<br />

Get the value of the specified parameter type<br />

Applies default settings of the encoding format<br />

Allocate hardware resources for the encoder<br />

Fetches the buffer containing SPS and PPS<br />

Encode one video picture<br />

Register user defined callback functions to the encoder<br />

Releases the <strong>NVIDIA</strong> encoder object<br />

<strong>NVIDIA</strong> <strong>CUDA</strong> <strong>VIDEO</strong> <strong>ENCODER</strong> SP04456-001_v03 | 15

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!