VSG Logo   Avizo Forum

Go Back   Avizo and Amira Forum > Resources

Resources Scripts, samples, demos,...

Thread Tools Display Modes
Old 17th November 2009, 19:22
ShawnZhang ShawnZhang is offline
VSG Staff
Join Date: Mar 2008
Posts: 43
Default Rendering two parts/materials/objects with distinctive colormaps

A customer requested the following,

"I have a data set that I have segmented into two regions (maybe three, the default “exterior” plus two defined by me). I would like to use VoltexHighQuality to render this. But what I would like is to be able to set one region (say label A) to one colormap/alpha value and have label B use a different colormap/alpha value. The densities of the two label regions are similar, so I cannot separate them based on the colormap density values alone. How do I do this? Any suggestions?"

The attached script should do the trick. Save the hx file under $AVIZO/data/tutorials, and load it.

The basic idea is using arithmetic module to mask out the part/material that is of interest.

Screen shot follow. In my case, I have 8 different labels, and I am extracting out label ID 6 and ID 7.

A few additional notes about improving volume rendering comparison.

1. When choose colormap, please make sure that you choose the colormap with transparency (alpha value) defined, such as the ones with "volren" string in the names.

2. SelectROI is a good idea to reduce the data being finally rendered on the screen, however, it does not reduce the total amount of data that you sent to GPU. You need to use the crop editor (available through the data module's property top-right icon list) to crop the data.

3. Then you can increase the number of slices to enhance the rendering quality.

Feedback welcome. Enjoy.

Attached Images
File Type: jpg two-volrend.JPG (139.2 KB, 72 views)
Attached Files
File Type: hx two-volrend.hx (13.9 KB, 37 views)
Reply With Quote
Old 31st May 2011, 08:42
shuom shuom is offline
Join Date: Jul 2009
Posts: 13
Default Re: Rendering two parts/materials/objects with distinctive colormaps

In the attached image, the (B==7) refers to the label set in B which is also indexed as 7, correct?
Reply With Quote
Old 31st May 2011, 19:12
forum_admin forum_admin is offline
Join Date: Feb 2008
Posts: 110
Default Re: Rendering two parts/materials/objects with distinctive colormaps

Correct. Label set with index 7 in B is used as a mask to pick out the voxels from the original image data.

Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT. The time now is 10:13.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2016, vBulletin Solutions, Inc.
Copyright FEI SAS, 2008-2014.