public class SoLDMNodeFrontManager extends SoLDMLargeDataManagement
<font color="#0000FF">NOTE:</font> This class does not exist in Open Inventor 10.0 and later.
The SoLDMNodeFrontManager
is in charge of maintaining a data structure representing the multiresolution organization of the data stored on disk and the state of this data in main memory for a specific frame (tiles loaded in main memory and their importance and attributes for rendering).
The set of tiles of higher weights in this data structure represent the best available textures to fit in texture memory for the frame to render. This collection is the result of the data structure evaluation.
An evaluation of the structure is performed when LDM asks (getNextTexFront, getNextSliceTexFront, getOrderedDataFront) for an update of the texture node front and if the SoLDMNodeFrontManager
was previously notified that something changed (geomChangeNotify
, resourceChangeNotify
, movingChangeNotify
) e.g., some geometry has changed, some new tiles have been loaded, etc.
The SoLDMNodeFrontManager
asks the SoLDMTileVisitor
to compute the weight of each node. Based on these weights, decisions are made to either refine (load tiles of higher resolution) or collapse the multiresolution system (unload). The SoLDMNodeFrontManager
works under constraints given by the SoLDMResourceManager
(number of texture allowed in texture memory and texture load rate).
If the user does not interact with the model, the quality of the rendering will increase until it reaches an optimal state. The asynchronous loading process continues loading until the weight of the next tile to load is less than the weight of the next tile to unload meaning that the optimal collection of tiles is present in main memory and in texture memory.
See also:
Inventor.ConstructorCommand
VERBOSE_LEVEL, ZeroHandle
Modifier and Type | Method and Description |
---|---|
void |
geomChangeNotify()
Calls geomChangeNotify(false).
|
void |
geomChangeNotify(boolean redraw)
Notifies
SoLDMNodeFrontManager that it's necessary to re-evaluate the data structure due to geometry or property changes. |
SoLDMTileID |
getDataTileID(SoLDMTileID tileID)
Given a tileID, returns the tileID whose data will be used for the input tileID.
|
int |
getFileID(SoLDMTileID tileID)
Returns the file ID corresponding to the specified tile ID (ID of the tile in the file).
|
long |
getMaxTileIDAtResolution(int level)
return the maximum tileID at a given depth.
|
int |
getMinResolution()
Returns how many different subsample levels of the data set the data stores.
|
int |
getNextLoadedStepLevel(int id)
Return the level of the next time step.
|
int |
getNumFileIDs()
Returns the total number of file IDs used ( < getNumTileIDs() ).
|
SoLDMTileID |
getShape2dTexTileID(SoLdmShape shape,
SoLDMTileID tileID)
Same thing as
getTexTileID but for a 2d shape. |
SoLDMTileID |
getTexTileID(SoLDMTileID tileID)
Given a tileID, returns the tileID whose texture will be used for the input tileID.
|
SoLDMTileID |
getTileID(SbVec3i32 cellPos)
Calls getTileID(cellPos, (int)0).
|
SoLDMTileID |
getTileID(SbVec3i32 cellPos,
int resolution)
Given the position of a cell (i,j,k) and the resolution, returns the tile ID of the corresponding tile.
|
int |
getTileLevel(SoLDMTileID tileID)
return the depth of the given tileID.
|
SbBox3i32 |
getTilePos(SoLDMTileID tileID)
Returns the tile position in data coordinates of the specified tile ID.
|
float |
getWeight(SoLDMTileID tileID)
Utility function to get a tile's weight.
|
boolean |
isSliceTexFrontEmpty(int name_17645)
Indicates if there is no texture to be loaded yet because nothing is in main memory.
|
boolean |
isTextureFrontEmpty()
Indicates if there is no texture to be loaded yet because nothing is in main memory.
|
void |
movingChangeNotify(boolean movingValue)
Notifies
SoLDMNodeFrontManager if the user is interacting with the scene or not. |
int |
registerSlice(SoShape name_17636)
This function must be called by a slice to notify the nodeFrontManager that a new data structure must be maintained for it.
|
void |
reset2dTexFronts(SoLdmShape shape) |
void |
resourceChangeNotify()
Notifies
SoLDMNodeFrontManager that texture resources have changed and the front needs to be recalculated. |
void |
setSliceMaxVisualResolution(int sliceID,
int res)
Set the maximum display resolution of slice sliceID.
|
void |
setSlicePlane(int sliceID,
SbPlane plane)
Tells
SoLDMNodeFrontManager what plane the slice is in. |
void |
shouldInit()
Indicates that the manager should be initialized.
|
void |
startTraversalNotify()
This function is called at the beginning of each traversal and can be used to initialize whatever variables are necessary for the
SoLDMNodeFrontManager . |
void |
unRegisterSlice(int sliceID)
Notifies
SoLDMNodeFrontManager that the slice of ID sliceID is no longer valid. |
reset
dispose, getAddress, getNativeResourceHandle, startInternalThreads, stopInternalThreads
public SoLDMTileID getTileID(SbVec3i32 cellPos)
public void geomChangeNotify()
public SoLDMTileID getDataTileID(SoLDMTileID tileID)
public void reset2dTexFronts(SoLdmShape shape)
public int getFileID(SoLDMTileID tileID)
public SbBox3i32 getTilePos(SoLDMTileID tileID)
public int getNumFileIDs()
If the data set has dimension x,y,z, then getNumTileIds represents the number of tiles in a cubic data set of dimension D, where
D = nearest greater power of 2 to max(x,y,z)
(This number varies depending on the topology used). A fileID represents the ID of a tile that is actually used and is 0 if the tile is outside of the actual non cubic data set of dimension x,y,z.
getNumFileIDs returns the number of non null fileIds and is used by the Tile Manager. (It represents the maximum number of non-empty tiles that can be present in main memory.)
public SoLDMTileID getTexTileID(SoLDMTileID tileID)
public SoLDMTileID getShape2dTexTileID(SoLdmShape shape, SoLDMTileID tileID)
getTexTileID
but for a 2d shape.public int getMinResolution()
public SoLDMTileID getTileID(SbVec3i32 cellPos, int resolution)
public float getWeight(SoLDMTileID tileID)
public void startTraversalNotify()
SoLDMNodeFrontManager
.public long getMaxTileIDAtResolution(int level)
public void setSlicePlane(int sliceID, SbPlane plane)
SoLDMNodeFrontManager
what plane the slice is in.public void geomChangeNotify(boolean redraw)
SoLDMNodeFrontManager
that it's necessary to re-evaluate the data structure due to geometry or property changes.
The redraw flag specifies whether to redraw the data set or not.public boolean isTextureFrontEmpty()
public void movingChangeNotify(boolean movingValue)
SoLDMNodeFrontManager
if the user is interacting with the scene or not.public boolean isSliceTexFrontEmpty(int name_17645)
public void resourceChangeNotify()
SoLDMNodeFrontManager
that texture resources have changed and the front needs to be recalculated.public void setSliceMaxVisualResolution(int sliceID, int res)
public int getNextLoadedStepLevel(int id)
public int getTileLevel(SoLDMTileID tileID)
public void unRegisterSlice(int sliceID)
SoLDMNodeFrontManager
that the slice of ID sliceID is no longer valid.public void shouldInit()
public int registerSlice(SoShape name_17636)
Generated on January 23, 2025, Copyright © Thermo Fisher Scientific. All rights reserved. http://www.openinventor.com