Jump to content

Photo

LDD2OBJ


  • Please log in to reply
19 replies to this topic

#1
jamesster

jamesster

  • Moderator
  • PipPipPipPipPip
  • 2,602 posts
I didn't create this program, I am simply redistributing it under the GNU General Public License.

Download

Requires Python. Extracts LDD's Assets.lif file via JrMasterModelBuilder's LIF Extractor (which was also released under the GNU GPLv3; see "License (LIF extractor).txt"), then converts the resulting extracted .g brick models to OBJ format - please note that textured bricks are not yet supported.

Again, not made by me (feel free to redistribute it yourself, don't worry, the programmer is OK with it), but I have tested it and it works perfectly. Simply extract the zip, locate Assets.lif (found at "C:\Program Files (x86)\LEGO Company\LEGO Digital Designer" by default), copy it to the same folder as the program, and run LIF2OBJ.jar.
  • le717 thanked this

#2
LUModder

Hey look, source code I can decompile (loljk)

 

Really gotta try this out when I'm bored.



#3
Alcom1

nST0lUh.png

Why yes, I do as a matter of fact... why?



#4
LUModder

-snip-
Why yes, I do as a matter of fact... why?

Which version?

#5
LUModder

0af2b032eb7326ca0ac88cb115eeea9b.png

IT'S RIGHT THERE! (even though I have already extracted it :P )



#6
ProfessorBrickkeeper

ProfessorBrickkeeper

    Keeper of the Bricks

  • Members
  • PipPipPip
  • 158 posts
Gotta try this out soon... This looks awesome and promising....

#7
le717

Is this the tool created by HJMediaStudios by any chance?



#8
jamesster

jamesster

  • Moderator
  • PipPipPipPipPip
  • 2,602 posts

nST0lUh.png
Why yes, I do as a matter of fact... why?

I had to re-install Python and enable... Uh... Some option having to do with a path. Sorry I can't be more specific, I don't remember exactly what it was, but download the latest version of Python and when it asks what components to install, enable the one mentioning the word "path". :P

0af2b032eb7326ca0ac88cb115eeea9b.png
IT'S RIGHT THERE! (even though I have already extracted it :P )

I can't be sure unless I see the entire folder, but I have the feeling there's some files missing there - care to post a bigger screenshot?

Is this the tool created by HJMediaStudios by any chance?

No.

#9
le717



-snip-
Why yes, I do as a matter of fact... why?

I had to re-install Python and enable... Uh... Some option having to do with a path. Sorry I can't be more specific, I don't remember exactly what it was, but download the latest version of Python and when it asks what components to install, enable the one mentioning the word "path". :P
I understand. It seems the dev has made use of the system PATH, where you can just "python LIFExtractor.py" and it will run. The Python 3.3 installer has an option to enable this. If you can, you should contact him and ask him to swap to the x86 EXE so more people don't have this error.

And, unless the dev wrote a Java UI into this, and somehow managed to overwrite the .jar shell extension to run it with Python, it also requires Java. :P



Is this the tool created by HJMediaStudios by any chance?

No.
Oh, by someone else? Interesting...

#10
bartvbl

bartvbl

    g33k

  • Donators
  • PipPipPipPip
  • 251 posts

Awesome! Gonna try it out this evening.

 

0af2b032eb7326ca0ac88cb115eeea9b.png

IT'S RIGHT THERE! (even though I have already extracted it :P )

 

By the looks of it you extracted the program into the LDD folder in program files. Perhaps it doesn't have permission to read the directory contents? Try copying it over to the dekstop.



#11
TheDoctor

Awesome! Gonna try it out this evening.

0af2b032eb7326ca0ac88cb115eeea9b.png
IT'S RIGHT THERE! (even though I have already extracted it :P )

 
By the looks of it you extracted the program into the LDD folder in program files. Perhaps it doesn't have permission to read the directory contents? Try copying it over to the dekstop.


If you ran the program and you can see the file, It can see the file. It's not a matter of read permissions.

#12
bartvbl

bartvbl

    g33k

  • Donators
  • PipPipPipPip
  • 251 posts

<snip>
If you ran the program and you can see the file, It can see the file. It's not a matter of read permissions.

It is, actually. The icons are missing from the UI. they're in the res directory, so the program probably loads them at runtime, and can apparently not access those either.

 

Other than that, the tool seems to work as advertised.

I'm assuming that the python script indeed gets executed the way le717 suggested; I have python on my PATH, and it worked on my end with no problems.

Thanks for posting it!



#13
JrMasterModelBuilder

JrMasterModelBuilder

    LR, LR2, LDR, and LDD Extractor Creator

  • Contributors
  • PipPipPipPip
  • 526 posts

Hmm, works perfectly. I think it should use db.lif instead of Assets.lif because db.lif is updated more frequently, but it works great, even on OS X.

 

Are we being secretive about the developer for some reason?



#14
JrMasterModelBuilder

JrMasterModelBuilder

    LR, LR2, LDR, and LDD Extractor Creator

  • Contributors
  • PipPipPipPip
  • 526 posts

UPDATE:

 

While poking around with the Java applet, I noticed there is a folder containing the source code for the application contained within the JAR (just extract it like a ZIP). I realize Java decompiling is easy but though it was worth noting. It's actually rather simple, I'm surprised it took this long for someone to make this.

 

Also, I can confirm that it executes python by the command line assuming that python is in the path.



#15
scrubs

scrubs

    Newbie

  • Members
  • Pip
  • 3 posts

Hi,

 

I managed to make it work pretty easily, however I noticed that a lot of the obj models generated have missing vertices/faces. See the following picture for an example with the 2X2 bricks.

I only tried it on my mac with python 2.7.1 for now.

 

3003.png