public class SoAppearancePreserver extends Inventor
SoSimplifyAction
, SoSimplify...), a normal map texture and texture coordinates for this texture to be applied to the simplified model. For each triangle in the simplified model, there is a triangular area in the normal map texture that contains normal vectors derived from the original complex model. Using the bump mapping technique with the generated normal map, the rendering of the simplified model will appear with the details of the original model but using much fewer triangles.
Note 1: The time for generating the normal map depends on the size of the original model, the size of the simplified model, and also the size of the normal map texture. This process could take several minutes.
Note 2: The quality of the final rendering using the bump mapping technique is closely linked to the size of the normal map texture.
Limitations: The size of the normal map texture limits the number of possible triangles for the simplified model. This is because the minimum size for a triangle in the normal map texture is at least 3 pixels. So for a 256*256 texture size, a maximum of 22,000 triangles can be stored. If necessary, specify a larger texture (see setTextureSize
) or a more aggressive simplification of the model.
See also:
SoBumpMappingProperty
, SoTextureUnit.Deprecated since Open Inventor 9400
No longer supported.
Inventor.ConstructorCommand
VERBOSE_LEVEL, ZeroHandle
Constructor and Description |
---|
SoAppearancePreserver()
Deprecated.
Constructor.
|
Modifier and Type | Method and Description |
---|---|
SoTextureCoordinate2 |
getBumpCoords()
Deprecated.
Computes the texture coordinates and creates an
SoTextureCoordinate2 node. |
SoTexture2 |
getDisplacementMapTexture()
Deprecated.
Calls getDisplacementMapTexture("").
|
SoTexture2 |
getDisplacementMapTexture(java.lang.String filename)
Deprecated.
Computes the displacement map texture and creates an
SoTexture2 node. |
SoTexture2 |
getNormalMapTexture()
Deprecated.
Calls getNormalMapTexture("").
|
SoTexture2 |
getNormalMapTexture(java.lang.String filename)
Deprecated.
Computes the normal map texture and creates an
SoTexture2 node. |
void |
setSceneGraphs(SoNode original,
SoNode simplified)
Deprecated.
Specifies the original scene graph and the simplified scene graph.
|
void |
setTextureSize(int width,
int height)
Deprecated.
Specifies the texture size to be generated.
|
void |
setTriangleMinSize(int size)
Deprecated.
Specifies the mininum size for a triangle stored within the normal map texture.
|
dispose, getAddress, getNativeResourceHandle, startInternalThreads, stopInternalThreads
public SoTexture2 getNormalMapTexture()
public SoTexture2 getDisplacementMapTexture()
public SoTexture2 getNormalMapTexture(java.lang.String filename)
SoTexture2
node.
If no file name is specified, the texture is stored in the SoTexture2
image field. Otherwise the file name is stored in the SoTexture2
filename field and the texture is written to a PNG format file. NULL is returned if the texture could not be computed, generally due to there being more triangles than could be stored in the normal map.public SoTexture2 getDisplacementMapTexture(java.lang.String filename)
SoTexture2
node.
If no file name is specified, the texture is stored in the SoTexture2
image field. Otherwise the file name is stored in the SoTexture2
filename field and the texture is written to a PNG format file. NULL is returned if the texture could not be computed, generally due to there being more triangles than could be stored in the normal map.public void setTriangleMinSize(int size)
public void setTextureSize(int width, int height)
public void setSceneGraphs(SoNode original, SoNode simplified)
public SoTextureCoordinate2 getBumpCoords()
SoTextureCoordinate2
node.
The texture coordinates are stored in the texture coordinate point field. They can be applied with the bump mapping technique to the simplified model. NULL is returned if the texture coordinates could not be computed, generally due to there being more triangles than could be stored in the normal map.Generated on January 23, 2025, Copyright © Thermo Fisher Scientific. All rights reserved. http://www.openinventor.com