RtmpPublisher icon indicating copy to clipboard operation
RtmpPublisher copied to clipboard

issue with frame rate

Open rahulpal193 opened this issue 6 years ago • 11 comments

When i have done live stream on wowza streaming server then shows issue on wowza streaming server that
frame rate is too low that is 14.3 and key frame interval should be equal or twice to frame rate.

and video quality is too low.

rahulpal193 avatar May 14 '18 10:05 rahulpal193

you can't set a specific frame rate for now. I will add that feature to control the frame rate later, one thing you can do now is fork this repo and change this value.

https://github.com/TakuSemba/RtmpPublisher/blob/master/rtmppublisher/src/main/java/com/takusemba/rtmppublisher/VideoEncoder.java#L18

and if you can set higher bitrate to make the video quality high. check out read.me for more info.

thanks.

TakuSemba avatar May 17 '18 04:05 TakuSemba

When you instance Publisher .setVideoBitrate() to 204800

publisher = new Publisher.Builder(this) .setGlView(glView) .setUrl(url) .setSize(480, 640) .setAudioBitrate(6400) .setVideoBitrate(204800) .setCameraMode(Publisher.Builder.DEFAULT_MODE) .setListener(this) .build();

camillo860 avatar May 19 '18 18:05 camillo860

@camillo860 sorry, what do you mean by "When you instance Publisher .setVideoBitrate() to 204800"

TakuSemba avatar May 22 '18 05:05 TakuSemba

When you instance class Publisher, you can set bitrate. The number 204800 is a bitrate andi it is equal to 2000Kbit/ps. . The default value is very low.

camillo860 avatar May 23 '18 09:05 camillo860

There are lots of bitrate and resolutions problem in the library may be. Not sure bug is in the library or i am doing some mistakes. Unfortunately not able to find combinations for resolutions

I need combination for

1080p: "width": 1920,"height": 1080 720p: "width": 1280,"height": 720 460p: "width": 854,"height": 460

1080p VideoBitrate: 3000kps AudioBitrate: 320kps 720p VideoBitrate: 1500kps AudioBitrate: 160kps 480p VideoBitrate: 500kps AudioBitrate: 160kps

Unfortunately these combinations are not working for me output is worst. Can you suggest me any solution for that ?

I have tried multiple devices and multiple android versions to make sure version is not the problem

rkoshti avatar May 24 '18 11:05 rkoshti

did you set these setAudioBitrate() and .setVideoBitrate() ? if you did, what values are they?

TakuSemba avatar May 29 '18 04:05 TakuSemba

Video bitrate = 1500 * 1024 Audio bitrate = 160 Width = 1280 Height = 720

rkoshti avatar May 29 '18 04:05 rkoshti

if your device is connected to wifi? from my experiences, if the network is weak, the output is really bad.

TakuSemba avatar May 29 '18 08:05 TakuSemba

Yes I am testing using WiFi connection

rkoshti avatar May 29 '18 08:05 rkoshti

well, I have to reproduce the situation first, it might take take a little bit long, but I will let you know if I find something.

TakuSemba avatar May 30 '18 14:05 TakuSemba

I am using very high-speed data connectivity. If I use the default video bitrate, the quality is bad but Ant Media Server is able to save and preview it. But if I increase the bit rate, the Ant Media server detects the stream but is unable to save or preview it.

anoopmis avatar Feb 20 '20 04:02 anoopmis