Creator Script: Tip for using Select From ID if your node names contain special characters
C
Craig
started a topic Thursday, Nov 17, 2016
Original Post by: SteveThompson Fri Dec 2 21:23:51 2011
During the OpenFlight User Group Meeting at I/ITSEC on 11/30/2011, tips and tricks were presented for using OpenFlight Script and Creator Script.
Here is a script presented that shows how to use the Creator Script command Select From ID. It shows how to set the "ID" parameter of the command when your node names contain special characters.
Note that during the presentation, a user asked how to search for a node whose name contains the "*" (wildcard) character. The script presented below is a modified version of that presented during the meeting in order to address this specific question.
We hope you find this instructional.
# this script executes the Creator tool: Select From ID
# to demonstrate how to use this tool for different kinds of names
# consider a simgle scene containing the following hierarchy
#
# db
# |
# +---------------+--------------+
# | | |
# shadow group collision group shadow*
#
# get a parameter block that can be used for the Select From ID tool
paramBlock = mgGetParamBlock ("Select from ID")
# set up the tool parameters
# select only this node
mgParamSet (paramBlock, "Add to Select List", MG_FALSE)
Craig
During the OpenFlight User Group Meeting at I/ITSEC on 11/30/2011, tips and tricks were presented for using OpenFlight Script and Creator Script.
Here is a script presented that shows how to use the Creator Script command Select From ID. It shows how to set the "ID" parameter of the command when your node names contain special characters.
Note that during the presentation, a user asked how to search for a node whose name contains the "*" (wildcard) character. The script presented below is a modified version of that presented during the meeting in order to address this specific question.
We hope you find this instructional.