LDraw.org Discussion Forums

Full Version: Issue with Main ldr in LDCad
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
So firstly, let me thank you Roland for a terrific tool. I've tried a couple of LDraw editors as well as LDD itself and I find your tool by far the easiest to use.

Now, let's see if you can help me with a problem I'm having.


I have an ldr file from another builder that posted his MOC at rebrickable.
When I open that ldr in LDCad, the main model isn't built and complete. But when I open that ldr in MLCad, it's complete. I've also opened other ldr files from this builder in LDCad and they work.
I've included two as examples for you to troubleshoot with.
peterbilt389 works.
peterbilt379 doesn't.
Thanks Darren,

De 397 model has type 2 lines which are used for indicating extremely simplified wires.

By design LDCad deems anything with type 2 lines a part and as such tries to prepare the whole model for rendering as a single entity. This results in too much data (6.5 million vertices) which in result cancels the preparation. The cutoff is controlled by an option but you generally don't want it to try as it might take ages to prep.

To fix this you simply move any type 2 stuff (together with some supporting parts etc if needed ) to a submode.

I've attached a corrected version in which I have done this for you.
(2016-07-12, 16:57)Roland Melkert Wrote: [ -> ]Thanks Darren,

De 397 model has type 2 lines which are used for indicating extremely simplified wires.

By design LDCad deems anything with type 2 lines a part and as such tries to prepare the whole model for rendering as a single entity. This results in too much data (6.5 million vertices) which in result cancels the preparation. The cutoff is controlled by an option but you generally don't want it to try as it might take ages to prep.

To fix this you simply move any type 2 stuff (together with some supporting parts etc if needed ) to a submode.

I've attached a corrected version in which I have done this for you.

Thank you so much. It would have taken me a while to figure out what the Type 2 parts are. I'm pretty new to this. So I appreciate so much what you did. 
I just went to your site to figure out how to send you a donation. The fact you do this for absolutely nothing is incredible.
I'm going to fire off a postcard just as soon as I can get out to a store and find something meaningful from where I live.

Thanks again.
(2016-07-13, 3:22)Darren Carlson Wrote: [ -> ]Thank you so much. It would have taken me a while to figure out what the Type 2 parts are. I'm pretty new to this. So I appreciate so much what you did. 
I just went to your site to figure out how to send you a donation. The fact you do this for absolutely nothing is incredible.
I'm going to fire off a postcard just as soon as I can get out to a store and find something meaningful from where I live.

Thanks again.
Thanks, LDCad is just my way of giving back to LDraw and the internet itself as I use lots of free / Open source stuff myself Smile
Ok, so I have another model with the same problem. I've included it here for you but I'd like to understand myself how to open it in MLCad and move the Type 2 parts into a submodel. I'm sure this is going to continue to happen so better I understand it myself if you'd be so kind as to guide me.
(2016-07-13, 18:06)Darren Carlson Wrote: [ -> ]Ok, so I have another model with the same problem. I've included it here for you but I'd like to understand myself how to open it in MLCad and move the Type 2 parts into a submodel. I'm sure this is going to continue to happen so better I understand it myself if you'd be so kind as to guide me.

This will be easy to correct in the new 1.6 version but the last Alpha has a bug preventing it at the moment.

In MLCad you can create a new submodel and then cut paste all the lines (as seen in the top window) starting with '2' into it. But as these lines are used as hardly noticable eletric wires you could also consider to just hide them using MLCad's permanent hide feature.
(2016-07-13, 18:29)Roland Melkert Wrote: [ -> ]
(2016-07-13, 18:06)Darren Carlson Wrote: [ -> ]Ok, so I have another model with the same problem. I've included it here for you but I'd like to understand myself how to open it in MLCad and move the Type 2 parts into a submodel. I'm sure this is going to continue to happen so better I understand it myself if you'd be so kind as to guide me.

This will be easy to correct in the new 1.6 version but the last Alpha has a bug preventing it at the moment.

In MLCad you can create a new submodel and then cut paste all the lines (as seen in the top window) starting with '2' into it. But as these lines are used as hardly noticable eletric wires you could also consider to just hide them using MLCad's permanent hide feature.

