Skip to content
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

Error in merging videos #29

Open
nauman415 opened this issue Jul 6, 2018 · 0 comments
Open

Error in merging videos #29

nauman415 opened this issue Jul 6, 2018 · 0 comments

Comments

@nauman415
Copy link

String intermediate1 = getExternalFilesDir(null).getAbsoluteFile()+"/intermediate1.ts";
String intermediate2 = getExternalFilesDir(null).getAbsoluteFile()+"/intermediate2.ts";
String filein = getExternalFilesDir(null).getAbsoluteFile()+"/in.mp4";
String fileout = getExternalFilesDir(null).getAbsoluteFile()+"/out.mp4";
String fileouts = getExternalFilesDir(null).getAbsoluteFile()+"/outs.mp4";
/************************************************/
Controller.getInstance().run(new String[]{
"-i",
filein,
"-c",
"copy",
"-bsf:v h264_mp4toannexb",
"-f",
"mpegts",

            intermediate1
    });
    Controller.getInstance().run(new String[]{
            "-i",
            fileout,
            "-c",
            "copy",
            "-bsf:v h264_mp4toannexb",
            "-f",
            "mpegts",

            intermediate2
    });

[https://trac.ffmpeg.org/wiki/Concatenate]
/*****************************************/
below is your code

from this files are created but not merge into 1 file

Controller.getInstance().run(new String[]{
"-f",
"-i",
filein,
"-vcodec",
"copy",
"-an",
intermediate2
}); Controller.getInstance().run(new String[]{
"-f",
"-i",
fileout,
"-vcodec",
"copy",
"-an",
intermediate1
});
Controller.getInstance().run(new String[]{
"-i",
"concat:"+intermediate1+"|"+intermediate2,
"-c",
"copy",
"-bsf:a aac_adtstoasc",
fileouts
});
Application is closed when this code is run
Please help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant