|
LdrDat2Obj or LdrDat2Dxf Programs I made this program based on old Dat2Dxf program which apparently isn't supported anymore. Download links is at bottom of site. I recommend you to read entire site, since there's some important notes related to functions of either converters. There is 2 different converters. One converts Ldraw to Dxf, other to Obj. Dxf is more widely supported but very limited on color and no alpha support. Obj have much more support for textures and alpha so clear pieces is possible without having to set colors again like with dxf format. I will note differences between dxf and obj export when needed. Using it is very simple actually. If its first time you have to find parts directories for it. It will need to know location of ldraw.exe. it assumes that it is in P, Parts and models sub directories of folder the ldraw.exe is in. To convert a single Dat or Ldr to a Dxf/Obj file, you just click on Change Import/Export button.First it will show a file dialog, use that to find and open a Dat or ldr file, then click on open button. Next it will open the save dialog. use it same way the usual save dialogs. Now it will show the filenames with directories. Review ti make sure they're correct. Now, click Convert button. it will show a progress window, and main window will hide away. When its done the main window will come back and you have nifty Dxf or Obj to use in rendering program! If you want to convert a bunch of dat or ldr files, you can click on Batch Convert. New window will appear. You can browse and add files from any location but it can only export to single location. The dxf files will be named same as dat and ldr but with extension of dxf or obj and in export folder. When you're done just hit convert button and it will get busy. There is 3 layering, or grouping choices. Line Number as Layer is best since it will make each part of model as its own layer. For example, if you import dxf or obj of 2 bricks into Bryce, then ungroup it. It will be 2 models of bricks. Other is step as layer. It will set steps to layer. for example if there is 3 bricks added in a step those 3 bricks will be in same layer. Third happens if both options is not checked. it will be single layer, meaning you cant split or ungroup it. *Note Bryce sets all colors to its own groups on top of format's own native grouping, I don't know if it applies for other programs, so if there's no other grouping type, it will be set to same color grouping, but if there's grouping to "line number" then each brick, if have more than one color, will be split to each color. I can't fix this "feature" in Bryce. Bow Tie repair is useful if exported model have bow ties. I'm not sure if its working properly but there's 2 options, one thats quick and dirty and one that checks slowly. I suggest you don't use it unless model have bow ties. Ignore all file errors tells LdrDat2Dxf or LdrDat2Obj to ignore any file not found errors, which is good for certain problems such as not having a unofficial file or such. Remove Studs is just that, while it processes, if it finds stud sub part references it skips over that file, so model will not have any studs. it will lessen polygon count. In some cases, a very large polygon count savings. Dxf file you have just converted from Ldraw format is now ready to be imported into any rendering program! Obj needs just one thing to be done, you need to copy Legocolors.mtl (included in LdrDat2Obj download) to same folder your new obj file is in, then it's ready to be imported! *minor note: Legocolors.mtl was hand-written by myself, but I am not expert on this, so colors is little off, but if you're good on making MTL file, you could help me by making more accurate minerals file, but that's the advantage of having minerals separate from obj files. I also didn't define any dither colors, but that file have all of regular lego colors ready. It's still beta so feedback and bug reports is very important for me, and thanks in advance for any of them. Site last updated: 11/8/2004 Download Links: Main programs: LdrDat2Dxf and LdrDat2Obj Download Microsoft NET Framework here. It's needed to run installer, LdrDat2Dxf or LdrDat2Obj. If it don't work, and you have installed .Net framework installed, go to here for Win Nt/2k or here for Win 9X. |