Got it. Took me a bit because they don't start with a 2 in that window. They might have in previous versions. Now they appear as "/Line". Rereading your reply caused me to see 'lines' and put it together. It renders now. Thanks again Roland.
If you're ok with just deleting the lines, a text editor is probably the fastest way to do this.

In an advanced editor like notepad++ (if you're using windows) you can very simply find all lines starting with 2 by searching for '^2' and delete them.
(2016-07-13, 18:46)Niklas Buchmann Wrote: [ -> ]If you're ok with just deleting the lines, a text editor is probably the fastest way to do this.

In an advanced editor like notepad++ (if you're using windows) you can very simply find all lines starting with 2 by searching for '^2' and delete them.

Yes they are hardnly noticable anyway.

In 1.6 you will simply be able to move them using the reorganize menu, then save to disk and reload the model Smile

[attachment=2366]

I'm also considering offering an option to 'upgrade' during loading.
(2016-07-13, 18:46)Niklas Buchmann Wrote: [ -> ]If you're ok with just deleting the lines, a text editor is probably the fastest way to do this.

In an advanced editor like notepad++ (if you're using windows) you can very simply find all lines starting with 2 by searching for '^2' and delete them.

That's what I'll do next time. I just opened it in Notepad to have a look and it's really straightforward. I'll get Notepad++ so it's easier to find the right lines though. Rotten search facilities in the basic Notepad.
(2016-07-13, 19:02)Roland Melkert Wrote: [ -> ]
(2016-07-13, 18:46)Niklas Buchmann Wrote: [ -> ]If you're ok with just deleting the lines, a text editor is probably the fastest way to do this.

In an advanced editor like notepad++ (if you're using windows) you can very simply find all lines starting with 2 by searching for '^2' and delete them.

Yes they are hardnly noticable anyway.

In 1.6 you will simply be able to move them using the reorganize menu, then save to disk and reload the model Smile



I'm also considering offering an option to 'upgrade' during loading.
I assume that's 1.6 in that screenshot. Is there a way in 1.5 to make the grid/rotation control in the lower left stay out in the open when you put colour bin and parts bins on the left side? I'm really liking the layout you're using with the colour and parts bins on the left, models across the bottom.
Ok, here I am again on bended knee. In that same file, trailer_pup.ldr can't be edited in LDCad. I see that it doesn't have the same name as the other submodels. My suspicion is the original designer built it in a separate ldr and then imported it as an entire placeholder.

I used MLCad to export all of the submodels and opened the resulting trailer_pup.ldr but I still can't edit it.

It's all just data in an xml file so it has to be fixable but I have no idea what needs to change to fix it.
(2016-07-13, 19:28)Darren Carlson Wrote: [ -> ]I assume that's 1.6 in that screenshot. Is there a way in 1.5 to make the grid/rotation control in the lower left stay out in the open when you put colour bin and parts bins on the left side? I'm really liking the layout you're using with the colour and parts bins on the left, models across the bottom.

Yes it is 1.6 but 1.5 can also be setup to look like that.

Open a second bin using the view menu, it will float by default.
Drag it down to the bottom and then press and hold ctrl to dock it.
(2016-07-13, 19:48)Darren Carlson Wrote: [ -> ]It's all just data in an xml file so it has to be fixable but I have no idea what needs to change to fix it.

I think you forgot to attach the fie, LDraw doesn't use XML files though so I'm not sure what you mean.
(2016-07-13, 20:01)Roland Melkert Wrote: [ -> ]
(2016-07-13, 19:48)Darren Carlson Wrote: [ -> ]It's all just data in an xml file so it has to be fixable but I have no idea what needs to change to fix it.

I think you forgot to attach the fie, LDraw doesn't use XML files though so I'm not sure what you mean.

Here it is. Sorry. Misspoke. Not xml but rather just a text file defining all of the elements in the model.
I've attached the larger ldr with all of the submodels as well as just the individual ldr that I exported out of the larger ldr with MLCad thinking that might work.
[quote pid='22473' dateline='1468440632']
Here it is. Sorry. Misspoke. Not xml but rather just a text file defining all of the elements in the model.
I've attached the larger ldr with all of the submodels as well as just the individual ldr that I exported out of the larger ldr with MLCad thinking that might work.
[/quote]

The trailer model has multiple type 2 lines, the large mpd seems to be a problem in general as it won't load at all in 1.5 for me (it does in 1.6)

I'll have to investigate what's going on there but it's probably a 1.5 known (and fiixed in 1.6) bug.

I'll get back to you when I have more info.
(2016-07-13, 20:59)Roland Melkert Wrote: [ -> ][quote pid='22473' dateline='1468440632']
Here it is. Sorry. Misspoke. Not xml but rather just a text file defining all of the elements in the model.
I've attached the larger ldr with all of the submodels as well as just the individual ldr that I exported out of the larger ldr with MLCad thinking that might work.

The trailer model has multiple type 2 lines, the large mpd seems to be a problem in general as it won't load at all in 1.5 for me (it does in 1.6)

I'll have to investigate what's going on there but it's probably a 1.5 known (and fiixed in 1.6) bug.

I'll get back to you when I have more info.
[/quote]

That's interesting. It does load for me in 1.5. Whenever you can. I've already started editing what I can since the only thing I'll end up keeping is the frame and running gear. All of the power functions and decking are coming off.
I appreciate your help.
(2016-07-13, 21:28)Darren Carlson Wrote: [ -> ]That's interesting. It does load for me in 1.5. Whenever you can. I've already started editing what I can since the only thing I'll end up keeping is the frame and running gear. All of the power functions and decking are coming off.
I appreciate your help.
I was using an older LDraw library which brings one of the fixed bugs to the surface, 1.5 with the 1502 library loads it just fine indeed.

The trailer behaves like a single brick as that whole (sub)model is 'degraded' to a part because of the type 2 lines in it. One advantage of that though it should render like crazy fast Smile

To fix the type 2 lines you could use the notepad++ method on the large mpd Niklas wrote about.
(2016-07-13, 21:42)Roland Melkert Wrote: [ -> ]
(2016-07-13, 21:28)Darren Carlson Wrote: [ -> ]That's interesting. It does load for me in 1.5. Whenever you can. I've already started editing what I can since the only thing I'll end up keeping is the frame and running gear. All of the power functions and decking are coming off.
I appreciate your help.
I was using an older LDraw library which brings one of the fixed bugs to the surface, 1.5 with the 1502 library loads it just fine indeed.

The trailer behaves like a single brick as that whole (sub)model is 'degraded' to a part because of the type 2 lines in it. One advantage of that though it should render like crazy fast Smile

To fix the type 2 lines you could use the notepad++ method on the large mpd Niklas wrote about.
And TADA it works. LOL.

So any time I have a problem, the first thing I'm going to do is open the .mpd or .lpr in Notepad++ and delete the 2 lines. Smile

I just have to figure out how to search for lines that begin with something in Notepad++. Regardless, I got it done.
Thanks for the help.
Looking forward to the Beta of 1.6. If you have a distribution list you're using to notify testers for you, I'd be happy to be added when you're considering it a Beta.
(2016-07-13, 19:59)Roland Melkert Wrote: [ -> ]
(2016-07-13, 19:28)Darren Carlson Wrote: [ -> ]I assume that's 1.6 in that screenshot. Is there a way in 1.5 to make the grid/rotation control in the lower left stay out in the open when you put colour bin and parts bins on the left side? I'm really liking the layout you're using with the colour and parts bins on the left, models across the bottom.

Yes it is 1.6 but 1.5 can also be setup to look like that.

Open a second bin using the view menu, it will float by default.
Drag it down to the bottom and then press and hold ctrl to dock it.
I had missed this reply earlier. Thank you so much. This is so much better.

When I finish the design work on this model, I'm going to start putting together a list of 'must know' items for LDCad and begin some tutorial documentation. I've learned much in the last few weeks and I'd like to share that knowledge.
And I figured out how to find new lines beginning with a 2. Google is wonderful.