[Radiance-general] rayinit.cal problem

Thomas Bleicher tbleicher at arcor.de
Tue Jan 20 07:34:14 PST 2009


On 20 Jan 2009, at 13:32, Brajesh Lal wrote:

> Thanks Lars and Thomas,
>
> It is working !!
> I copied the rayinit.cal and skybright.cal into project folder. Now  
> "rpict: command is working. Image is rendered and i am able to see  
> in HDR shop.

Definitively a PATH problem, then.

> Well i am not a expert unix guy.... just started with cygwin.....

Be told that you will suffer more than necessary for using cygwin. If  
you have the resources I recommend installing Linux on an old  
computer or setting up a virtual machine with Linux. It will make it  
easier for you to understand Unix.

> Now i really want to fix the problem of PATH for future. Therefore  
> i am explaining my directory structure.
> Under cygwin\home\abc directory  ..... i have folder  "opt" and  
> files .bashrc , .inputrc, bash_profile, BASH_HISTORY

First: According to this you are user 'abc' on your Windows machine.  
Is this correct or did you set this up intentionally? You can verify  
by typing

whoami
pwd

in the console window. The first should give you 'abc' the second '/ 
home/abc'


Second: This 'opt' is not were it is intended to be. That might be  
the problem.

Cygwin creates its own file system 'root' in its installation  
directory (typically "C:\cygwin"). Every command you enter in a  
Cygwin shell will use this as the start for the file system tree. An  
absolute file path in Unix starts with '/' (no dot!). So if you see a  
Unix path '/home/abc' this translates to "C:\cygwin\home\abc".

Following this logic '/opt/radiance/cygwin-radiance_dist-3R9/bin'  
should be found as
"C:\cygwin\opt\radiance\cygwin-radiance_dist-3R9\bin". Just keep the  
files as they are and move the cygwin-radiance_dist-3R9 folder to the  
right location.

You should not mix your project files with files in the distribution.  
You might accidentally destroy essential files.

> bash_profile changed content is given below

Note that there should be a '.' in front of the file name:  
'.bash_profile'. The '.' hides the name for the user so this file is  
somewhat protected. It is still part of the file name and without it  
the file will not be recognised. This may be why you don't have the  
$RAYPATH set correctly.

> # System-wide .bashrc file
> # change the directories if necessary
> PATH=.:/opt/radiance/cygwin-radiance_dist-3R9/bin:$PATH
> RAYPATH=.:/opt/radiance/cygwin-radiance_dist-3R9/lib:$RAYPATH
> MANPATH=/opt/radiance/cygwin-radiance_dist-3R9/doc/man:$MANPATH
> export PATH RAYPATH MANPATH

If you follow the renaming as above these settings should work now.


> then under   cygwin\home\abc\opt\radiance\cygwin-radiance_dist-3R9
>  i have "bin", "doc", "lib" and "obj" folders. and my source files  
> ( now it includes rayinit.cal and skybright.cal) are also into   -  
> "cygwin\home\abc\opt\radiance\cygwin-radiance_dist-3R9"

Move your source files to a folder in your HOME directory ('/home/abc/ 
project1' for example). Keep your Radiance installation clear!

> When i relaunch the cygwin console and  execute $PATH .... i get  
> the following info on the console
> bash: usr/local/bin: /usr/bin: /bin : /usr/X11R6/bin : /cygdrive/c/ 
> Program: No such file or directory.
>
> and when i do $RAYPATH then no message or info comes on the console.

See above. IF you are user 'abc' AND the file is called  
'.bash_profile' it should work.

> for execution of source file - once i am inside the "cygwin\home\abc 
> \opt\radiance\cygwin-radiance_dist-3R9" ditectory
> I do
> 1. export PATH=$HOME/opt/radiance/cygwin-radiance_dist-3R9/bin/:$PATH

What you do here is what should happen in the config file. You only  
did change the PATH setting, but did not create a RAYPATH. Therefore  
you could use oconv and rpict but the search for 'rayinit.cal' failed.


One last thing: If you copy-and-past from Windows to Linux you should  
change the line end characters. Windows will create a '\r\n' at the  
end of a text file while Unix only uses '\n'. The bash configuration  
files should not be affected, but other programs might have problems  
with that.

Regards,
Thomas









More information about the Radiance-general mailing list