4141#define GUARD_BAND_TYPE 4
4242#define IP_ADDRESS_LEN 16
4343#define MAX_SESSION_COUNT 32
44+ #define MAX_REGION_COUNT 512
4445
4546//!
4647//! \enum DispatchType
@@ -119,7 +120,7 @@ typedef enum
119120{
120121 EncoderType_None = 0 ,
121122 EncoderType_SVTHEVC ,
122- EncoderType_Multiple_SVTHEVC ,
123+ EncoderType_SG1VAAPI ,
123124}EncoderType ;
124125
125126//!
@@ -139,11 +140,12 @@ typedef struct HEADERS
139140//!
140141typedef struct SESSIONINFO
141142{
142- bool isNative ; //!< Native or remote mode
143- char ipAddress [IP_ADDRESS_LEN ]; //!< IP address of worker
144- int32_t port ; //!< Port of worker
145- int32_t targetSocket ; //!< Target CPU group
146- int32_t gpuNode ; //!< Assigned GPU node
143+ EncoderType encoder ; //!< Type of encoder
144+ bool isNative ; //!< Native or remote mode
145+ char ipAddress [IP_ADDRESS_LEN ]; //!< IP address of worker
146+ int32_t port ; //!< Port of worker
147+ int32_t targetSocket ; //!< Target CPU group
148+ int32_t gpuNode ; //!< Assigned GPU node
147149}SessionInfo ;
148150
149151//!
@@ -202,9 +204,12 @@ typedef struct ENCODERPARAM{
202204 uint8_t MCTS_enable ; //!< motion vector constrains flag
203205 uint8_t tile_columnCnt ; //!< tile column count when tile is enabled
204206 uint8_t tile_rowCnt ; //!< tile row count when tile is enabled
207+ uint32_t frame_width ; //!< width of frame
208+ uint32_t frame_height ; //!< height of frame
205209 int8_t target_socket ; //!< Target socket to run on
210+ int32_t gpu_node ; //!< GPU node to encode frames
206211 bool in_parallel ; //!< multiple tiles encoding in parallel
207- bool native_mode ; //!< flag of native mode for encoder
212+ bool native_mode ; //!< flag of native mode for encoder
208213}EncoderParam ;
209214
210215typedef struct INPUTFRAME {
@@ -277,6 +282,23 @@ typedef struct CODECAPPOPTION{
277282 uint32_t minLogLevel ; //!< Minimal log level of output
278283}CodecAppOption ;
279284
285+ typedef struct MANUALREGIONINFO {
286+ int32_t x ;
287+ int32_t y ;
288+ int32_t w ;
289+ int32_t h ;
290+
291+ int32_t encMode ;
292+ int32_t rcMode ;
293+ int32_t qp ;
294+ int32_t bitRate ;
295+ }ManualRegionInfo ;
296+
297+ typedef struct REGIONSESSIONPAIR {
298+ ManualRegionInfo * regionInfo ;
299+ int32_t sessionNumber ;
300+ }RegionSessionPair ;
301+
280302//!
281303//! \struct: DistributedEncoderParam
282304//! \brief: parameters for distributed encoder library
@@ -290,6 +312,8 @@ typedef struct DISTRIBUTEDENCODERPARAM{
290312 bool glogInitialized ; //!< Whether glog has been initialized
291313 SessionInfo * sessionList [MAX_SESSION_COUNT ]; //!< Session info list
292314 uint8_t sessionCount ; //!< Session info count
315+ RegionSessionPair regionInfoList [MAX_REGION_COUNT ];//!< Region info List
316+ uint8_t regionCount ; //!< Region info count
293317}DistributedEncoderParam ;
294318
295319#ifdef __cplusplus
0 commit comments