We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
int VideoCtl::audio_thread(void *arg) { VideoState *is = (VideoState *)arg; AVFrame *frame = av_frame_alloc(); Frame *af;
int got_frame = 0; AVRational tb; int ret = 0; if (!frame) return AVERROR(ENOMEM); do { if ((got_frame = decoder_decode_frame(&is->auddec, frame, NULL)) < 0) goto the_end; if (got_frame) { tb = { 1, frame->sample_rate }; if (!(af = frame_queue_peek_writable(&is->sampq))) goto the_end; af->pts = (frame->pts == AV_NOPTS_VALUE) ? NAN : frame->pts * av_q2d(tb); af->pos = av_frame_get_pkt_pos(frame); af->serial = is->auddec.pkt_serial; af->duration = av_q2d({ frame->nb_samples, frame->sample_rate }); av_frame_move_ref(af->frame, frame); frame_queue_push(&is->sampq); } } while (ret >= 0 || ret == AVERROR(EAGAIN) || ret == AVERROR_EOF);
the_end:
av_frame_free(&frame); return ret;
} 比如说这个函数,新版本里面av_frame_get_pkt_pos已经废弃,Frame这个自定义的结构体是必须要用到pos这个成员吗?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
int VideoCtl::audio_thread(void *arg)
{
VideoState *is = (VideoState *)arg;
AVFrame *frame = av_frame_alloc();
Frame *af;
the_end:
}
比如说这个函数,新版本里面av_frame_get_pkt_pos已经废弃,Frame这个自定义的结构体是必须要用到pos这个成员吗?
The text was updated successfully, but these errors were encountered: