LDraw.org Discussion Forums

Full Version: Cannot open include file lg_defs.inc
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
It's been a very long time since I last tried to use POVRAY. I just now exported a model from LDView into POVRAY, but when I try to render this model in POVRAY, I get the error message "Parse Error: Cannot open include file lg_defs.inc". 

I've tried searching tis site (not just the Forums), and I've searched Google as well, but I cannot find anything that actually helps me fix this error. 

Please advise. 

Have you downloaded the LGEO package? If so, is the path to the LGEO folder in the POV-Ray search paths?
(2023-01-10, 21:44)Orion Pobursky Wrote: [ -> ]Have you downloaded the LGEO package?
If so, is the path to the LGEO folder in the POV-Ray search paths?

I've used the All-in-One Installer, so I presume I've got that library somewhere on my PC. 

I presume it's this folder... 

How do I check the search paths for POV-RAY, please? 
I looked for a means of configuring its default parameters, but like I said, it's been an age... 

Just on a lark, did some experimenting... 

Quote:#version 3.6;

#declare Library_Path="G:\LDraw\LGEO"
#declare Library_Path="G:\LDraw\LGEO\lg"
#declare Library_Path="G:\LDraw\LGEO\ar"

// Parse Error: Illegal escape sequence in string.

Sigh...  :-(
This is for 3.6 but it applies to 3.7 as well:

Adding the LGEO path to the "[Permitted Input Paths]" should fix your issue.
You mean, like this? 

[Permitted Input Paths]

Unfortunately, I'm still getting the same (original) message.  

Also, since LDView is the program exporting my model into POVRAY format, why isn't that ap including all of the appropriate library paths in the first place? 

Ok here's the solution:

Click the INI button on the menu

In the command line options box add the following:
+L "G:\LDraw\LGEO" +L "G:\LDraw\LGEO\lg" +L "G:\LDraw\LGEO\ar"

Click save

Render file

Failed to set render options (Failed to parse command-line option).
See message pane for more details.

(Message pane says): 
"This is not a valid command line." 

Tried again, this time without quote marks, but got same error message.
Hmm. Try without space between the +L and path and with the quotes?
We have a winner!!  ^_^  

+L"G:\LDraw\LGEO" +L"G:\LDraw\LGEO\lg" +L"G:\LDraw\LGEO\ar"

And after all of this hassle, it gives me a very tiny image.  ^_^  

I'm done for the night. Tomorrow will be soon enough, for getting a properly large image. 

Thanks for the help!!