powered by Jive Software

Whiteboard sample and also documentation of events

Hey anyone have any samples of the whiteboard features of xiff? Also having issues finding documentation of general events for the XIFF objects - where should I be looking?

If someone could give me the basic steps to be able to use the org.jivesoftware.xiff.data.whiteboard.Path class to draw a line series it would be awesome. New to XIFF 2 and trying to figure out the basic usage of the data packages. Any help is greatly appreciated!!!

Thanks.

Message was edited by:

xyris

Hey David,

All the docs should be in the distro package - did you install them so they would show up in the Flash IDE help panel?

Regarding the whiteboard - that was a last-minute addition to the code that I didn’‘t write. Sean Treadway did that one (http://sean.treadway.info). AFAIK, the code is for transmission of the necessary information to recreate the geometry of a drawing on the other end. Meaning, the code doesn’'t do any drawing itself, just acts as a convenient way to transmit the data in a Message.

To use, you would do something like:

var myMessage = new Message( … );

var wb = new WhiteboardExtension();

// Add a path to the WhiteboardExtension payload in the message

var p = new Path();

p.addSegment( , to: } );

p.serialize( wb );

myMessage.addExtension( wb );

// Now send the message, trace to see the XML

myXMPPConnection.send( myMessage );

// On the other end, take the message, extract the paths from the whiteboard payload

This is an educated guess as to how it works - I haven’'t tried it myself. I know that it does work though, as its used at http://www.scenerum.org.

Also, all the paths and fills will be sent as SVG XML, from what I can tell.

Awesome I will give that a shot and let you know how it works.

d,