SIMVoleon: SoObliqueSlice Class Reference

| Coin3D is Free Software, published under the BSD 3-clause license. | https://bitbucket.org/Coin3D/ http://www.kongsberg.com/kogt/

SoObliqueSlice Class Reference

Render a slice of the volume data, with any orientation. More...

`#include <VolumeViz/nodes/SoObliqueSlice.h>`

## Public Types
enum | Interpolation { NEAREST , LINEAR }
enum | AlphaUse { ALPHA_AS_IS , ALPHA_OPAQUE , ALPHA_BINARY }

## Static Public Member Functions
static void | initClass (void)

## Public Attributes
SoSFPlane | plane
SoSFEnum | interpolation
SoSFEnum | alphaUse
SoSFNode | alternateRep

## Protected Member Functions
virtual void | GLRender (SoGLRenderAction *action)
virtual void | rayPick (SoRayPickAction *action)
virtual void | generatePrimitives (SoAction *action)
virtual void | computeBBox (SoAction *action, SbBox3f &box, SbVec3f &center)
virtual void | write (SoWriteAction *action)
virtual SbBool | readInstance (SoInput *in, unsigned short flags)

## Friends
class | SoObliqueSliceP

## Detailed Description

Render a slice of the volume data, with any orientation.

Insert a node of this type after an SoVolumeData node in the scene graph to render a single slice from the full volume data set. The slice is specified as a plane with an orientation and position within the volume.

Here is a simple example, in the form of an iv-file:

    #Inventor V2.1 ascii

    SoVolumeData { fileName "ENGINE.VOL" }

    Separator {
      SoTransferFunction { }
      DEF clipper ClipPlaneManip { }
      SoVolumeRender { }
    }

    Separator {
      SoTransferFunction { predefColorMap GLOW }
      SoObliqueSlice {
        interpolation LINEAR
        alphaUse ALPHA_AS_IS
        plane = USE clipper . plane
      }
    }

Please note that SoObliqueSlice will not work with older OpenGL drivers as they usually lack 3D-texture support. OpenGL drivers of version 1.2 and onwards supports 3D-texturing, as does older OpenGL drivers with the `GL_EXT_texture3D` extension. If none of these are available, a warning message will be printed using Coin's SoDebugError::postWarning().

See also
  SoVolumeRender, SoOrthoSlice
  SoVolumeTriangleStripSet, SoVolumeIndexedTriangleStripSet,
  SoVolumeIndexedFaceSet, SoVolumeFaceSet

Since
  SIM Voleon 2.0

## Member Enumeration Documentation

## ◆ Interpolation

enum SoObliqueSlice::Interpolation

Enumeration of available types of voxel colors interpolation.

Enumerator
NEAREST | For "in between" pixels of the screen rasterization, pick the color of the nearest voxel. Will give sharp edges and a distinct blocky look.
LINEAR | For "in between" pixels of the screen rasterization, interpolate by averaging the colors of several of the nearest voxels. Will give a smoother appearance, but sacrifies some "correctness" for appearance.

## ◆ AlphaUse

enum SoObliqueSlice::AlphaUse

Enumerator
ALPHA_AS_IS | The alpha channel is rendered 'as-is'.
ALPHA_OPAQUE | The alpha channel is ignored making the slice opaque.
ALPHA_BINARY | All alpha values not equal to 0 is threated as value 1.0f.

## Member Data Documentation

## ◆ plane

SoSFPlane SoObliqueSlice::plane

The plane defining the slice.

Default value is an XY plane.

## ◆ interpolation

SoSFEnum SoObliqueSlice::interpolation

How to interpolate color values when rendering "in between" voxels. See SoObliqueSlice::Interpolation.

Default value is SoObliqueSlice::LINEAR.

## ◆ alphaUse

SoSFEnum SoObliqueSlice::alphaUse

How the alpha channel should be threated during rendering. See SoObliqueSlice::AlphaUse.

Default value is SoObliqueSlice::ALPHA_AS_IS

## ◆ alternateRep

SoSFNode SoObliqueSlice::alternateRep

NOTE: support for this field not yet implemented in SIM Voleon.

Since
  SIM Voleon 2.0

The documentation for this class was generated from the following files:

- SoObliqueSlice.h
- ObliqueSlice.cpp