NVIDIA DRIVE OS Linux SDK API Reference

5.2.6 Release
For Test and Development only
nvmedia_common.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2017-2019 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 
8 
17 #ifndef NVMEDIA_COMMON_H
18 #define NVMEDIA_COMMON_H
19 
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23 
24 #include "nvmedia_core.h"
25 
35 #include "nvmedia_common_decode.h"
36 #include "nvmedia_common_encode.h"
37 
39 #define NVMEDIA_COMMON_VERSION_MAJOR 1
40 
41 #define NVMEDIA_COMMON_VERSION_MINOR 29
42 
43 
46 typedef enum {
54 
66 #define NVMEDIA_DISP_ATTR_COMPOSITION (1<<6)
67 
71 #define NVMEDIA_DISP_ATTR_SET_DEPTH (1<<7)
72 
76 #define NVMEDIA_DISP_ATTR_SET_POSITION (1<<8)
77 
83 typedef enum {
93 
97 typedef struct {
109  uint32_t depth;
115 
118 typedef enum {
134 
137 /*
138  * \defgroup history_nvmedia_common History
139  * Provides change history for the NvMedia Common Types.
140  *
141  * \section history_nvmedia_common Version History
142  *
143  * <b> Version 1.0 </b> March 21, 2017
144  * - Initial release
145  *
146  * <b> Version 1.1 </b> April 18, 2017
147  * - Added \ref NvMediaDecoderInstanceId enum and
148  * \ref NvMediaEncoderInstanceId enum
149  * - Changed to use standard data types
150  * - Removed input surface rotation and mirroring enumerations and members from
151  * \ref NvMediaEncodeInitializeParamsH264 and \ref NvMediaEncodeInitializeParamsH265
152  *
153  * <b> Version 1.2 </b> May 4, 2017
154  * - Added SLICE_LEVEL_OUTPUT, RTP_MODE_OUTPUT, EXT_PIC_RC_HINT, DYNAMIC_RPS,
155  * MV_BUFFER_DUMP and RECON_CRC features for \ref NvMediaEncodeH264Features
156  * and \ref NvMediaEncodeH265Features
157  * - Add bConstFrameQP parameter in \ref NvMediaEncodeRCParams.
158  * - Add NvMediaEncAttrType enum and NvMediaNalData data structure.
159  *
160  * <b> Version 1.3 </b> May 8, 2017
161  * - Added \ref numMacroblocksPerSlice in \ref NvMediaEncodeConfigH264
162  * and \ref numCTUsPerSlice in \ref NvMediaEncodeConfigH265.
163  *
164  * <b> Version 1.4 </b> May 10, 2017
165  * - Added LOOP_FILTER_PARAMS, QUANTIZATION_PARAMS, TRANSFORM_MODE, HIGH_PRECISION_MV
166  * and ERROR_RESILIENT features in \ref NvMediaEncodeVP9Features.
167  * - Added filter_type, filter_level, sharpness_level, ref_lf_deltas, mode_lf_deltas,
168  * bmode_ref_lf_delta_enabled, bmode_ref_lf_delta_update, base_qindex, delta_y_dc_q,
169  * delta_uv_dc, delta_uv_ac, transform_mode, high_prec_mv and error_resilient
170  * parameters in \ref NvMediaEncodeConfigVP9.
171  *
172  * <b> Version 1.5 </b> May 17, 2017
173  * - Added display_attributes enum defines
174  * - Added \ref NvMediaDispCompMode and \ref NvMediaDispAttributes
175  *
176  * <b> Version 1.6 </b> May 18, 2017
177  * - Added NvMediaTransform enum defines
178  *
179  * <b> Version 1.7 </b> June 05, 2017
180  * - Add \ref bSliceDecEnable and \ref NvMediaSliceDecodeData structure member in
181  * \ref NvMediaPictureInfoH265 structure.
182  *
183  * <b> Version 1.8 </b> June 07, 2017
184  * - Added \ref NvMediaEncodeH264POCType enum for H.264 pic_order_cnt_type.
185  * The support is added for pic_order_cnt_type 0 and 2. pic_order_cnt_type 1 is not
186  * not supported.
187  * - Added variable pocType of type \ref NvMediaEncodeH264POCType in \ref NvMediaEncodeConfigH264.
188  *
189  * <b> Version 1.9 </b> June 09, 2017
190  * -Added PROFILING feature in \ref NvMediaEncodeH264Features,
191  * \ref NvMediaEncodeH265Features and \ref NvMediaEncodeVP9Features.
192  *
193  * <b> Version 1.10 </b> June 09, 2017
194  * - Removed RECON_CRC features from \ref NvMediaEncodeH264Features
195  * and \ref NvMediaEncodeH265Features and added it as enableReconCRC
196  * for \ref NvMediaEncodeInitializeParamsH264 and \ref
197  * NvMediaEncodeInitializeParamsH265.
198  * - Added enableMVC, enableROIEncode and enableSliceEncode
199  * in \ref NvMediaEncodeInitializeParamsH264 and \ref
200  * NvMediaEncodeInitializeParamsH265.
201  *
202  * <b> Version 1.11 </b> June 22, 2017
203  * -Added levelTier parameter in \ref NvMediaEncodeInitializeParamsH265
204  * Added initQP, maxQP parameters in \ref NvMediaEncodeConfigH264,
205  * \ref NvMediaEncodeConfigH265 and \ref NvMediaEncodeConfigVP9.
206  *
207  * <b> Version 1.12 </b> June 29, 2017
208  * -Added feature in \ref NvMediaEncodeH264Features and \ref NvMediaEncodeH265Features,
209  * to enable 4 byte start code.
210  *
211  * <b> Version 1.13</b> June 30, 2017
212  * -Added HEVC MV interface members in \ref NvMediaPictureInfoH265 structure
213  *
214  * <b> Version 1.14</b> July 26, 2017
215  * -Added enableWeightedPrediction in \ref NvMediaEncodeConfigH264 structure *
216  *
217  * <b> Version 1.15</b> Sept 1, 2017
218  * -Added NvMediaEncodeVP8Features, NvMediaEncodeConfigVP8, NvMediaEncodeInitializeParamsVP8
219  * and NvMediaEncodePicParamsVP8 structures *
220  *
221  * <b> Version 1.16 </b> Sept 13, 2017
222  * -Added frameRateNum and frameRateDen parameters in \ref NvMediaEncodePicParamsVP8
223  *
224  * <b> Version 1.17 </b> Oct 26, 2017
225  * -Added useBFramesAsRef parameter in \ref NvMediaEncodeInitializeParamsH264
226  * and \ref NvMediaEncodeInitializeParamsH265
227  *
228  * <b> Version 1.18 </b> Nov 6, 2017
229  * - Added enableTwoPassRC and enableSourceHalfScaled for \ref NvMediaEncodeInitializeParamsH264 and
230  * \ref NvMediaEncodeInitializeParamsH265.
231  *
232  * <b> Version 1.19 </b> Nov 24, 2017
233  * - Added mvNumViews for \ref NvMediaEncodeInitializeParamsH265 and viewId for
234  * \ref NvMediaEncodePicParamsH265. Added mvcNumViews for \ref NvMediaEncodeInitializeParamsH264
235  * and viewId for \ref NvMediaEncodePicParamsH264.
236  *
237  * <b> Version 1.20 </b> March 16, 2018
238  * - Added \ref NvMediaNoiseReductionAlgorithm structure
239  *
240  * <b> Version 1.21 </b> October 4, 2018
241  * - Added Ultrafast encoding support for H.264 for platforms >=T194 in
242  * \ref NvMediaEncodeH264Features
243  *
244  * <b> Version 1.22 </b> October 29, 2018
245  * - Added enableExternalPictureRC in \ref NvMediaEncodeInitializeParamsH264
246  * and \ref NvMediaEncodeInitializeParamsH265
247  *
248  * <b> Version 1.23 </b> Dec 14, 2018
249  * - Defined Macro constants as unsigned to fix MISRA issues
250  * - Fix MISRA violations 21.1 and 21.2
251  *
252  * <b> Version 1.24 </b> Jan 02, 2019
253  * - Added enableAllIFrames in \ref NvMediaEncodeInitializeParamsH264
254  * and \ref NvMediaEncodeInitializeParamsH265
255  *
256  * <b> Version 1.25 </b> Jan 21, 2019
257  * - Moved \ref NvMediaTransform to nvmedia_2d.h
258  *
259  * <b> Version 1.26 </b> Feb 6, 2019
260  * - Deprecated the following display attributes \ref NVMEDIA_DISP_ATTR_BRIGHTNESS,
261  * \ref NVMEDIA_DISP_ATTR_COLOR_STANDARD, \ref NVMEDIA_DISP_ATTR_SATURATION,
262  * \ref NVMEDIA_DISP_ATTR_HUE, \ref NVMEDIA_DISP_ATTR_CONTRAST, \ref NVMEDIA_DISP_ATTR_LIMITED_RGB
263  * - Deprecated parameters brightness, hue, saturation, contrast, limitedRGB and
264  * colorStandard from \ref NvMediaDispAttributes
265  *
266  * <b> Version 1.27 </b> March 26, 2019
267  * - Added \ref NvMediaContentLightLevelInfo structure
268  *
269  * <b> Version 1.28 </b> April 4, 2019
270  * - Deprecate NVMEDIA_MIN_CAPTURE_FRAME_BUFFERS, NVMEDIA_MAX_CAPTURE_FRAME_BUFFERS
271  *
272  * <b> Version 1.29 </b> July 5, 2019
273  * - Moved Encode structures to nvmedia_common_encode.h
274  * - Moved Decode structures to nvmedia_common_decode.h
275  */
276 
277 
278 #ifdef __cplusplus
279 }; /* extern "C" */
280 #endif
281 
282 #endif /* NVMEDIA_COMMON_H */
NVMEDIA_FILTER_QUALITY_HIGH
@ NVMEDIA_FILTER_QUALITY_HIGH
High filter quality.
Definition: nvmedia_common.h:52
NVMEDIA_DISP_COMP_MODE_SRC_ALPHA
@ NVMEDIA_DISP_COMP_MODE_SRC_ALPHA
A lower depth overlay is per-pixel alpha blended over any higher depth overlay.
Definition: nvmedia_common.h:88
NVMEDIA_DISP_COMP_MODE_OPAQUE
@ NVMEDIA_DISP_COMP_MODE_OPAQUE
A lower depth overlay is fully covering any higher depth overlay.
Definition: nvmedia_common.h:85
NVMEDIA_NOISE_REDUCTION_ALGORITHM_INDOOR_LOW_LIGHT
@ NVMEDIA_NOISE_REDUCTION_ALGORITHM_INDOOR_LOW_LIGHT
Noise reduction algorithm for indoor low light condition.
Definition: nvmedia_common.h:128
NvMediaDispAttributes::position
NvMediaRect position
The rectangle where the video renders.
Definition: nvmedia_common.h:113
NvMediaDispAttributes::depth
uint32_t depth
Holds a positive value (up to 255) that specifies the video displays relative to the top-most layer.
Definition: nvmedia_common.h:109
NvMediaDispCompMode
NvMediaDispCompMode
Specifies composition modes for layers.
Definition: nvmedia_common.h:83
NVMEDIA_NOISE_REDUCTION_ALGORITHM_ORIGINAL
@ NVMEDIA_NOISE_REDUCTION_ALGORITHM_ORIGINAL
Original (default) noise reduction algorithm.
Definition: nvmedia_common.h:120
NvMediaFilterQuality
NvMediaFilterQuality
Defines filter quality levels.
Definition: nvmedia_common.h:46
NVMEDIA_FILTER_QUALITY_LOW
@ NVMEDIA_FILTER_QUALITY_LOW
Low (default) filter quality.
Definition: nvmedia_common.h:48
NVMEDIA_NOISE_REDUCTION_ALGORITHM_INDOOR_MEDIUM_LIGHT
@ NVMEDIA_NOISE_REDUCTION_ALGORITHM_INDOOR_MEDIUM_LIGHT
Noise reduction algorithm for indoor medium light condition.
Definition: nvmedia_common.h:130
NvMediaRect
Holds a rectangular region of a surface.
Definition: nvmedia_core.h:133
nvmedia_core.h
NVIDIA Media Interface: Core
NVMEDIA_DISP_COMP_MODE_PREMULTI_SRC_ALPHA
@ NVMEDIA_DISP_COMP_MODE_PREMULTI_SRC_ALPHA
A lower depth overlay is per-pixel alpha blended over any higher depth overlay.
Definition: nvmedia_common.h:91
NvMediaNoiseReductionAlgorithm
NvMediaNoiseReductionAlgorithm
Noise Reduction Algorithm.
Definition: nvmedia_common.h:118
NVMEDIA_NOISE_REDUCTION_ALGORITHM_OUTDOOR_LOW_LIGHT
@ NVMEDIA_NOISE_REDUCTION_ALGORITHM_OUTDOOR_LOW_LIGHT
Noise reduction algorithm for outdoor low light condition.
Definition: nvmedia_common.h:122
NVMEDIA_NOISE_REDUCTION_ALGORITHM_OUTDOOR_MEDIUM_LIGHT
@ NVMEDIA_NOISE_REDUCTION_ALGORITHM_OUTDOOR_MEDIUM_LIGHT
Noise reduction algorithm for outdoor medium light condition.
Definition: nvmedia_common.h:124
NVMEDIA_NOISE_REDUCTION_ALGORITHM_INDOOR_HIGH_LIGHT
@ NVMEDIA_NOISE_REDUCTION_ALGORITHM_INDOOR_HIGH_LIGHT
Noise reduction algorithm for indoor high light condition.
Definition: nvmedia_common.h:132
nvmedia_common_decode.h
NVIDIA Media Interface: Common Types for Video/Image Decode
NVMEDIA_FILTER_QUALITY_MEDIUM
@ NVMEDIA_FILTER_QUALITY_MEDIUM
Medium filter quality.
Definition: nvmedia_common.h:50
nvmedia_common_encode.h
NVIDIA Media Interface: Common Types for Video/Image Encode
NVMEDIA_NOISE_REDUCTION_ALGORITHM_OUTDOOR_HIGH_LIGHT
@ NVMEDIA_NOISE_REDUCTION_ALGORITHM_OUTDOOR_HIGH_LIGHT
Noise reduction algorithm for outdoor high light condition.
Definition: nvmedia_common.h:126
NvMediaDispAttributes
Holds NvMedia display attributes.
Definition: nvmedia_common.h:97
NvMediaDispAttributes::compositionMode
NvMediaDispCompMode compositionMode
Defines the composition mode for the layer.
Definition: nvmedia_common.h:104