-
Notifications
You must be signed in to change notification settings - Fork 930
New issue
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
copy in ffmpeg c++ #65
Comments
i hope you will open it if you want to help , thanks in advance |
Hey @Niek-Okido Greeping the FFmpeg source code ( static void close_output_stream(OutputStream *ost)
{
OutputFile *of = output_files[ost->file_index];
ost->finished |= ENCODER_FINISHED;
if (of->shortest) {
int64_t end = av_rescale_q(ost->sync_opts - ost->first_pts, ost->enc_ctx->time_base, AV_TIME_BASE_Q);
of->recording_time = FFMIN(of->recording_time, end);
}
} |
but in reality you could check the duration of the shortest stream and stop to process packets/frames there. |
thank you very much, really needed this help :) thank you very much get it working now ❤️ |
dear,
i am currently stuck now for almost 1 month and still not get the solution ,
in the commandline tool the following command is what i want
ffmpeg -i "video.mp4" -i "audio.mp4" -codec copy -shortest output.mp4
i want to add a new generated video with no sound in it (greated with opencv). to the original video
what i need to do in c++ i really stuck now on this for 4 weeks (learn a lot of new things).
i hope you can help me with this , it seems to be very easy but my headache is on the
-codec copy -shortest
how i can get this succeeded in ffmpeg?thank in advance if you want to help me with this,
Kind regards Niek Tuytel,
The text was updated successfully, but these errors were encountered: