Skip to content

Commit 3b04dc4

Browse files
committed
Import version 7.1.9
1 parent aeb1190 commit 3b04dc4

File tree

1 file changed

+48
-15
lines changed

1 file changed

+48
-15
lines changed

nvEncodeAPI.h

Lines changed: 48 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ typedef void* NV_ENC_OUTPUT_PTR; /**< NVENCODE API output buffer*/
108108
typedef void* NV_ENC_REGISTERED_PTR; /**< A Resource that has been registered with NVENCODE API*/
109109

110110
#define NVENCAPI_MAJOR_VERSION 7
111-
#define NVENCAPI_MINOR_VERSION 0
111+
#define NVENCAPI_MINOR_VERSION 1
112112

113113
#define NVENCAPI_VERSION (NVENCAPI_MAJOR_VERSION | (NVENCAPI_MINOR_VERSION << 24))
114114

@@ -251,13 +251,16 @@ typedef enum _NV_ENC_PARAMS_RC_MODE
251251
NV_ENC_PARAMS_RC_CONSTQP = 0x0, /**< Constant QP mode */
252252
NV_ENC_PARAMS_RC_VBR = 0x1, /**< Variable bitrate mode */
253253
NV_ENC_PARAMS_RC_CBR = 0x2, /**< Constant bitrate mode */
254-
NV_ENC_PARAMS_RC_VBR_MINQP = 0x4, /**< Variable bitrate mode with MinQP */
255-
NV_ENC_PARAMS_RC_2_PASS_QUALITY = 0x8, /**< Multi pass encoding optimized for image quality and works only with low latency mode */
256-
NV_ENC_PARAMS_RC_2_PASS_FRAMESIZE_CAP = 0x10, /**< Multi pass encoding optimized for maintaining frame size and works only with low latency mode */
257-
NV_ENC_PARAMS_RC_2_PASS_VBR = 0x20 /**< Multi pass VBR */
254+
NV_ENC_PARAMS_RC_CBR_LOWDELAY_HQ = 0x8, /**< low-delay CBR, high quality */
255+
NV_ENC_PARAMS_RC_CBR_HQ = 0x10, /**< CBR, high quality (slower) */
256+
NV_ENC_PARAMS_RC_VBR_HQ = 0x20 /**< VBR, high quality (slower) */
258257
} NV_ENC_PARAMS_RC_MODE;
259258

260-
#define NV_ENC_PARAMS_RC_CBR2 NV_ENC_PARAMS_RC_CBR /**< Deprecated */
259+
#define NV_ENC_PARAMS_RC_VBR_MINQP (NV_ENC_PARAMS_RC_MODE)0x4 /**< Deprecated */
260+
#define NV_ENC_PARAMS_RC_2_PASS_QUALITY NV_ENC_PARAMS_RC_CBR_LOWDELAY_HQ /**< Deprecated */
261+
#define NV_ENC_PARAMS_RC_2_PASS_FRAMESIZE_CAP NV_ENC_PARAMS_RC_CBR_HQ /**< Deprecated */
262+
#define NV_ENC_PARAMS_RC_2_PASS_VBR NV_ENC_PARAMS_RC_VBR_HQ /**< Deprecated */
263+
#define NV_ENC_PARAMS_RC_CBR2 NV_ENC_PARAMS_RC_CBR /**< Deprecated */
261264

262265
/**
263266
* Input picture structure
@@ -1263,15 +1266,47 @@ typedef struct _NV_ENC_CONFIG_HEVC
12631266
void* reserved2[64]; /**< [in]: Reserved and must be set to NULL */
12641267
} NV_ENC_CONFIG_HEVC;
12651268

1269+
/**
1270+
* \struct _NV_ENC_CONFIG_H264_MEONLY
1271+
* H264 encoder configuration parameters for ME only Mode
1272+
*
1273+
*/
1274+
typedef struct _NV_ENC_CONFIG_H264_MEONLY
1275+
{
1276+
uint32_t disablePartition16x16 :1; /**< [in]: Disable MotionEstimation on 16x16 blocks*/
1277+
uint32_t disablePartition8x16 :1; /**< [in]: Disable MotionEstimation on 8x16 blocks*/
1278+
uint32_t disablePartition16x8 :1; /**< [in]: Disable MotionEstimation on 16x8 blocks*/
1279+
uint32_t disablePartition8x8 :1; /**< [in]: Disable MotionEstimation on 8x8 blocks*/
1280+
uint32_t disableIntraSearch :1; /**< [in]: Disable Intra search during MotionEstimation*/
1281+
uint32_t bStereoEnable :1; /**< [in]: Enable Stereo Mode for Motion Estimation where each view is independently executed*/
1282+
uint32_t reserved :26; /**< [in]: Reserved and must be set to 0 */
1283+
uint32_t reserved1 [255]; /**< [in]: Reserved and must be set to 0 */
1284+
void* reserved2[64]; /**< [in]: Reserved and must be set to NULL */
1285+
} NV_ENC_CONFIG_H264_MEONLY;
1286+
1287+
1288+
/**
1289+
* \struct _NV_ENC_CONFIG_HEVC_MEONLY
1290+
* HEVC encoder configuration parameters for ME only Mode
1291+
*
1292+
*/
1293+
typedef struct _NV_ENC_CONFIG_HEVC_MEONLY
1294+
{
1295+
uint32_t reserved [256]; /**< [in]: Reserved and must be set to 0 */
1296+
void* reserved1[64]; /**< [in]: Reserved and must be set to NULL */
1297+
} NV_ENC_CONFIG_HEVC_MEONLY;
1298+
12661299
/**
12671300
* \struct _NV_ENC_CODEC_CONFIG
12681301
* Codec-specific encoder configuration parameters to be set during initialization.
12691302
*/
12701303
typedef union _NV_ENC_CODEC_CONFIG
12711304
{
1272-
NV_ENC_CONFIG_H264 h264Config; /**< [in]: Specifies the H.264-specific encoder configuration. */
1273-
NV_ENC_CONFIG_HEVC hevcConfig; /**< [in]: Specifies the HEVC-specific encoder configuration. */
1274-
uint32_t reserved[256]; /**< [in]: Reserved and must be set to 0 */
1305+
NV_ENC_CONFIG_H264 h264Config; /**< [in]: Specifies the H.264-specific encoder configuration. */
1306+
NV_ENC_CONFIG_HEVC hevcConfig; /**< [in]: Specifies the HEVC-specific encoder configuration. */
1307+
NV_ENC_CONFIG_H264_MEONLY h264MeOnlyConfig; /**< [in]: Specifies the H.264-specific ME only encoder configuration. */
1308+
NV_ENC_CONFIG_HEVC_MEONLY hevcMeOnlyConfig; /**< [in]: Specifies the HEVC-specific ME only encoder configuration. */
1309+
uint32_t reserved[320]; /**< [in]: Reserved and must be set to 0 */
12751310
} NV_ENC_CODEC_CONFIG;
12761311

12771312

@@ -1542,12 +1577,14 @@ typedef struct _NV_ENC_MEONLY_PARAMS
15421577
void* completionEvent; /**< [in]: Specifies an event to be signalled on completion of motion estimation
15431578
of this Frame [only if operating in Asynchronous mode].
15441579
Each output buffer should be associated with a distinct event pointer. */
1545-
uint32_t reserved1[252]; /**< [in]: Reserved and must be set to 0 */
1580+
uint32_t viewID; /**< [in]: Specifies left,right viewID if NV_ENC_CONFIG_H264_MEONLY::bStereoEnable is set.
1581+
viewID can be 0,1 if bStereoEnable is set, 0 otherwise. */
1582+
uint32_t reserved1[251]; /**< [in]: Reserved and must be set to 0 */
15461583
void* reserved2[60]; /**< [in]: Reserved and must be set to NULL */
15471584
} NV_ENC_MEONLY_PARAMS;
15481585

15491586
/** NV_ENC_MEONLY_PARAMS struct version*/
1550-
#define NV_ENC_MEONLY_PARAMS_VER NVENCAPI_STRUCT_VERSION(2)
1587+
#define NV_ENC_MEONLY_PARAMS_VER NVENCAPI_STRUCT_VERSION(3)
15511588

15521589

15531590
/**
@@ -2889,8 +2926,6 @@ NVENCSTATUS NVENCAPI NvEncOpenEncodeSessionEx (NV_ENC_OPEN_ENC
28892926
*
28902927
* Registers a resource with the Nvidia Video Encoder Interface for book keeping.
28912928
* The client is expected to pass the registered resource handle as well, while calling ::NvEncMapInputResource API.
2892-
* This API is not implemented for the DirectX Interface.
2893-
* DirectX based clients need not change their implementation.
28942929
*
28952930
* \param [in] encoder
28962931
* Pointer to the NVEncodeAPI interface.
@@ -2922,8 +2957,6 @@ NVENCSTATUS NVENCAPI NvEncRegisterResource (void* encoder,
29222957
* Unregisters a resource previously registered with the Nvidia Video Encoder Interface.
29232958
* The client is expected to unregister any resource that it has registered with the
29242959
* Nvidia Video Encoder Interface before destroying the resource.
2925-
* This API is not implemented for the DirectX Interface.
2926-
* DirectX based clients need not change their implementation.
29272960
*
29282961
* \param [in] encoder
29292962
* Pointer to the NVEncodeAPI interface.

0 commit comments

Comments
 (0)