![]() |
File paths in various programs - 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: File paths in various programs (/thread-28821.html) |
File paths in various programs - N. W. Perry - 2025-05-14 I'm seeking your wise advice on proper file paths (relative or absolute) for the various LDraw tools, and why they don't seem to behave the same between themselves. In my ldraw folder I have these sub-directories, among others: p/ parts/ Unofficial/ User/ Unofficial (for uncertified tracker parts) and User (for my own parts) each have their own p/ and parts/ subfolders, so they are both valid ldraw libraries. User also has a number of subfolders for parts authoring projects. So I'm working on a part in one of those project folders in the User library, and it uses a custom primitive that is also in the User library (obviously in User/p/). To get this primitive to appear in LDPE, I have to give it this path: User\p\48\prim.dat. Some notes:
Now on to LDView. When I open the same part in LDView, the custom primitive isn't found, even though both User and User/p/ are set as extra search paths. To make the prim appear, I have to change the pathname to the full pathname from my disk (so Users/nwperry/ldraw/User/p/48/prim.dat). Finally, out of curiosity I tried LDCad. In this case, the full pathname didn't work, but it was sufficient to just use 48\prim.dat as you would expect in any part file. User is designated as one of my unofficial libraries in LDCad's settings, and in this case the behavior is as I expect: it finds the primitive in the p folder in that library. So the question is, could I do something differently so that all these programs will find the custom primitive, without having to have a different version of the part file for each different tool? And are all these programs behaving as expected? It seems odd that I have an unofficial primitive in an unofficial library, but the programs don't find it there even though I've specifically set them up to do so. RE: File paths in various programs - Roland Melkert - 2025-05-14 (9 hours ago)N. W. Perry Wrote: I'm seeking your wise advice on proper file paths (relative or absolute) for the various LDraw tools, and why they don't seem to behave the same between themselves. I would recommend fully separating libraries and user content. For example I use these items in my (ldcad) search path: d:\LDraw\complete-2504.zip d:\LDraw\ldrawunf.zip d:\LDraw\projects\ You could optionally unzip the zips into their own subfolders. This assumes the used tools differentiate between normal and library locations. If not you will probably need to merge the two zip contents like so: d:\LDraw\library\p (from complete.zip) d:\LDraw\library\parts (from complete.zip) d:\LDraw\library\unofficial\p (from ldrawunf.zip) d:\LDraw\library\unofficial\parts (from ldrawunf.zip) d:\LDraw\projects\ ps: LDCad will still (also) look in the unofficial subfolders of library locations/zips, but personally I don't use that much. note: also using locations which are sub locations of libraries might crash LDCad ![]() RE: File paths in various programs - N. W. Perry - 2025-05-14 (8 hours ago)Roland Melkert Wrote: I would recommend fully separating libraries and user content. This is actually how I'm set up now, as far as LDCad is concerned. Additionally, I do have the zips unzipped; the only thing is that complete.zip is not a subfolder, it's just the p and parts subfolders at the top level of the ldraw directory. In other words (using your directory names): d:\LDraw\complete-2504.zip d:\LDraw\p\ d:\LDraw\parts\ d:\LDraw\ldrawunf.zip d:\LDraw\unofficial\ d:\LDraw\projects\ Quote:This assumes the used tools differentiate between normal and library locations. So if I were to use the ldparteditor temp folder, this would be my hierarchy exactly. Maybe I should do that? Quote:ps: LDCad will still (also) look in the unofficial subfolders of library locations/zips, but personally I don't use that much. No crashes as of yet. The only thing that happens with LDCad is that if I search a part, it won't show me both the official and unofficial version(s) of the part, only the one that is set highest in the preferences. (This is probably intended behavior.) RE: File paths in various programs - Travis Cobbs - 2025-05-14 (9 hours ago)N. W. Perry Wrote: Now on to LDView. When I open the same part in LDView, the custom primitive isn't found, even though both User and User/p/ are set as extra search paths. To make the prim appear, I have to change the pathname to the full pathname from my disk (so Users/nwperry/ldraw/User/p/48/prim.dat). I just tested on my Mac, and LDView 4.6 was able to find 48/user-p.dat in <ldraw dir>/User/p/48 when <ldraw dir>/User/p was in its extra search dirs. This is the expected behavior, so I'm not sure why it wouldn't work for you. What OS are you using? |