bytedeco/javacv
View on GitHubavfilter_graph_parse_ptr() error -22 while merging two music with different sample rate
Open
#1,736 opened on Jan 7, 2022
help wantedquestion
Repository metrics
- Stars
- (6,985 stars)
- PR merge metrics
- (No merged PRs in 30d)
Description
Hi, I want to merge two music with different sample rate(44100 and 48000), and I push their samples to two FFmpegFrameFilter(A, B) with different sample rate. And I want merge these two filters into the one, how can I do this?
I create third filter(C, 44100) uses [0:a][1:a]amix=inputs=2:duration=longest[a].
And I push Samples that pulled by A and B to C.
But I get the error message (avfilter_graph_parse_ptr() error -22) while pushing B's samples.
So, what is the correct way of merging two music with different sample rate?
Thanks.