FreeWRL

 view release on metacpan or  search on metacpan

ARCHITECTURE  view on Meta::CPAN


---

Q. What is the internal handling of events ?

A. This happens in Events.pm (duh ;) as well as Scene.pm.

Basically, the function VRML::EventMachine::propagate_events (Events.pm)
is called at each event timestamp.  This function first gets the
initial events from nodes and from mouse events, propagates the
event cascade, calls eventsProcessed and continues this until
no events remain.

Take note of the {RFields} member of a node -- this is a *tied*
hash (which looks like a normal perl hash (associative array) on top
but assignments to members and getting values of members translate
to function calls) tied with the class VRML::FieldHash (Scene.pm).
This takes care of IS and USE/DEF when getting/setting field values
as well as generating events when setting field values. The line

	$node->{EventModel}->put_event($node, $k, $value);

in the function VRML::FieldHash::STORE causes the new event to be queued
to be executed at the next step of the current event cascade.

Nodes receive events by the function VRML::Node::receive_event (Scene.pm)
which calls the function for that particular node (defined in VRMLNodes.pm)
to receive that event.


---

Q. Where and how is JavaScript/VrmlScript/Java connected ?



( run in 0.659 second using v1.01-cache-2.11-cpan-49f99fa48dc )