NVIDIA DRIVE OS Linux SDK API Reference

5.1.6.0 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
nvmedia_2d.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2013-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 
16 #ifndef NVMEDIA_2D_H
17 #define NVMEDIA_2D_H
18 
19 #ifdef __cplusplus
20 extern "C" {
21 #endif
22 
23 #include "nvmedia_core.h"
24 #include "nvmedia_image.h"
36 #define NVMEDIA_2D_VERSION_MAJOR 3
37 
38 #define NVMEDIA_2D_VERSION_MINOR 7
39 
40 
46 typedef enum
47 {
57 
127 typedef enum
128 {
148 
149 /*---------------------------------------------------------*/
159 typedef enum
160 {
170 
177 typedef struct
178 {
187  uint32_t validFields;
191  uint32_t flags;
199 
205 typedef struct
206 {
207  /* Reserved for future use. */
208  uint32_t reserved[8];
210 
220  NvMediaVersion *version
221 );
222 
226 typedef struct NvMedia2D NvMedia2D;
227 
235 NvMedia2D *
237  NvMediaDevice *device
238 );
239 
245 void
247  NvMedia2D *i2d
248 );
249 
297  const NvMedia2D *i2d,
298  NvMediaImage *dstSurface,
299  const NvMediaRect *dstRect,
300  NvMediaImage *srcSurface,
301  const NvMediaRect *srcRect,
302  const NvMedia2DBlitParameters *params,
303  NvMedia2DBlitParametersOut *paramsOut
304 );
305 
326  const NvMedia2D *i2d,
327  NvMediaImage *dstSurface,
328  uint32_t dstPlane,
329  NvMediaImage *srcSurface,
330  uint32_t srcPlane
331 );
332 
361  const NvMedia2D *i2d,
362  NvMediaImage *imageOdd,
363  NvMediaImage *imageEven,
364  NvMediaImage *outImage
365 );
366 
400  const NvMedia2D *i2d,
401  NvMediaImage *image,
402  NvMediaAccessMode accessMode
403 );
404 
428  const NvMedia2D *i2d,
429  NvMediaImage *image
430 );
431 
432 /*
433  * \defgroup history_nvmedia_2d History
434  * Provides change history for the NvMedia 2D API.
435  *
436  * \section history_nvmedia_2d Version History
437  *
438  * <b> Version 1.1 </b> February 1, 2016
439  * - Initial release
440  *
441  * <b> Version 1.2 </b> May 11, 2016
442  * - Added \ref NvMedia2DCheckVersion API
443  *
444  * <b> Version 1.3 </b> May 5, 2017
445  * - Removed compositing, blending and alpha related defines and structures
446  *
447  * <b> Version 2.0 </b> May 11, 2017
448  * - Deprecated NvMedia2DBlit API
449  * - Deprecated NvMedia2DCheckVersion API
450  * - Deprecated NvMedia2DColorStandard, NvMedia2DColorRange and
451  * NvMedia2DColorMatrix types
452  * - Added \ref NvMedia2DGetVersion API
453  *
454  * <b> Version 2.1 </b> May 17, 2017
455  * - Moved transformation to nvmedia_common.h
456  * - Renamed NvMedia2DTransform to \ref NvMediaTransform
457  *
458  * <b> Version 2.2 </b> September 4, 2018
459  * - Added deprecated warning message for \ref NvMedia2DCopyPlane,
460  * NvMedia2DWeave
461  * - Added APIs \ref NvMedia2DCopyPlaneNew, \ref NvMedia2DWeaveNew
462  *
463  * <b> Version 3.0 </b> October 30, 2018
464  * - Deprecated \ref NvMedia2DCopyPlane API
465  * - Deprecated \ref NvMedia2DWeave API
466  *
467  * <b> Version 3.1 </b> December 11, 2018
468  * - Fixed MISRA-C Rule 21.1 and 21.2 Violations
469  *
470  * <b> Version 3.2 </b> January 21, 2019
471  * - Moved \ref NvMediaTransform from nvmedia_common.h to this header
472  *
473  * <b> Version 3.3 </b> Feb 21, 2019
474  * - Changed \ref NvMedia2D type from void to struct
475  *
476  * <b> Version 3.4 </b> March 5, 2019
477  * - Fixed MISRA-C Rule 8.13 Violations
478  *
479  * <b> Version 3.5 </b> March 14, 2019
480  * - Removing NvMedia2DBlitFlags enum definition
481  * - updated \ref NvMedia2DBlitParametersOut structure definition
482  *
483  * <b> Version 3.6 </b> March 18, 2019
484  * - Added APIs \ref NvMedia2DImageRegister, \ref NvMedia2DImageUnRegister
485  *
486  * <b> Version 3.7 </b> March 22, 2019
487  * - Unnecessary header include nvmedia_common.h has been removed
488  */
491 #ifdef __cplusplus
492 }; /* extern "C" */
493 #endif
494 
495 #endif /* NVMEDIA_2D_H */
Specifies horizontal mirroring.
Definition: nvmedia_2d.h:138
Holds the additional parameters for a blit.
Definition: nvmedia_2d.h:177
Holds a handle representing image objects.
Definition: nvmedia_image.h:69
Specifies enable the best quality filtering.
Definition: nvmedia_2d.h:55
NvMediaTransform dstTransform
Holds destination transformation when NVMEDIA_2D_BLIT_PARAMS_DST_TRANSFORM is set.
Definition: nvmedia_2d.h:194
NvMedia2DStretchFilter filter
Holds the filter mode.
Definition: nvmedia_2d.h:189
Specifies rotation by 270 degrees.
Definition: nvmedia_2d.h:136
NVIDIA Media Interface: Image Processing
NvMediaAccessMode
Definition: nvmedia_core.h:288
Holds NvMedia version information.
Definition: nvmedia_core.h:226
Specifies rotation by 180 degrees.
Definition: nvmedia_2d.h:134
struct NvMediaDevice NvMediaDevice
An opaque handle representing an NvMediaDevice object.
Definition: nvmedia_core.h:337
NvMediaColorStandard colorStandard
Holds the color space conversion standard when NVMEDIA_2D_BLIT_PARAMS_COLOR_STD is set...
Definition: nvmedia_2d.h:197
NvMediaColorStandard
Defines color standards.
Definition: nvmedia_core.h:108
void NvMedia2DDestroy(NvMedia2D *i2d)
Destroys a 2D object.
Specifies enabling use of blit flags.
Definition: nvmedia_2d.h:164
Specifies disable the horizontal and vertical filtering.
Definition: nvmedia_2d.h:49
Specifies enabling use of color space conversion standard.
Definition: nvmedia_2d.h:168
NvMediaStatus NvMedia2DImageRegister(const NvMedia2D *i2d, NvMediaImage *image, NvMediaAccessMode accessMode)
Registers an NvMediaImage for use with an NvMedia2D handle.
NVIDIA Media Interface: Core
Specifies rotation by 90 degrees.
Definition: nvmedia_2d.h:132
NvMediaStatus
Defines all possible error codes.
Definition: nvmedia_core.h:169
Specifies mirroring along a diagonal axis from top right to bottom left of the rectangular region...
Definition: nvmedia_2d.h:141
NvMediaTransform
Defines transformations.
Definition: nvmedia_2d.h:127
NvMediaStatus NvMedia2DGetVersion(NvMediaVersion *version)
Returns the version information for the NvMedia 2D library.
uint32_t flags
Holds flags use to set NVMEDIA_2D_BLIT_PARAMS_FLAGS.
Definition: nvmedia_2d.h:191
NvMedia2DStretchFilter
Specifies filtering mode used for stretched blits.
Definition: nvmedia_2d.h:46
NvMedia2DBlitParamField
Defines bit masks for NvMedia2DBlitParameters::validFields.
Definition: nvmedia_2d.h:159
Holds a rectangular region of a surface.
Definition: nvmedia_core.h:133
Specifies no transformation.
Definition: nvmedia_2d.h:130
NvMediaStatus NvMedia2DCopyPlaneNew(const NvMedia2D *i2d, NvMediaImage *dstSurface, uint32_t dstPlane, NvMediaImage *srcSurface, uint32_t srcPlane)
Copies a plane of a YUV image to another YUV image.
NvMediaStatus NvMedia2DWeaveNew(const NvMedia2D *i2d, NvMediaImage *imageOdd, NvMediaImage *imageEven, NvMediaImage *outImage)
Performs an NvMedia2D weave operation on NvMedia images.
Holds additional values returned from a blit.
Definition: nvmedia_2d.h:205
NvMedia2D * NvMedia2DCreate(NvMediaDevice *device)
Creates a 2D object.
Specifies enable low quality filtering.
Definition: nvmedia_2d.h:51
Specifies enable use of stretch filter.
Definition: nvmedia_2d.h:162
NvMediaStatus NvMedia2DImageUnRegister(const NvMedia2D *i2d, NvMediaImage *image)
Unregisters an NvMediaImage registered with NvMedia2D by a call to NvMedia2DImageRegister().
NvMediaStatus NvMedia2DBlitEx(const NvMedia2D *i2d, NvMediaImage *dstSurface, const NvMediaRect *dstRect, NvMediaImage *srcSurface, const NvMediaRect *srcRect, const NvMedia2DBlitParameters *params, NvMedia2DBlitParametersOut *paramsOut)
Performs a 2D blit operation with supplementary return values.
struct NvMedia2D NvMedia2D
An opaque handle representing an NvMedia2D object.
Definition: nvmedia_2d.h:226
Specifies vertical mirroring.
Definition: nvmedia_2d.h:143
Specifies mirroring along a diagonal axis from top left to bottom right of the rectangular region...
Definition: nvmedia_2d.h:146
uint32_t validFields
Holds flags which determine which fields in this structure are used.
Definition: nvmedia_2d.h:187
Specifies enabling use of destination transform.
Definition: nvmedia_2d.h:166
Specifies enable media quality filtering.
Definition: nvmedia_2d.h:53