Hi Ora,
Events are often independent of bands (multiple bands can share one event
source).
But filters are band-specific. So don't use a filterMatcher for several bands,
use a filterMatcher per band. That way you know what band you're filtering.
Of course, you can use a second function for common filtering tasks. Eg
timeline.getBand(0).getEventPainter().setFilterMatcher(filterMatcher0);
timeline.getBand(1).getEventPainter().setFilterMatcher(filterMatcher1);
function filterMatcher0 (evt) {return commonFilterMatcher(0,evt)}
function filterMatcher1 (evt) {return commonFilterMatcher(1,evt)}
function commonFilterMatcher(band_index, evt) {
do filtering here. Return true || false
}
Larry
________________________________
From: ora <[email protected]>
To: SIMILE Widgets <[email protected]>
Sent: Sunday, April 5, 2009 1:58:23 AM
Subject: getting a band or a timeline of an event
Hi Everyone,
I am trying to find a way to get the band information and timeline
information from an event.
For example, lets say I have a filterMatcher for several banda, and
now the event is passed to this filter and my filtering depends on the
band that that contains the event, therefore I want to know which band
this event came from. I can obviously manage the filters and bands
somewhere, but I'd rather not, do you know of a way to get the band/
timeline info from an event on run-time?
Thanks
Ora
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"SIMILE Widgets" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/simile-widgets?hl=en
-~----------~----~----~----~------~----~------~--~---