Converting LDD parts to LDraw


Converting LDD parts to LDraw
#1
I found this article. There described way how to convert some parts. For automatic separation this long string to groups of 9 numbers you can use text editor with function of RegEx (I used EmEditor because I had problems with them in Notepad++)
In your program you have to find
Code:
(\s\S+){9}
and replace to
Code:
\0\n
(You have to put space-bar before first number) and you will have separated strings of 9 numbers. Then add 3 16 in front of each string using column editor.
Reply
Re: Converting LDD parts to LDraw
#2
But i have a question. How to set normal orientation. Information in article didn't help me. I scale part in MLCad, but information about angles is wrong(or I do something wrong). If you know tell me right angles in LDDP. Thanks.
Reply
Re: Converting LDD parts to LDraw
#3
Ok. I have found my mistake and tried to convert first part. It was Minifig Broom. It is not god now, but if you want it for you renders you can use it. Here it is. It can be normal rendered (using Mesh Enchancer). Hope somebody will make it good enough for part tracker.
Reply
Re: Converting LDD parts to LDraw
#4
One more try. Phoenix from Harry Potter. It needs a lot of work. But I don't know how to do it. File here.
I painted problem places in different colors. There are a lot of holes after I put studs primitives. I don't know how to build them.
Reply
Re: FAWKES 43744.dat
#6
Hey Stan,

you can use the normals to generate lines and optional lines. For each position (vertex) there is a normal in the 3dxml file.

If there are two triangles next to each other, they have two common vertices. If these vertices have the same normals, you can generate an optional line between them. For the control points you can use each third (not common) vertex of the triangles. If the normals of the common vertices differ, you can generate a normal line between them.

I have done this for the FAWKES (43744.dat).

This file still needs much work to become an ldraw part. It exists of triangles, lines and optional lines only. There are no primitives and if there are planar adjacent triangles there is even so an optional line between them.

Rolf
Reply
Re: Converting LDD parts to LDraw
#5
Also. I don't know how to smooth part. I saw hood part. 30381 ldraw part. It realy smoothed. How?
Reply
Re: Converting LDD parts to LDraw
#7
If you're talking about smoothing while rendering in viewers as Ldview, this is done using condlines. You can insert them with the help of Edger2, which is part of the Letgui package.
Reply
Re: Converting LDD parts to LDraw
#8
Thanks. I understand how to add edge lines with edger. But how to add smoothing condlines? I tried different angles, but no result.
Reply
Re: Converting LDD parts to LDraw
#9
LDView only smooths a file if it detects it is a part. This happens either because it came from a parts directory (<LDraw>\parts or <LDraw>\Unofficial\parts) or it has a header indicating it is a part. Try adding the following near the top of your file:

0 !LDRAW_ORG Unofficial_Part
Reply
Re: Converting LDD parts to LDraw
#18
Travis Cobbs Wrote:
-------------------------------------------------------
> LDView only smooths a file if it detects it is a
> part.
> 0 !LDRAW_ORG Unofficial_Part
BTW, is there a good reason not to smooth subparts? it's kind of annoying to have to make it temporarily a part to check smoothing while creating a subpart.
Reply
Re: Converting LDD parts to LDraw
#20
Smoothing requires all of the geometry in the part to be collapsed together so that adjacent polygons between the constituent components can be smoothed. I could probably have it smooth sub-parts if they are opened directly; I'd have to check the logic.
Reply
Re: Converting LDD parts to LDraw
#10
Travis, Thank you. It helps.
Reply
Re: Converting LDD parts to LDraw
#11
Thanks to everybody. I made one more part. Pipe Wrench. I converted it from LDD. Scales. Set orientation. Add edges with Edger2. Rebuild handle using primitives. You can download it here.
I have no rights to add parts to part tracker. But hope someone will post it there. This part has one problem. There are little holes between handle and wrench. But i don't know how to fix it.
Reply
Re: Converting LDD parts to LDraw
#12
It is great news that you are working on these conversions, as we always welcome new authors.

The LDraw Contributor Agreement was introduced to ensure that we have permission to distribute the work of parts authors. We cannot have files being submitted by a surrogate author. Stan, please follow the directions in the Submit New Parts paragraph at http://www.ldraw.org/library/tracker/ and you will be provided with access to the Parts Tracker.

Thanks, Chris
Chris (LDraw Parts Library Admin)
Reply
Re: Converting LDD parts to LDraw
#14
The wrench geometry has 12 facets around its base, while LDraw cylinders have 16 facets, so I think someone will have to manually make the join.
Reply
Re: Converting LDD parts to LDraw
#19
Travis Cobbs Wrote:
-------------------------------------------------------
> The wrench geometry has 12 facets around its base,
> while LDraw cylinders have 16 facets, so I think
> someone will have to manually make the join.
One solution for that is to delete the triangles at the base of wrench enlargement, create an "unmatched edge" line there with Edger2, then build a joint between this line and the (inlined) 4-4edge at the end of handle using Coverer. Of course since the mesh will be changed condlines will have to be generated again.
Reply
Re: Converting LDD parts to LDraw
#13
Ok. I send request to registration me as part author. And I have few questions. Can other users edit parts from part tracker and send them back? I don't know how to do a lot of things, so I can't do some things. Thanks.
Reply
Re: Converting LDD parts to LDraw
#15
I think your questions are answered at http://www.ldraw.org/library/tracker/ref/policy/ . Generally other people should give you the chance to fix problems, unless three months have passed with no response. If you don't yet have the skills, and would like other users to improve your submission, please write something like "Anyone can make changes to this part" in the comments at submit time.

Chris
Chris (LDraw Parts Library Admin)
Reply
Re: Converting LDD parts to LDraw
#16
Hi Chris,

Just noticed that the article needs changing, specifically the reference to asking on LUGNET should be replaced by direct links to this forum.

I don't have access to edits on the PT.

Tim
Reply
Re: Converting LDD parts to LDraw
#17
LUGNET reference removed. I'd prefer fixes to go into the Parts Tracker than being posted here. Otherwise we risked a "branched" development.

Chris
Chris (LDraw Parts Library Admin)
Reply
Re: Converting LDD parts to LDraw
#21
I post part on the tracker.
I don't know how to change origin. So if someone now how you can do it.
Reply
Re: Converting LDD parts to LDraw
#22
Great, Stan!

> I don't know how to change origin. So if someone now how you can do it.
I did some corrections to the door and uploaded it on PT. Changing origin is easy, just select and move everything in MLCad until part is correctly positionned around point 0,0,0.
Reply
Re: Converting LDD parts to LDraw
#23
Simply open it with MLCad, move the part to the desired location, then save it !
Reply
« Next Oldest | Next Newest »



Forum Jump:


Users browsing this thread: 1 Guest(s)