Hi,
I am encoding video on the fly using JavaCV & its JNDI binding for ffmpeg. I’m using the following settings:
FFmpegFrameRecorder fFmpegFrameRecorder = new FFmpegFrameRecorder("rtmp://localhost:1935/live/stream1", 400, 384); //rtmp destination, width and height
recorder.setVideoCodec(avcodec.AV_CODEC_ID_H264);
recorder.setPixelFormat(avutil.AV_PIX_FMT_YUV420P);
recorder.setFormat("flv");
recorder.setFrameRate(30);
recorder.setVideoBitrate(250000);
recorder.setVideoOption("x264opts, "keyint=30:min-keyint=30:no-scenecut"));
recorder.setVideoOption("preset", "medium");
recorder.setGopSize(30 * 2); //60 frames
On Wowza I have the following settings for “Cupertino Streaming Packetizer” properties:
cupertinoChunkDurationTarget=1000
cupertinoMaxChunkCount=3
I want to keep these low because I’m trying to keep client’s video roughly in sync with one another.
When I view the stream over HLS it seems to stutter every second, or more precisely every “cupertinoChunkDurationTarget” milliseconds. I have tried playing around with various encoder and Wowza settings but can’t seem to get rid of it. Any suggestions?