How to merge two .MTS files in Linux
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
I have two video files from a Panasonic camera in .MTS format and I want to merge them into one file and burn that file onto a TV-playable DVD.
I tried importing them into kino and merging them, but the resulting file has somehow a very slow video playback and the audio is way out of sync.
I selected the MPEG tab with file format '8 - DVD' with no deinterlacing.
Can someone point me into the right direction for merging the two files correctly? Since exporting of the file takes around one hour, it's quite impractical to play around with different options :)
video ffmpeg
add a comment |Â
up vote
0
down vote
favorite
I have two video files from a Panasonic camera in .MTS format and I want to merge them into one file and burn that file onto a TV-playable DVD.
I tried importing them into kino and merging them, but the resulting file has somehow a very slow video playback and the audio is way out of sync.
I selected the MPEG tab with file format '8 - DVD' with no deinterlacing.
Can someone point me into the right direction for merging the two files correctly? Since exporting of the file takes around one hour, it's quite impractical to play around with different options :)
video ffmpeg
Isn't kino for DV only? Ifffmpeg
can handle it, you could useffmpeg -i 'concat:1.mts|2.mts' output.mpeg
(plus whatever codec/quality options you desire).
â frostschutz
Sep 17 '13 at 16:55
1
Wouldn't this be a better match for SuperUser?
â darnir
Sep 17 '13 at 17:52
add a comment |Â
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I have two video files from a Panasonic camera in .MTS format and I want to merge them into one file and burn that file onto a TV-playable DVD.
I tried importing them into kino and merging them, but the resulting file has somehow a very slow video playback and the audio is way out of sync.
I selected the MPEG tab with file format '8 - DVD' with no deinterlacing.
Can someone point me into the right direction for merging the two files correctly? Since exporting of the file takes around one hour, it's quite impractical to play around with different options :)
video ffmpeg
I have two video files from a Panasonic camera in .MTS format and I want to merge them into one file and burn that file onto a TV-playable DVD.
I tried importing them into kino and merging them, but the resulting file has somehow a very slow video playback and the audio is way out of sync.
I selected the MPEG tab with file format '8 - DVD' with no deinterlacing.
Can someone point me into the right direction for merging the two files correctly? Since exporting of the file takes around one hour, it's quite impractical to play around with different options :)
video ffmpeg
video ffmpeg
edited 1 min ago
jasonwryan
47.9k14131181
47.9k14131181
asked Sep 17 '13 at 16:49
Wojciech Morawiec
1013
1013
Isn't kino for DV only? Ifffmpeg
can handle it, you could useffmpeg -i 'concat:1.mts|2.mts' output.mpeg
(plus whatever codec/quality options you desire).
â frostschutz
Sep 17 '13 at 16:55
1
Wouldn't this be a better match for SuperUser?
â darnir
Sep 17 '13 at 17:52
add a comment |Â
Isn't kino for DV only? Ifffmpeg
can handle it, you could useffmpeg -i 'concat:1.mts|2.mts' output.mpeg
(plus whatever codec/quality options you desire).
â frostschutz
Sep 17 '13 at 16:55
1
Wouldn't this be a better match for SuperUser?
â darnir
Sep 17 '13 at 17:52
Isn't kino for DV only? If
ffmpeg
can handle it, you could use ffmpeg -i 'concat:1.mts|2.mts' output.mpeg
(plus whatever codec/quality options you desire).â frostschutz
Sep 17 '13 at 16:55
Isn't kino for DV only? If
ffmpeg
can handle it, you could use ffmpeg -i 'concat:1.mts|2.mts' output.mpeg
(plus whatever codec/quality options you desire).â frostschutz
Sep 17 '13 at 16:55
1
1
Wouldn't this be a better match for SuperUser?
â darnir
Sep 17 '13 at 17:52
Wouldn't this be a better match for SuperUser?
â darnir
Sep 17 '13 at 17:52
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
0
down vote
#!/usr/bin/env bash
# Join video clips
video1="$1"
video2="$2"
name="$video%.*"
ext="$video#*."
(( $# != 2)) && printf "%sn" "Pass two videos to convert" && exit 1
read -p "Name of joined file? " jfile
ffmpeg -i "$1" -c copy -bsf:v h264_mp4toannexb -f mpegts int_1.ts
ffmpeg -i "$2" -c copy -bsf:v h264_mp4toannexb -f mpegts int_2.ts
ffmpeg -i "concat:int_1.ts|int_2.ts" -c copy -bsf:a aac_adtstoasc "$jfile"
(( $? == 0 )) && rm int_*
# vim:set ts=2 sts=2 sw=2 et:
add a comment |Â
up vote
-3
down vote
Join many MTS clips into one MTS file and convert the joined MTS to MP4, WMV, MOV, AVI, FLV, MKV, ASF, etc.with Avdshare Video Converter.
New contributor
Flagged as spam, cf. unix.stackexchange.com/a/419792 and 70 other posts on the Stack Exchange network (and counting).
â Glorfindel
5 mins ago
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
#!/usr/bin/env bash
# Join video clips
video1="$1"
video2="$2"
name="$video%.*"
ext="$video#*."
(( $# != 2)) && printf "%sn" "Pass two videos to convert" && exit 1
read -p "Name of joined file? " jfile
ffmpeg -i "$1" -c copy -bsf:v h264_mp4toannexb -f mpegts int_1.ts
ffmpeg -i "$2" -c copy -bsf:v h264_mp4toannexb -f mpegts int_2.ts
ffmpeg -i "concat:int_1.ts|int_2.ts" -c copy -bsf:a aac_adtstoasc "$jfile"
(( $? == 0 )) && rm int_*
# vim:set ts=2 sts=2 sw=2 et:
add a comment |Â
up vote
0
down vote
#!/usr/bin/env bash
# Join video clips
video1="$1"
video2="$2"
name="$video%.*"
ext="$video#*."
(( $# != 2)) && printf "%sn" "Pass two videos to convert" && exit 1
read -p "Name of joined file? " jfile
ffmpeg -i "$1" -c copy -bsf:v h264_mp4toannexb -f mpegts int_1.ts
ffmpeg -i "$2" -c copy -bsf:v h264_mp4toannexb -f mpegts int_2.ts
ffmpeg -i "concat:int_1.ts|int_2.ts" -c copy -bsf:a aac_adtstoasc "$jfile"
(( $? == 0 )) && rm int_*
# vim:set ts=2 sts=2 sw=2 et:
add a comment |Â
up vote
0
down vote
up vote
0
down vote
#!/usr/bin/env bash
# Join video clips
video1="$1"
video2="$2"
name="$video%.*"
ext="$video#*."
(( $# != 2)) && printf "%sn" "Pass two videos to convert" && exit 1
read -p "Name of joined file? " jfile
ffmpeg -i "$1" -c copy -bsf:v h264_mp4toannexb -f mpegts int_1.ts
ffmpeg -i "$2" -c copy -bsf:v h264_mp4toannexb -f mpegts int_2.ts
ffmpeg -i "concat:int_1.ts|int_2.ts" -c copy -bsf:a aac_adtstoasc "$jfile"
(( $? == 0 )) && rm int_*
# vim:set ts=2 sts=2 sw=2 et:
#!/usr/bin/env bash
# Join video clips
video1="$1"
video2="$2"
name="$video%.*"
ext="$video#*."
(( $# != 2)) && printf "%sn" "Pass two videos to convert" && exit 1
read -p "Name of joined file? " jfile
ffmpeg -i "$1" -c copy -bsf:v h264_mp4toannexb -f mpegts int_1.ts
ffmpeg -i "$2" -c copy -bsf:v h264_mp4toannexb -f mpegts int_2.ts
ffmpeg -i "concat:int_1.ts|int_2.ts" -c copy -bsf:a aac_adtstoasc "$jfile"
(( $? == 0 )) && rm int_*
# vim:set ts=2 sts=2 sw=2 et:
answered 3 mins ago
jasonwryan
47.9k14131181
47.9k14131181
add a comment |Â
add a comment |Â
up vote
-3
down vote
Join many MTS clips into one MTS file and convert the joined MTS to MP4, WMV, MOV, AVI, FLV, MKV, ASF, etc.with Avdshare Video Converter.
New contributor
Flagged as spam, cf. unix.stackexchange.com/a/419792 and 70 other posts on the Stack Exchange network (and counting).
â Glorfindel
5 mins ago
add a comment |Â
up vote
-3
down vote
Join many MTS clips into one MTS file and convert the joined MTS to MP4, WMV, MOV, AVI, FLV, MKV, ASF, etc.with Avdshare Video Converter.
New contributor
Flagged as spam, cf. unix.stackexchange.com/a/419792 and 70 other posts on the Stack Exchange network (and counting).
â Glorfindel
5 mins ago
add a comment |Â
up vote
-3
down vote
up vote
-3
down vote
Join many MTS clips into one MTS file and convert the joined MTS to MP4, WMV, MOV, AVI, FLV, MKV, ASF, etc.with Avdshare Video Converter.
New contributor
Join many MTS clips into one MTS file and convert the joined MTS to MP4, WMV, MOV, AVI, FLV, MKV, ASF, etc.with Avdshare Video Converter.
New contributor
New contributor
answered 14 mins ago
Tonya Rabish
1
1
New contributor
New contributor
Flagged as spam, cf. unix.stackexchange.com/a/419792 and 70 other posts on the Stack Exchange network (and counting).
â Glorfindel
5 mins ago
add a comment |Â
Flagged as spam, cf. unix.stackexchange.com/a/419792 and 70 other posts on the Stack Exchange network (and counting).
â Glorfindel
5 mins ago
Flagged as spam, cf. unix.stackexchange.com/a/419792 and 70 other posts on the Stack Exchange network (and counting).
â Glorfindel
5 mins ago
Flagged as spam, cf. unix.stackexchange.com/a/419792 and 70 other posts on the Stack Exchange network (and counting).
â Glorfindel
5 mins ago
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f91083%2fhow-to-merge-two-mts-files-in-linux%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Isn't kino for DV only? If
ffmpeg
can handle it, you could useffmpeg -i 'concat:1.mts|2.mts' output.mpeg
(plus whatever codec/quality options you desire).â frostschutz
Sep 17 '13 at 16:55
1
Wouldn't this be a better match for SuperUser?
â darnir
Sep 17 '13 at 17:52