mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2024-11-22 10:40:05 +08:00
avoid fps too big
This commit is contained in:
parent
98ec6b68d9
commit
876aea33f5
@ -382,7 +382,7 @@ Value makeMediaSourceJson(MediaSource &media){
|
||||
int gop_size = video_track->getVideoGopSize();
|
||||
int gop_interval_ms = video_track->getVideoGopInterval();
|
||||
float fps = video_track->getVideoFps();
|
||||
if (fps <= 1) {
|
||||
if (fps <= 1 && gop_interval_ms) {
|
||||
fps = gop_size * 1000.0 / gop_interval_ms;
|
||||
}
|
||||
obj["fps"] = round(fps);
|
||||
|
Loading…
Reference in New Issue
Block a user