[osg-users] Help for OSGVolume

Zhang Shuyao zhangshuyao1103 at gmail.com
Thu Jul 27 21:34:04 PDT 2017


Hi, everyone,

I'm working on visualizing volume data via osgVolume, I wrote a program to generate some ".raw" files,  and my data is supposed to be 61*61*61 volume, I can see it perfectly in osgVolume.exe like this:
    osgVolume.exe --raw 61 61 61 1 1 big XXX.raw
but only in this way, it's a grayscale volume.

Here is my problem,
When I tried to give it color and opacity like this :
    osgVolume.exe --raw 61 61 61 1 4 big XXX.raw
the program just crashed. I know it was because the ".raw" data reading progress in the readRaw(...) function, when chose to use GL_RGBA pixel format, the data is not suitable for reading anymore, but I can't figure out how to fix this problem, CAN ANYONE HELP ME? 

Thank you!

Cheers,
Zhang

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=71330#71330







More information about the osg-users mailing list