Merging mlts corrupts

This is a bit curious. I save each lecture scene (approx 1 minute each) into a separate mlt file. Each mlt clip plays fine on its own. But when I load them all into the playlist and then into to the timeline, the fifth mlt causes the audio to garble and the end of the mlt clip to extend. The other mlt clips are fine. I deleted and rebuilt the combined mlt clip and got the same result. So I created an mp4 (which took quite a long time for a 6 minute video). Not only did that segment’s audio remain garbled, but lost sync with the video. But the rest of the mp4 was fine. (My plan is to rebuild the offending clip and try it again assuming that I will avoid whatever is causing this malfunction.)

I’m running Microsoft Windows 10 home Version 10.0.18363 Build 18363 on a Dell Inspiron laptop,

Any idea what I might have done to get this resullt?

If this issue is specific to the files you are working with, would you be willing to send the source files along the MLT project file to Dan, the main developer? You can PM him if you don’t want the files to be on the open forum.

Are all the clips from the same camera and same recording session? Is it possible that the different MLT projects may have been made with different frame rates?

Yes. Certainly. How do I get them to Dan (the main developer)? Attachments to a reply?

Thank you, @Austin, for your reply. Yes they are from the same camera (Logitech C920 HD Pro) recorded on a Lavaliere microphone (Mano Elf I believe) in the same morning session. My guess is that I inadvertently and subtly corrupted the video and/or audio while editing that took it out of sync with the other mlts so that when I concatenated them with my other MLT clips, Shotcut couldn’t cope.

I do believe it is something I did while editing the original video. And recreating the offending mlt took care of the problem. But not knowing what I did means I could do it again.

@DRM I continue to have the same issue. My guess is that it has to do with either the .png files and/or the “open other”>Text tracks that I add over the base .mpg .

It appears I have two choices. I can either export each mlt to an mpg and combine them later, or create my entire lecture into a single mlt before exporting.

Beyond being quite annoying, the latter portion of my Video Memories course involves using a video editor. I am planning on recommending and demonstrating Shotcut.

Earlier you asked for the source files, but not how to get them to you. The main folder containing this latest example is 172MB (before zip as of this writing) and one mlt uses a ,jpg outside of that folder. If you are still interested let me know how I can get them to you.

It’s Dan that would have to look at them as he is the main developer. If you don’t have a problem putting the files on an open forum and if the files aren’t huge sizes then you can try to upload the mp4 and mlt project files directly in a reply of yours here by hitting the upload button in the reply toolbar. Then when he sees your post he can take them from here and analyze them. You can always delete the files from here afterwards.

If you rather share those files through private message then send him a private message with those mp4 and mlt files at @shotcut.

https://forum.shotcut.org/uploads/default/original/2X/6/6ec9a1173746ea73149af843ccbbc8658360d0d9.mp4 The lecture itself is too large to uploadHere are the relevant mlts and sources. I can cobble together a screencast if that’s appropriate.000Title.mlt (5.9 KB) 00Introduction.mlt (20.0 KB)

Do you have like a dropbox account or any account with a file storage site? You can upload it there and just put the download link here.

@DRM I do not have a dropbox account at the moment. I do have something called “one drive” on my tray which I suppose I could research. I am a bit torn between completing the edits for my lecture and redirecting my efforts to learn how to define and populate a drop box. But your response has been so positive that I will try to figure it out and have something by tomorrow. Thanks again for your attention to this dilemma.

Just get a mega account then. It’s free and you can do it quickly to post it here.

@DRM I have downloaded Mega. But I do not seem to figure out how it works. I tried uploading a folder and it tells me it is already sync’d. I am quite beyond my level of frustration for today. I’ll give it another shot tomorrow.

Make sure they are all the same frame rate. If you were using Automatic Video Mode, then it may have created MLT files with differing frame rates. You open each in a text editor and look at the <profile> in each looking at its frame_rate_num and frame_rate_den attributes.

@shotcut That appears to be it. The frame rate / den for the first mlt is 25 / 1. But for the next two, the frame rate / den is 9164800 / 305493. The remaining mlts return to 25 / 1.

Thank you. So, what are my remedy alternatives?

Upload the ones with the strange frame rate. I will fix them manually. There is a process to change them within the UI, but I do not want you to bump into a known bug with that fixed for the next version.
In the future, when using this kind of workflow, choose a specific Video Mode and stick to it for all your projects. I will think about a way to avoid the problem with mixing frame rates in the meantime.

@shotcut As if you didn’t have enough to do. Here is the only mlt I have not rewritten. S00Introduction.mlt (22.1 KB)

I don’t know what I did to achieve the erroneous video mode, I have not intentionally chosen a Video Mode, taking the defaults. And for at least one of the earlier issues, simply rebuilding the mlt from scratch took care of the issue (as I look back at the one with the bad frame rate versus the rebuilt one with the 25 / 1 rate.),

As I mentioned, part of the course I’m building features a subset of Shotcut capabilities so my student’s may run into the same issue. Is there something I can share with my students to preempt / avoid / detect / repair that I can include in my lectures?

Tell them to be careful with Automatic Video Mode. While convenient for quick casual work, better to pick something such as 1080p25 (whatever the majority of your source video footage is) and stick with it.

Your .mlt file was easy to repair because it was not affected by the bug I mentioned. After verifying every instance of <property name="length">00:00:59.833</property> uses a time value rather than a real number (frame units), all I had to do was edit the <profile> for 25 fps.

S00Introduction.mlt (22.1 KB)

Thank you @shotcut . I gather I select HD 1080p25 fps in Settings>Video Mode. And that I should recommend that my students do the same? (They will seldom upload a video. Just uploaded photographs, clip art, narration they record on their computer and music clips from the YouTube library.)

Also, to see if I understand – as long as the property name=“length” contains a time stamp, I can simply overtype the frame_rate_num and frame_rate_den to 25 and 1 respectively? Not that intend to do that. Just curious.

Yes and yes

As I prepare my ShotCut export lecture, I find that Youtube, Facebook, Instagram, Linkedin , Snapchat and Twitter to name a few, recommend 30fps. Should I still set my Video Mode to 25fps?