This forum has been archived. All content is frozen. Please use KDE Discuss instead.

.kdenlive file format

Tags: None
(comma "," separated)
mcfrisk
Registered Member
Posts
40
Karma
0

.kdenlive file format

Mon Jun 22, 2009 4:29 pm
In short:

Please make .kdenlive part of the user interface and try keep it scriptable and simple.

In too many words:
I'm trying to work with a number of video formats and kdenlive.

It's been quite a ride, but now I think I know how to make various formats editable in kdenlive for progressive 720p output:

- deinterlace all dv videos with ffmpeg before editing:
ffmpeg -i raw.dv -target pal-dv -deinterlace -sameq editable.avi

- deinterlace and convert all AVCHD .mts files to mpeg4 avi's:
ffmpeg -i $f -s hd720 -acodec pcm_s16le -ac 2 -vcodec mpeg4 -sameq -deinterlace editable.avi

- use MJPEG 720p videos as is

The problem now is, that all the editing I did with bad file formats like interleaved and fps wrongly set to 60000 videos is now going to waste.

Problem 1: changing fps

My timeline is a fast paced 8 minute clip. Some of the edited MPEG4 clips had fps set to 60000 (mencoder doesn't like fps 60000/1001) which seemed play with original speed in editor but not after rendering. I re-created these MPEG4 clips from the original AVCHD .MTS files with correct fps. The clips are loaded and seem to play at correct speed in kdenlive editor, but the project file still states the files to be at 60000 fps.

Can I safely remove the source_fps property from the .kdenlive file?

Problem 2: changing clip name

I deinterlaced all dv material which kdenlive wasn't able to deinterlace for me, but I also changed the clip file names.

Can I just change the clip file name to point to *_deint.avi instead of .dv?

There's another problem, ffmpeg creates 48kHz audio while my cheap Sony camera used 32kHz audio stream.

Can I just change the meta.media.1.codec.sample_rate to 48000, or can kdenlive somehow re-read the properties.

The project takes 20 minutes to load, a few hundred clips and still fotos. It seems reading clip properties and thumbnails takes all this time. But still I'd like kdenlive to read clip properties from the clips, and not cache them in the project file. This would allow using editing sources at say VGA resolution and rendering sources at 1024i50 resolution. Also, loading thumbnails effectively makes the GUI non-responsive, I can't really do anything on the project before it's done. Progress bar would be nice.


jmpoure_drupal
Registered Member
Posts
735
Karma
0

Re: .kdenlive file format

Tue Jun 23, 2009 8:53 am
* Please add your camcorder to the database if it is not already in and publish some footage. We will not answer unless your footage is published. It is very important to reproduce bugs and help improve FFmpeg, Kdenlive and MLT.
* Editing at VGA size od HD720 will downgrade the quality of your films. Project size is not a temporary size during editing. Downgrading to lower quality will destroy your film. Use your original HD movies and use the same size of project, i.e. probably HDV 1080p. I don't know the resolution of the source media.
* Do not deinterlace prior to rendering. Kdenlive has an option to export full frames, in which case it will deinterlace on rendering.
* Do not convert files to Mpeg4. If you wish, Kdenlive 0.7.4 has an option to transcode media to non-destructive DNxGD format. Use this format if you want to avoid AVCHD.
* Always use Kdenlive 0.7.4, not 0.7.3

* Disable thumbnails, 20 minutes loading is inacceptable.
* Do not write Kdenlive MLT files by hand. This is way to difficult and undocumented.
mcfrisk
Registered Member
Posts
40
Karma
0

Re: .kdenlive file format

Tue Jun 23, 2009 3:18 pm
Thanks for the answers.

1. I'll check that the Sony cameras are in the database. The cameras aren't mine, I just have the footage atm. Back in spring editing with the raw .MTS files didn't work at all, so I gave up and converted them to mpeg4. Now I just try to finish this project without redoing the whole timeline. For new projects I will try to use the originals.

2. Ok, for now I try to create 720p and VGA for web from 720p30, pal-dv and 1024i50 sources.

3. When mixing 720p, pal-dv and 1024i50 content, I can't get kdenlive to deinterlace the interlaced formats.

4. Non-destructive formats are great, but with my current setup I don't have the disk space: just 20 gigabytes left. For this project mpeg4 will suffice. Though I had to switch from .avi to .mov, since ffmpeg created .avi's played only once and seeking failed with mplayer, melt and kdenlive.

5. I'm trying to keep up with svn and git versions.

6. Actually I need the thumbnails when looking through the clip selections. Plain file names overlap, sigh. But after loading, kdenlive is responsive even when:

Mem: 1035308k total, 1019028k used, 16280k free, 4640k buffers
Swap: 2084856k total, 1013284k used, 1071572k free, 68520k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
23889 mcfrisk 20 0 1955m 822m 9800 S 0.0 81.3 16:05.81 kdenlive

7. Ok, I just wish the project file format would be scriptable. Relying on plain guis isn't nice, or Unix like.

Thanks for your hard work!


madsdyd
Registered Member
Posts
204
Karma
0

Re: .kdenlive file format

Thu Jun 25, 2009 1:12 pm
re 7) I agree, and eventually I believe we should have at the very least an xsd to rely on. At the moment however, you are very much on your own. You can have a look at the code, obviously, and the MLT section is actually documented on the MLT website.
ddennedy
Registered Member
Posts
1315
Karma
1

Re: .kdenlive file format

Thu Jun 25, 2009 9:57 pm
Any property in the XML beginning with meta.media. is ignored. These are read-only, generated properties to describe the clip to you or a tool. You can delete them if it makes manual editing more convenient.

The file format is already scriptable if you use it with a XML DOM API as kdenlive does, or you can use the MLT API with script bindings and simply serialize it with the XML consumer, or you can just do text processing as I have done with PHP for one customer. There is a DTD for MLT XML, but not yet XSD.




Bookmarks



Who is online

Registered users: bartoloni, Bing [Bot], Google [Bot], Yahoo [Bot]