NVIDIA DRIVE OS Linux API Reference

5.1.0.2 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
nvmedia_imgdec.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2016-2017, NVIDIA CORPORATION. All rights reserved. All
3  * information contained herein is proprietary and confidential to NVIDIA
4  * Corporation. Any use, reproduction, or disclosure without the written
5  * permission of NVIDIA Corporation is prohibited.
6  */
7 
15 #ifndef _NVMEDIA_IMGDEC_H
16 #define _NVMEDIA_IMGDEC_H
17 
18 #ifdef __cplusplus
19 extern "C" {
20 #endif
21 
22 #include "nvmedia_common.h"
23 #include "nvmedia_image.h"
24 
43 #define NVMEDIA_IMAGEDEC_VERSION_MAJOR 2
44 
45 #define NVMEDIA_IMAGEDEC_VERSION_MINOR 0
46 
50 typedef enum {
56 
60 typedef struct {
64  uint16_t width;
66  uint16_t height;
68  uint16_t maxReferences;
72 
83 #define NVMEDIA_IMAGE_DECODER_ATTRIBUTE_PROGRESSIVE_SEQUENCE (1<<0)
84 
90 #define NVMEDIA_IMAGE_DECODER_10BIT_DECODE (1<<1)
91 
97 #define NVMEDIA_IMAGE_DECODER_PIXEL_REC_2020 (1<<2)
98 
111  NvMediaVersion *version
112 );
113 
153  NvMediaDevice *device,
154  NvMediaImageCodec codec,
155  uint16_t width,
156  uint16_t height,
157  uint16_t maxReferences,
158  uint64_t maxBitstreamSize,
159  uint8_t inputBuffering,
160  uint32_t flags,
161  NvMediaDecoderInstanceId instanceId
162 );
163 
168 void
170  NvMediaImageDecoder *decoder
171 );
172 
199  NvMediaImageDecoder *decoder,
200  NvMediaImage *target,
201  NvMediaPictureInfo *pictureInfo,
202  uint32_t numBitstreamBuffers,
203  const NvMediaBitstreamBuffer *bitstreams,
204  NvMediaDecoderInstanceId instanceId
205 );
206 
207 /*
208  * \defgroup history_nvmedia_imgdec History
209  * Provides change history for the NvMedia Image Decode API.
210  *
211  * \section history_nvmedia_imgdec Version History
212  *
213  * <b> Version 1.0 </b> May 1, 2016
214  * - Initial release
215  *
216  * <b> Version 1.1 </b> May 27, 2016
217  * - Added \ref NvMediaImageDecoderCheckVersion API
218  *
219  * <b> Version 2.0 </b> May 9, 2017
220  * - Added instance ID parameter to \ref NvMediaImageDecoderCreate()
221  * and NvMediaImageDecoderRender()
222  * - Added NvMediaDevice parameter to NvMediaImageDecoderCreate()
223  * - NvMediaImageDecoderCheckVersion is now deprecated.
224  * Use NvMediaImageDecoderGetVersion() instead.
225  * - All NvMedia data types are moved to standard data types
226  */
229 #ifdef __cplusplus
230 }; /* extern "C" */
231 #endif
232 
233 #endif /* _NVMEDIA_IMGDEC_H */
uint16_t width
Decoder width.
A handle representing image objects.
Definition: nvmedia_image.h:75
uint16_t height
Decoder height.
Holds an application data buffer containing compressed video data.
int uint32_t width
NvMediaStatus NvMediaImageDecoderGetVersion(NvMediaVersion *version)
Checks the version compatibility for the NvMedia Image decoder library.
void NvMediaImageDecoderDestroy(NvMediaImageDecoder *decoder)
Destroys a image decoder object.
NvMediaDecoderInstanceId
Specifies the decoder instance ID.
NVIDIA Media Interface: Image Processing
NvMediaImageCodec
Image codec type.
Holds NvMedia Version information.
Definition: nvmedia_core.h:252
NVIDIA Media Interface: Common Types for Video/Image Encode/Decode
NvMediaDecoderInstanceId instanceId
Instance ID of the decoder.
NvMediaStatus
The set of all possible error codes.
Definition: nvmedia_core.h:199
int uint32_t uint32_t uint32_t const uint32_t const uint32_t const uint32_t const uint64_t uint32_t uint32_t flags
int uint32_t uint32_t height
uint16_t maxReferences
Maximum number of reference pictures.
void NvMediaDevice
An opaque handle representing a NvMediaDevice object.
Definition: nvmedia_core.h:305
void NvMediaPictureInfo
A generic "picture information" pointer type.
A handle representing a IMAGE decoder object.
NvMediaStatus NvMediaImageDecoderRender(NvMediaImageDecoder *decoder, NvMediaImage *target, NvMediaPictureInfo *pictureInfo, uint32_t numBitstreamBuffers, const NvMediaBitstreamBuffer *bitstreams, NvMediaDecoderInstanceId instanceId)
Decodes a compressed field/frame and render the result into a NvMediaImage.
NvMediaImageDecoder * NvMediaImageDecoderCreate(NvMediaDevice *device, NvMediaImageCodec codec, uint16_t width, uint16_t height, uint16_t maxReferences, uint64_t maxBitstreamSize, uint8_t inputBuffering, uint32_t flags, NvMediaDecoderInstanceId instanceId)
Creates a image decoder object.
NvMediaImageCodec codec
Codec type.