From time to time I get emails asking about voxel data/volume rendering capabilities in Blender for medical scan data (see this previous post). Today I got one asking for a simple example for using it in 2.5, so I thought I’d re-post it here. It’s using a 512 x 512 x 233 scan of a plastic skull, and the demo file is just loading it up as a density source in a simple scene with ground plane and light. To set it up from scratch, you should be able to follow the same instructions as any tutorial for rendering smoke or other volumes in blender, but change the density source.
Some extra notes:
- The main thing to remember is that volume rendering in blender is not really intended for solids, or even medical usage at all – it’s really just a nice side effect. The volume shader in blender is intended for gas/particles like clouds or smoke. Having said that, if you crank the density of the volume right up, you can approach something more solid looking. The above example is using a Density Scale of 50.
- This plastic skull example was quite easy because I didn’t have to isolate any kind of extra tissue etc. To do that normally you’d have to use the ramp option in the Texture’s Color panel. Here’s an example of a scan of my own head, using the ramp to isolate out the skull (right) from all the flesh (left).
- You may notice on a dense volume like this, the shading looks a bit blocky – this is due to the Light Cache, which speeds up rendering a lot, without too much visual quality loss on most cloud/smoke kinds of volumes. The artifacts do show a bit more clearly with very dense volumes though. You can remedy this by either increasing the Light Cache resolution (using more memory) or turning it off completely (using more CPU).