My ultimate goal: Allow user to select options (using the NoteISwitch command) before rendering and exporting images. Options will include BPR On/Off, Floor On/Off, Perspective On/Off, Color Pass, Depth Pass, Shadow Pass, etc, etc.
I’m using the NoteISwitch command inside a note. So far I have 2 buttons setup … one labeled “Floor On/Off” and another labeled “Perspective On/Off”. Now I’m trying to figure out the path of these buttons. I need know if the button is selected or not.
An example of the behavior I’m looking for:
- User selects desired options
- User selects execute
- When it executes, look at each option (for example “Perspective On/Off”) and determine if it is selected of not
- If the switch button is selected, turn Perspective on (IPress,Draw:Perspective)
Outside a note you just look up the path of the Switch button you’ve created. I’m not sure how to find the path of the button when it is in a note. Is this possible?
//Variables
[VarSet,hPos,5]
[VarSet,vPos,30]
//Routines
[RoutineDef,NoteInterface,
//background image - the other buttons are positioned relative to this
[NoteIButton,,,,1,1,1,210,350,,,0,,1]
//Options Title Bar
[NoteIButton,"Options",,,1,hPos,vPos,200,20, (185+(139*256)+(107*65536)),0, , , ]
//Floor label
[NoteISwitch,"Floor ON/OFF" , , ,,hPos ,vPos+25 ,200 ,20 , , , , , ]
//Perspective label
[NoteISwitch,"Perspective ON/OFF" , , ,,hPos ,vPos+50 ,200 ,20 ,, ,, , ]
//Execute button
[NoteIButton,"Execute" , , ,,20 ,350 ,75 ,25 , ,0xffa000 ,, , ]
[Note,"==== Title of Note ===="]
]//end routine
//Create button
[IButton,"test","test",
[RoutineCall,NoteInterface]
,,.5
]//end test button