Skip to content

Commit e844e5b

Browse files
committed
Update headers from Video SDK 13.0
1 parent 9934f17 commit e844e5b

File tree

5 files changed

+237
-73
lines changed

5 files changed

+237
-73
lines changed

README

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
FFmpeg version of headers required to interface with Nvidias codec APIs.
22

3-
Corresponds to Video Codec SDK version 12.0.16.
3+
Corresponds to Video Codec SDK version 13.0.19.
44

55
Minimum required driver versions:
6-
Linux: 550.54.14 or newer
7-
Windows: 551.76 or newer
6+
Linux: 570.0 or newer
7+
Windows: 570.0 or newer

ffnvcodec.pc.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ includedir=${prefix}/include
33

44
Name: ffnvcodec
55
Description: FFmpeg version of Nvidia Codec SDK headers
6-
Version: 12.2.72.1
6+
Version: 13.0.19.0
77
Cflags: -I${includedir}

include/ffnvcodec/dynlink_cuviddec.h

Lines changed: 31 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@
4040
#endif
4141
#endif
4242

43-
#define NVDECAPI_MAJOR_VERSION 12
44-
#define NVDECAPI_MINOR_VERSION 2
43+
#define NVDECAPI_MAJOR_VERSION 13
44+
#define NVDECAPI_MINOR_VERSION 0
4545

4646
#define NVDECAPI_VERSION (NVDECAPI_MAJOR_VERSION | (NVDECAPI_MINOR_VERSION << 24))
4747

@@ -97,6 +97,9 @@ typedef enum cudaVideoSurfaceFormat_enum {
9797
cudaVideoSurfaceFormat_YUV444=2, /**< Planar YUV [Y plane followed by U and V planes] */
9898
cudaVideoSurfaceFormat_YUV444_16Bit=3, /**< 16 bit Planar YUV [Y plane followed by U and V planes].
9999
Can be used for 10 bit(6LSB bits 0), 12 bit (4LSB bits 0) */
100+
cudaVideoSurfaceFormat_NV16=4, /**< Semi-Planar YUV 422 [Y plane followed by interleaved UV plane] */
101+
cudaVideoSurfaceFormat_P216=5 /**< 16 bit Semi-Planar YUV 422[Y plane followed by interleaved UV plane].
102+
Can be used for 10 bit(6LSB bits 0), 12 bit (4LSB bits 0) */
100103
} cudaVideoSurfaceFormat;
101104

102105
/******************************************************************************************************************/
@@ -320,10 +323,10 @@ typedef struct _CUVIDH264PICPARAMS
320323
int delta_pic_order_always_zero_flag;
321324
int frame_mbs_only_flag;
322325
int direct_8x8_inference_flag;
323-
int num_ref_frames; // NOTE: shall meet level 4.1 restrictions
326+
int num_ref_frames;
324327
unsigned char residual_colour_transform_flag;
325-
unsigned char bit_depth_luma_minus8; // Must be 0 (only 8-bit supported)
326-
unsigned char bit_depth_chroma_minus8; // Must be 0 (only 8-bit supported)
328+
unsigned char bit_depth_luma_minus8;
329+
unsigned char bit_depth_chroma_minus8;
327330
unsigned char qpprime_y_zero_transform_bypass_flag;
328331
// PPS
329332
int entropy_coding_mode_flag;
@@ -344,7 +347,7 @@ typedef struct _CUVIDH264PICPARAMS
344347
int frame_num;
345348
int CurrFieldOrderCnt[2];
346349
// DPB
347-
CUVIDH264DPBENTRY dpb[16]; // List of reference frames within the DPB
350+
CUVIDH264DPBENTRY dpb[16]; // List of reference frames within the DPB
348351
// Quantization Matrices (raster-order)
349352
unsigned char WeightScale4x4[6][16];
350353
unsigned char WeightScale8x8[2][64];
@@ -359,7 +362,10 @@ typedef struct _CUVIDH264PICPARAMS
359362
unsigned long long slice_group_map_addr;
360363
const unsigned char *pMb2SliceGroupMap;
361364
} fmo;
362-
unsigned int Reserved[12];
365+
unsigned int mb_adaptive_frame_field_flag : 2; // bit 0 represent SPS flag mb_adaptive_frame_field_flag
366+
// if bit 1 is not set, flag is ignored. Bit 1 is set to maintain backward compatibility
367+
unsigned int Reserved1 : 30;
368+
unsigned int Reserved[11];
363369
// SVC/MVC
364370
union
365371
{
@@ -487,7 +493,24 @@ typedef struct _CUVIDVC1PICPARAMS
487493
/***********************************************************/
488494
typedef struct _CUVIDJPEGPICPARAMS
489495
{
490-
int Reserved;
496+
unsigned char numComponents;
497+
unsigned char bitDepth;
498+
unsigned char quantizationTableSelector[4];
499+
unsigned int scanOffset[4];
500+
unsigned int scanSize[4];
501+
502+
unsigned short restartInterval;
503+
unsigned char componentIdentifier[4];
504+
505+
unsigned char hasQMatrix;
506+
unsigned char hasHuffman;
507+
unsigned short quantvals[4][64];
508+
509+
unsigned char bits_ac[4][16];
510+
unsigned char table_ac[4][256]; // there can only be max of 162 ac symbols
511+
512+
unsigned char bits_dc[4][16];
513+
unsigned char table_dc[4][256]; // there can only be max of 12 dc symbols
491514
} CUVIDJPEGPICPARAMS;
492515

493516

include/ffnvcodec/dynlink_nvcuvid.h

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -502,8 +502,11 @@ typedef struct _CUVIDPARSERPARAMS
502502
IN: call pfnDecodePicture even if picture bitstream is fully corrupted) */
503503
unsigned int ulMaxDisplayDelay; /**< IN: Max display queue delay (improves pipelining of decode with display)
504504
0=no delay (recommended values: 2..4) */
505-
unsigned int bAnnexb : 1; /**< IN: AV1 annexB stream */
506-
unsigned int uReserved : 31; /**< Reserved for future use - set to zero */
505+
unsigned int bAnnexb : 1; /**< IN: AV1 annexB stream */
506+
unsigned int bMemoryOptimize : 1; /**< IN: Utilize minimum picIdx from dpb to allow memory saving at the
507+
decoder layer, use cuvidReconfigureDecoder() to increase the
508+
decode surfaces if needed (perf may get impacted) */
509+
unsigned int uReserved : 30; /**< Reserved for future use - set to zero */
507510
unsigned int uReserved1[4]; /**< IN: Reserved for future use - set to 0 */
508511
void *pUserData; /**< IN: User data for callbacks */
509512
PFNVIDSEQUENCECALLBACK pfnSequenceCallback; /**< IN: Called before decoding frames and/or whenever there is a fmt change */

0 commit comments

Comments
 (0)