Skip to content

Commit 6ad6a82

Browse files
fix gop size
1 parent 38c6c78 commit 6ad6a82

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

3_transcoding.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,10 @@ int prepare_encoder(StreamingContext *sc, AVCodecContext *decoder_ctx, AVRationa
105105
if (!sc->video_avcc) {logging("could not allocated memory for codec context"); return -1;}
106106

107107
av_opt_set(sc->video_avcc->priv_data, "preset", "slow", 0);
108-
//av_opt_set(sc->video_avcc->priv_data, "x264opts", "keyint=60:min-keyint=60:scenecut=-1", 0);
108+
av_opt_set(sc->video_avcc->priv_data, "x264opts", "keyint=60:min-keyint=60:scenecut=-1", 0);
109+
//
110+
//sc->video_avcc->keyint_min = 60;
111+
//sc->video_avcc->gop_size = 60;
109112

110113
sc->video_avcc->height = decoder_ctx->height;
111114
sc->video_avcc->width = decoder_ctx->width;

0 commit comments

Comments
 (0)