LDraw.org Discussion Forums
Export of .mpd to single 'stand-alone' .ldr file ? - Printable Version

+- LDraw.org Discussion Forums (https://forums.ldraw.org)
+-- Forum: LDraw Programs (https://forums.ldraw.org/forum-7.html)
+--- Forum: LDraw Editors and Viewers (https://forums.ldraw.org/forum-11.html)
+--- Thread: Export of .mpd to single 'stand-alone' .ldr file ? (/thread-7398.html)

Pages: 1 2 3


Re: Export of .mpd to single 'stand-alone' .ldr file ? - Rob - 2012-12-22

As if often the case (!) - the mistake was mine - not the model.

Error in my code meant that parent matrix was not being applied to sub-model lines if the sub-model line was a reference to another sub-model.

Courmorant model now flattens correctly (my flattened version attached).


Re: Export of .mpd to single 'stand-alone' .ldr file ? - Steffen - 2012-12-22

Hi, I'd just like to add my 0.02 € to this thread,
to avoid confusion.
The 0 ROTATION element is just MLCad specific,
and it has nothing to do with MPDs or how they rotate the files contained within them.
It only tells MLCad WHERE to put the rotation point for the GUI,
has nothing to do with the rotation point around which the part gets rotated when used in its parent mpd!
Make sure you do _NOT_ use this line for the rotation when inlining into a single ldr...


Re: Export of .mpd to single 'stand-alone' .ldr file ? - Merlijn Wissink - 2014-10-26

I hope it's not a problem that I bump this very old topic, but I'm also interested in a .mpd to .ldr converter.
Is there any converter available?
I suppose the topic starter got something to work, because he said he needed such a converter for animations and he has a lot of animations on his website.


Re: Export of .mpd to single 'stand-alone' .ldr file ? - Michael Heidemann - 2014-10-26

Maybe you should give MPDCenter a try Smile


Re: Export of .mpd to single 'stand-alone' .ldr file ? - Dave Meister - 2015-02-23

Give the attached Python script a try (test example included) - I implemented it because I'm trying to add a motor to the 42005 Lego Monster Truck following the MPD file from rebrickable, but I couldn't find any tool to give me a flat LDR file so I can use tools like Bricksmith to bisect the model since the steps provided in the MPD file are pretty useless when you're trying to figure out how to build this thing...

Supports nested LDR references, but does NOT support references to other MPD files.
Works only on one file at a time.

How to use:
unzip, then you should have a mpd2ldr.py file - that file must be executable.
Now just call "./mpd2ldr.py filename.mpd" and the output will be filename.ldr
Has to be used from the command line (I've tried it on a Mac only)

I hope it works for you, and please forgive me if I don't provide support Smile


Re: Export of .mpd to single 'stand-alone' .ldr file ? - Nathanel Titane - 2015-02-24

Use LeoCAD, it now has full MPD support and can easily export the main model assembly to ldr, hassle free.


Re: Export of .mpd to single 'stand-alone' .ldr file ? - Mattia Zamboni - 2015-06-25

Well...
I see all kind of scary rocket-science type of answers in this thread.
I personally have always done the MPD to LDR conversion directly in MLCAD using the export menu.
In case you have multiple steps it generates an LDR file for each step, but you just take the last step (biggest file size) and you got your converted file.
As simple as that :-)

- Mattia