MSE h.264 latency

Max

Administrator
Staff member
Hello, Stanley.
Live stream latency depends on GOP (group of pictures), or keyframe interval size: the more often keyframe is sent, the less latency. You can adjust it as follows depending on your case:
1. If you publish RTMP steam to WCS server and then client plays it using MSE, you can adjust GOP size on your RTMP source.
2. If you publish WebRTC stream, you can set these options in WCS_HOME/conf/flashphoner.properties:
Code:
periodic_fir_request=true
periodic_fir_request_interval=1000
In this case, keyframe will be requested every 1 second.
3. You can enable transcoding on your WCS server
Code:
disable_streaming_proxy=true
and set GOP size for H.264 encoder (60 is the default value)
Code:
video_encoder_h264_gop=60
Note that the less GOP, the more bandwith is required.
 

Stanley

Member
Hi Max how do i ensure that there is no transcoding and only passthrough for MSE h.264? Ingest is RTMP h.264 mp4+aac
 

Max

Administrator
Staff member
Hi Max how do i ensure that there is no transcoding and only passthrough for MSE h.264?
You can open server stats and check native_resources field.
The filed lists all open decoders and encoders.

Example for video codecs:
15602328, H.264, Encoder, 500
Resource ID: 15602328
Resource name: H.264
Resource type: Encoder
Processed samples: 500

Example for audio codecs
15602328, Opus, -500
Resource ID: 15602328
Resource name: Opus
Processed samples: 500
Resource type: Encoder because (-500), or Decoder if (+500)

https://docs.flashphoner.com/display/WCS5EN/Load+and+resource+usage+information
 

Stanley

Member
Hi Max,
Is there any way to increase MSE and WSPlayer live stream loading speed? Anything we can fine tune in flashphoner.js ?
 

Max

Administrator
Staff member
Hello
You can't increase download speed because it depends on underling network channel only and on its quality.
MSE and WSPlayer (Websocket) are TCP based protocols.
So you can't manage latency here.
You can decrease video resolution to decrease overall video bitrate.
It may help for low-bitrate channels. However any fluctuation on the network may increase latency.
That's why WebRTC (RTP) is used for real-time. Not MSE or WSPlayer.
 
Top