set-video

Use this interface to configure parameters of the main and sub streams, including:

  • resolution
  • frame interval
  • video codec: choose H264 or HEVC for the main stream. The sub stream uses H264.
  • profile
  • video bit rate
  • keyframe interval
  • quantization range
  • bit rate stats duration

Obtain parameters value range using get-info.

{
  "codec-cap": {
    "resolutions": [],           // Value range of resolution 
    "durations": [],             // Value range of frame interval 
    "video-codec": [],           // Value range of video codec 
    "profile": [],               // H264 profile 
    "hevc-profile": [],          // HEVC profile 
    "video-kbps": [],            // Value range of video bit rate 
    "gop-sec": [],               // Value range of keyframe interval 
    "video-range": [],           // Value range of quantization range 
    "stat-sec": []               // Value range of bit rate stats duration 
  }
}

HTTP Request

GET http://ip/usapi?method=set-video&stream=0&is-auto=0&cx=1280&cy=720&duration=333333&kbps=1024&gop=1&fourcc=0&profile=2&cbrstat=60&fullrange=1&codec=0
Parameter Description
method set-video
stream Indicates the stream type.
0: the main stream
1: the sub stream
is-auto Indicates whether the stream format follows that of input signal. For a sub stream, this parameter can only be set to 0.
0: custom the format for your session.
1: follow input.
cx Indicates width of resolution dimensions in pixels.
cy Indicates height of resolution dimensions.
duration Indicates frame interval.
kbps Indicates bit rate.
gop Indicates keyframe interval.
fourcc Reserved. The default value is 0.
codec Indicates video codec.
profile Indicates encoding profile.
cbrstat Indicates bit rate stats duration.
fullrange Indicates quantization range.
is-vbr 0: CBR
1: VBR, the maximum and minimum steps are required
min-vbr-qp min-step ranging from 0 to 51
max-vbr-qp max-step ranging from minimum to 51
is-time-code-sei 0: not to set time code SEI messages
1: set a time code SEI messages
is-closed-caption-sei 0: not to set CC SEI messages
1: set CC SEI messages
ar-convert-mode 0: Ignore
1: Cropping
2: Padding

Response Body

{
  "result": 0
}
Item Description
result 0 indicates that the request was accepted successfully. Refer to API Status Codes to find specific description for other values.

results matching ""

    No results matching ""

    results matching ""

      No results matching ""