Open Inventor Release 2025.2.2
 
Loading...
Searching...
No Matches
TimeSeries

VolumeViz can render datasets that change over time. For example, while performing a cardiac ultrasound, you can successively record a large number of images of the moving heart. VolumeViz can process this set of images to create a realistic and animated rendering of the heartbeats. All rendering features of VolumeViz, such as volume rendering (SoVolumeRender) or orthoslices (SoOrthoSlice), are compatible with time series datasets.

Examples

A C++ example of this functionality is available in the directory:

$OIVHOME/examples/source/Medical/Rendering/Visualization/medical4DVolumeRendering

This example displays an animated volume rendering. Each 3D volume is stored in a separate file without any time information. The example uses a custom SoVolumeReader to read the data from different files and display it as a time series. An SoTimerSensor is used to trigger a timestamp change in the reader. The custom SoVolumeReader (TimeSeriesVolumeReader) is an array of SoVRGenericFileReader objects (TimeSeriesCachedGenericReader), each representing a different timestamp. At each timestamp change, the following operations are done in this example:

  1. the current generic reader closes opened files and other resources (cf method SoVolumeReader::closeAllHandles)
  2. the timestamp is incremented so that the next generic reader in the array becomes the current one to be used by SoVolumeData
  3. the SoVolumeData::updateRegions is called on the entire volume to force a full data reload

C++ :

// Close open files and other resources
reader->closeAllHandles();
// Reset the data on the entire volume
const SbBox3i32 volDataBox(SbVec3i32(0, 0, 0), volumeData->data.getSize() - SbVec3i32(1, 1, 1));
volumeData->updateRegions(&volDataBox, 1);

C# :

// Close open files and other resources
reader.CloseAllHandles();
// Reset the data on the entire volume
volumeData.UpdateRegions(new[] { new SbBox3i32(new SbVec3i32(0,0,0), volumeData.data.GetSize() - new SbVec3i32(1,1,1)); });

Java :

// Close open files and other resources
reader.closeAllHandles();
// Reset the data on the entire volume
SbBox3i32[] volDataBox = new SbBox3i32[] { new SbBox3i32( new SbVec3i32(0, 0, 0), volumeData.data.getSize().minus(new SbVec3i32(1, 1, 1))) };
volumeData.updateRegions(volDataBox);