Viewing an interactive model in Radiance via rview/rvu
September 10, 2009 2:54 PM   Subscribe

Radiance and x11 won't work well together, and I can't figure out what's going on!

I am on Mac OS X 10.5.6, and I'm just learning to use Radiance. According to the book that I've been using, I should be able to interactively view my model world by using rview (same as rvu?). When I try to run rview/rvu through the terminal, though, I keep getting the following error:

rvu: cannot open X-windows; DISPLAY variable set?
rvu: fatal - cannot initialize x11

I get the same error even when I start up x11 before running rvu. I tried setting the DISPLAY variable to 0 under bash_profile, but this has not solved the problem.

Everything else works fine: I can generate nicely ray-traced static pictures, no problem.

I've been Googling around for solutions for about two hours now, but am having the damndest time finding anything -- perhaps because I don't know what keywords to use.

Does anyone have any idea how I could fix this problem? Please assume I know nothing about either X11 or Radiance. :-) Thanks in advance!
posted by tickingclock to Computers & Internet (3 answers total)
 
Did you set DISPLAY to "0" or ":0"? The colon is important. Set it to ":0" and make sure X11 is running before you run any X apps.

However, the behavior you describe is strange. X should "just work" under 10.5; you shouldn't have to manually set the DISPLAY variable. You might want to try intsalling XQuartz, a more up-to-date version of X11 which fixes several bugs. If you go down this path, remove the line setting DISPLAY that you put in your .bash_profile, as it should be automatically set to something that will automatically start X11 if needed.
posted by zsazsa at 3:00 PM on September 10, 2009


Best answer: Environment variables last for the duration of the current process. Exported env vars persist to child processes. Variable assignments on the same line as command execution are visible to that command.

Also, X display values have a colon in them. The hostname before the colon is optional, if you're connecting to localhost. (X is a network protocol, didyaknow? It could be "cmillersComputerAcrossTheNet:0.0" and it would appear here!) After that is a X-server number, and a screen number. So, ":0.0" is what you should probably be using.

Do this.

$ DISPLAY=:0.0 rvu

or
$ export DISPLAY=:0.0
$ rvu

If you're not sure about "rvu", try "xeyes" -- a ubiquitous X toy app.
posted by cmiller at 3:06 PM on September 10, 2009


Response by poster: Thanks for the replies! cmiller's method worked -- sadly, the interactive view is not nearly as interactive as I was hoping. But that's okay!

I looked into downloading XQuartz, as zsazsa suggested, but it requires 10.5.8 or later, unfortunately -- I'm currently on 10.5.6.
posted by tickingclock at 8:19 AM on September 11, 2009


« Older Punk Leather Jacket Rehabilitation   |   Australian wine recommendation Newer »
This thread is closed to new comments.