rad to wrl

Hi Xian,

I really do not know that much about vrml. I just happened to know the possible translation pipeline.... I guess am not surprised that the file is large. How large is the corresponding radiance data? Are you also translating the materials? You will most likely need to have materials defined in vrml and perhaps even some lighting for proper display. I have posted this back to the list. Perhaps someone else has some insights?

-Jack

Yun-Xian Ho wrote:

···

Hi Jack,

I tried your suggested method of converting my rad file into vrml
format. However, I encountered two problems: (1) the wrl file is HUGE
(over 20mb) and one file can hardly be worth that much and (2) the wrl
file will does not seem to be properly displayed by my browser which
currently has cortona installed (including the VRML 1.0 converter).
Links to to the .wrl file and the .ppm file can be found at the
following links, respectively:

NYU
NYU

Any suggestions?

--xian

____________________________________________
yun-xian ho
e: [email protected]
c: 917.374.7598 -----------------------------
Hi Xian,

One option is to convert to mgf and then to to inventor/vrml:

    rad2mgf -df myscene.rad > myscene.mgf
    (converts to mgf format with units in feet)
    mgf2inv -vrml mscene.mgf > myscene.vrml
    (converts to vrml 1.0)

mgf2inv converts to vrml 1.0, inventor 1.0 and inventor 2.0

More about mfg can be found at:

    The Materials and Geometry Format

-Jack

---------------------------

Hi all,

Does anyone know of an easy way to convert radiance files to VRML
files?

--xian

____________________________________________
yun-xian ho
e: [email protected]
c: 917.374.7598

--
# Jack de Valpine
# president
#
# visarc incorporated
# http://www.visarc.com
#
# channeling technology for superior design and construction

Hi Jack,

The radiance data is 50kb. Not very large at all. And I am translating the materials and light as well in one line with rad2mgf. It seems that the output in the vrml file contains many of the following lines repeated with different values:

# Unsupported RADIANCE primitive:
# gray_plastic texfunc Phong
# 4 surf_dx surf_dy surf_dz surf.cal
# 0
# 13 2 0303123 ...

Clues?

--xian

Jack de Valpine wrote:

···

Hi Xian,

I really do not know that much about vrml. I just happened to know the possible translation pipeline.... I guess am not surprised that the file is large. How large is the corresponding radiance data? Are you also translating the materials? You will most likely need to have materials defined in vrml and perhaps even some lighting for proper display. I have posted this back to the list. Perhaps someone else has some insights?

-Jack

Yun-Xian Ho wrote:

Hi Jack,

I tried your suggested method of converting my rad file into vrml
format. However, I encountered two problems: (1) the wrl file is HUGE
(over 20mb) and one file can hardly be worth that much and (2) the wrl
file will does not seem to be properly displayed by my browser which
currently has cortona installed (including the VRML 1.0 converter).
Links to to the .wrl file and the .ppm file can be found at the
following links, respectively:

NYU
NYU

Any suggestions?

--xian

____________________________________________
yun-xian ho
e: [email protected]
c: 917.374.7598 -----------------------------
Hi Xian,

One option is to convert to mgf and then to to inventor/vrml:

    rad2mgf -df myscene.rad > myscene.mgf
    (converts to mgf format with units in feet)
    mgf2inv -vrml mscene.mgf > myscene.vrml
    (converts to vrml 1.0)

mgf2inv converts to vrml 1.0, inventor 1.0 and inventor 2.0

More about mfg can be found at:

    The Materials and Geometry Format

-Jack

---------------------------

Hi all,

Does anyone know of an easy way to convert radiance files to VRML
files?

--xian

____________________________________________
yun-xian ho
e: [email protected]
c: 917.374.7598

--
[email protected]
http://homepages.nyu.edu/~yxh201
somewhere in deutscheland (sept 01 - nov 16)

Hi Xian,

OK, well 20M from 50K probably means something is not quite right. I am pretty sure that you are not going to be able to translate Radiance modifiers such as "texfunc" to vrml. I expect you will only be able to translate basic materials such as plastic, metal or glass. Probably the first the to do is define some simple geometry with a basic material applied and see if you can get that to work. If this works then for your geometry you probably need to define an alternate set of materials using just the base material types.

-Jack

Yun-Xian Ho wrote:

···

Hi Jack,

The radiance data is 50kb. Not very large at all. And I am translating the materials and light as well in one line with rad2mgf. It seems that the output in the vrml file contains many of the following lines repeated with different values:

# Unsupported RADIANCE primitive:
# gray_plastic texfunc Phong
# 4 surf_dx surf_dy surf_dz surf.cal
# 0
# 13 2 0303123 ...

Clues?

--xian

Jack de Valpine wrote:

Hi Xian,

I really do not know that much about vrml. I just happened to know the possible translation pipeline.... I guess am not surprised that the file is large. How large is the corresponding radiance data? Are you also translating the materials? You will most likely need to have materials defined in vrml and perhaps even some lighting for proper display. I have posted this back to the list. Perhaps someone else has some insights?

-Jack

Yun-Xian Ho wrote:

Hi Jack,

I tried your suggested method of converting my rad file into vrml
format. However, I encountered two problems: (1) the wrl file is HUGE
(over 20mb) and one file can hardly be worth that much and (2) the wrl
file will does not seem to be properly displayed by my browser which
currently has cortona installed (including the VRML 1.0 converter).
Links to to the .wrl file and the .ppm file can be found at the
following links, respectively:

NYU
NYU

Any suggestions?

--xian

____________________________________________
yun-xian ho
e: [email protected]
c: 917.374.7598 -----------------------------
Hi Xian,

One option is to convert to mgf and then to to inventor/vrml:

    rad2mgf -df myscene.rad > myscene.mgf
    (converts to mgf format with units in feet)
    mgf2inv -vrml mscene.mgf > myscene.vrml
    (converts to vrml 1.0)

mgf2inv converts to vrml 1.0, inventor 1.0 and inventor 2.0

More about mfg can be found at:

    The Materials and Geometry Format

-Jack

---------------------------

Hi all,

Does anyone know of an easy way to convert radiance files to VRML
files?

--xian

____________________________________________
yun-xian ho
e: [email protected]
c: 917.374.7598

--
# Jack de Valpine
# president
#
# visarc incorporated
# http://www.visarc.com
#
# channeling technology for superior design and construction

Hi,

a note, vrml1 is tricky today. Also, there might be an alternative. If you manage to get Renderpark to run, it can load mgf and write precalculated (radiosity) vrml. Modifying mgf2inv to write vrml2 or x3d would also be great.

You can use grep to filter out all lines starting with #. That will reduce files size and should give working scenes.

Lars.