Basic HTML version of Foils prepared 5 August 97

Foil 16 Java code to set an eventOut field - II

From VRML97 Scripting: Java Nodes and External Authoring Interface UC Web Applications Certificate -- July 24 1997. by Wojtek Furmanski and Balaji Natarajan


1 Public void processEvent(Event e) {
2 ConstSFBool v = (ConstSFBool)e.getValue();
3 if(v.getValue()) {
4 if(on.getValue()){
5 newColor.setValue(red);
6 } else { newColor.setValue(blue);
7 }
8 on.setValue(!on.getValue()); } } }
9

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Sun Nov 29 1998