DOC PREVIEW
OSU CS 553 - Directly Visualizing Volume Data

This preview shows page 1-2-3-4-5 out of 16 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 16 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 16 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 16 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 16 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 16 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 16 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

1Directly Visualizing Volume DataMike [email protected] State Universitymjb – May 14, 2013Oregon State UniversityComputer GraphicsVolume Data: A DefinitionA volume is a 3D discretely sampled data set where the size of the voxels have been expanded to occupy the space to the neighboring voxels.mjb – May 14, 2013Oregon State UniversityComputer Graphics2Why Do We Care About Volume Visualization?• Medical: CAT, MRI, 3D ultrasound• Science and engineering: CFD, stress, thermal, moleculargg,, ,• Volumes are normally very difficult to comprehendmjb – May 14, 2013Oregon State UniversityComputer GraphicsUnderstanding Volume Data Usually Involves a CompromisePoint CloudsAll values everywhere, hard to see very much, distracting artifactsInterpolated-colors cutting planesContours cutting planeIsosurfacesAll values in a single planeDiscrete values in a single planeA single value everywheremjb – May 14, 2013Oregon State UniversityComputer GraphicsBecause of these compromises, these are all considered to be indirect ways to visualize volume data3Direct Volume RenderingComposite the colors and alphas of the voxelsmjb – May 14, 2013Oregon State UniversityComputer GraphicsA Volume Element, or voxelTransfer FunctionColorsOpacityFrequency Histogram (usually a log scale)mjb – May 14, 2013Oregon State UniversityComputer GraphicsOSU vxTransfer Function Sculpting Window4CCColdnew).1('Voxel CompositingRecall this color blending equation from the OpenGL Transparency notes:ColdIn “Voxel World”, things work the same way:mjb – May 14, 2013Oregon State UniversityComputer GraphicsC’Cnew, αTMIN = 0.TMAX = 100.The color transfer function is a Black-Red-Yellow-White heated object scale, mapping a scalar value of 0. to Black, and 100. to White.R,G,B = (0.,1.,1.)T = 33.33Voxel Compositing ExampleThe opacity transfer function is a linear ramp so that the opacity is 1. (opaque) when T = 100. and 0. (transparent) when T = 0.You are compositing back-to-front through the volume. At this moment, the running values of RGB are (0., 1., 1.) . The next voxel you encounter has a T value of 33.33R,G,B = (?,?,?)mjb – May 14, 2013Oregon State UniversityComputer Graphics1. What is the color of just this voxel?2. What is the opacity of just this voxel?3. What will the new running RGB values be when you are done compositing this voxel with the old running RGB values?5What is the color of just this voxel?What is the opacity ofjust this voxel?What will the new running RGB values be when you are done compositing this voxel with the old running RGB values?What is the opacity of just this voxel?mjb – May 14, 2013Oregon State UniversityComputer GraphicsCropping the Volume based on Data Valuemjb – May 14, 2013Oregon State UniversityComputer Graphics6Cropping the Volume based on Spatial Locationmjb – May 14, 2013Oregon State UniversityComputer Graphics“Magic Lens” to Selectively Look InsideVolume DataDisplay Parameters #1Display Parameters #2One Displaymjb – May 14, 2013Oregon State UniversityComputer Graphics7Lightingmjb – May 14, 2013Oregon State UniversityComputer Graphics(,,)dS dS dSnSdx dy dzXYVolume Rendering with Parallel Texture PlanesXZmjb – May 14, 2013Oregon State UniversityComputer Graphicsunsigned char TextureXY[NZ][NX][NY][4];“NZ slices of an NX by NY RGBA exture"unsigned char TextureYZ[NX][NY][NZ][4];“NX slices of an NY by NZ RGBA texture"unsigned char TextureXZ[NY][NX][NZ][4];“NY slices of an NX by NZ RGBA texture"8view … );; .5 );In a callback that is called whenever the opacity transfer function changes:set from ere elsethis voxellor composite); zz++ )fill:ue is not in the range you want to vr;.g;.b;a;0] = (unsigned char) ( 255.*r + .5 );] = (unsigned char) ( 255.*g + .5 );2] = (unsigned char) ( 255.*b + .5 );3] = (unsigned char) ( 255.*alpha +Zside is ssomewhemjb – May 14, 2013Oregon State UniversityComputer GraphicsvoidFillXY( void ){float alpha; // opacity at tfloat r, g, b; // running colfor( int x = 0; x < NX; x++ ){for( int y = 0; y < NY; y++ {r = g = b = 0.;for( int zz = 0; zz < NZ;{// which direction to fint z;if( Zside == PLUS )z = zz;elsez = ( NZ-1 ) - zz;if( … this scalar valu{r = g = b = 0.;alpha = 0.;}else{r = Nodes[x][y][z].g = Nodes[x][y][z]b = Nodes[x][y][z]alpha = MaxAlpha}TextureXY[zz][y][x][0TextureXY[zz][y][x][1TextureXY[zz][y][x][2TextureXY[zz][y][x][3}}}}glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP );glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP );glTexEnvf( GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE );int filter = GL_NEAREST;if( Bilinear )filter = GL_LINEAR;elsefilter = GL_NEAREST;In Display( ), I:glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, filter );glTexParameterf( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, filter );glPixelStorei( GL_UNPACK_ALIGNMENT, 1 );glEnable( GL_TEXTURE_2D );glBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA );glEnable( GL_BLEND );DetermineVisibility( );float z0, dz;if( Major==Z)Sets the global variables Major, Xside, Yside, and Zsidemjb – May 14, 2013Oregon State UniversityComputer Graphicsif( Major Z ){if( Zside == PLUS ){z0 = -1.; // back-to-frontdz = 2. / (float)( NZ - 1 );}else{z0 = 1.; // front-to-backdz = -2. / (float)( NZ - 1 );}9In Display( ), II:x= 1., y= 1., s=1., t=1.x=-1., y= 1., s=0., t=1.glBegin( GL_QUADS );for( z = 0; z < NZ; z++, zcoord += dz ){glTexImage2D( GL_TEXTURE_2D, 0, 4, NX, NY, 0, GL_RGBA, GL_UNSIGNED_BYTE, &TextureXY[z][0][0][0] );glTexCoord2f( 0.f, 0.f );glVertex3f( -1.f, -1.f, zcoord );glTexCoord2f( 1.f, 0.f );x=-1., y=-1., s=0., t=0.x= 1., y=-1., s=1., t=0.mjb – May 14, 2013Oregon State UniversityComputer Graphicsg()glVertex3f( 1.f, -1.f, zcoord );glTexCoord2f( 1.f, 1.f );glVertex3f( 1.f, 1.f, zcoord );glTexCoord2f( 0.f, 1.f );glVertex3f( -1.f, 1.f, zcoord );}glEnd( );} // if( Major == Z )Human Embryomjb – May 14, 2013Oregon State UniversityComputer Graphics10Geophysicsmjb – May 14, 2013Oregon State UniversityComputer GraphicsVolume Interaction: The Visible Humanmjb – May 14, 2013Oregon State UniversityComputer Graphics11Interactive Volume Visualization forComputational Fluid Dynamicsmjb – May 14, 2013Oregon State UniversityComputer GraphicsVolume Interaction in Cancer researchmjb – May 14, 2013Oregon State UniversityComputer Graphics12Molecular Sciencemjb – May 14, 2013Oregon State UniversityComputer GraphicsSolar Windmjb – May 14, 2013Oregon State UniversityComputer


View Full Document

OSU CS 553 - Directly Visualizing Volume Data

Download Directly Visualizing Volume Data
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Directly Visualizing Volume Data and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Directly Visualizing Volume Data 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?