SoBumpMappingProperty Class Reference
[FXViz]

FXViz Bump mapping property node. More...

#include <FXViz/nodes/SoBumpMappingProperty.h>

Inheritance diagram for SoBumpMappingProperty:
SoNode SoFieldContainer SoBase SoRefCounter SoTypedObject

List of all members.

Public Types

enum  NormalMapSpace {
  TANGENT_SPACE = SoBumpMappingPropertyElement::TANGENT_SPACE,
  MODEL_SPACE = SoBumpMappingPropertyElement::MODEL_SPACE
}
enum  TextureFormat {
  HEIGHT_MAP,
  NORMAL_MAP
}

Public Member Functions

virtual SoType getTypeId () const
 SoBumpMappingProperty ()

Static Public Member Functions

static SoType getClassTypeId ()
static SbBool isSupported ()

Public Attributes

SoSFEnum normalMapSpace
SoSFEnum textureFormat
SoSFBool isShadowed
SoSFBool isEyeDistanceAttenuation
SoSFBool isOnlyClosestLightUsed

Detailed Description

FXViz Bump mapping property node.

This node defines the current bump mapping properties for all subsequent shapes. However, currently, only SoFaceSet, SoQuadMesh, and SoTriangleStripSet support bump mapping. Two categories of properties can be defined:

Texture Properties: The format of the bump map texture stored within the SoTexture2 is given by the textureFormat field. The SoTextureUnit::mappingMethod field indicates if the texture stored within SoTexture2 node is a bump map texture or not. This texture can be a "height map", which is a grayscale texture of height (TextureFormat::HEIGHT_MAP), or a "normal map", which is a 3-component texture of normals (TextureFormat::NORMAL_MAP) with x, y, and z corresponding to the red, green, and blue components respectively.

If the current SoTexture2 node does not contain a 3-component texture, specifying normal map format will have no bump mapping effect.

For a height map format, only the first component of each pixel is used. A height map texture is converted internally to a normal map.

Each normal in the normal map texture can be expressed either in the space of the object called "modeling space" or in the space of the face called "tangent space". The normalMapSpace field allows you to specify the desired coordinate system. The tangent space coordinate system is convenient for applying repetitive wrinkle patterns.

Appearance Properties: OpenGL Gouraud lighting is deactivated when a shape is rendered using the bump mapping technique. A pixel shader and a vertex shader are used instead for computing the lighting contribution per pixel according to the normals stored in the normal map.

Depending on the hardware capabilities, the number of passes (maximum 3) necessary to render a shape also depends on the number of lights, brightness of the shape, and texturing (or not) of the shape. In order to select a compromise between rendering quality and rendering performance, several fields are available:

FILE FORMAT/DEFAULT

ACTION BEHAVIOR

SEE ALSO

SoTextureUnit, SoTexture2, SoAppearancePreserver.

Deprecated:

Deprecated since Open Inventor 9400
No longer supported.
See related examples:

BumpMapping


Member Enumeration Documentation

Enumerator:
TANGENT_SPACE 

Normals are expressed in the space of faces.

MODEL_SPACE 

Normals are expressed in the space of the model (i.e., modeling coordinates).

Enumerator:
HEIGHT_MAP 

Grayscale height texture.

NORMAL_MAP 

3-component normal texture.


Constructor & Destructor Documentation

SoBumpMappingProperty::SoBumpMappingProperty (  ) 

Constructor.


Member Function Documentation

static SoType SoBumpMappingProperty::getClassTypeId (  )  [static]

Returns the type identifier for this class.

Reimplemented from SoNode.

virtual SoType SoBumpMappingProperty::getTypeId (  )  const [virtual]

Returns the type identifier for this specific instance.

Reimplemented from SoNode.

static SbBool SoBumpMappingProperty::isSupported (  )  [static]

Indicates if bump mapping is supported by your graphics board.

When using a debug build of Open Inventor, some "no context available" warning messages may be generated. You can ignore them or see SoGLExtension for an example of using SoGLContext to avoid them.


Member Data Documentation

Eye distance attenuation.

Indicates if only the closest light (relative to the shape) is used or if all lights are used.

Activates/deactivates the lighting of unlit areas.

Specifies in which space normals in the normal map are expressed.

Indicates if the specified bump map texture in SoTexture2 is a height map or a normal map.


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

Open Inventor Toolkit reference manual, generated on 12 Feb 2024
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/