begin: every element contains a begin trigger. The default value is 0, except of the
excltag. In this only case, the value is indefinite. This prevents that children of
exclwill start automatically. Furthermore, due to the absolute nature there are some restrictions when using begin in children
seqtag. There is only one positive time clock value possible.
- end: There is no default value. This attribute provides an explicit end of the element's active duration. This attribute supersedes even dur. So, when an end signal is fired, the current active duration ends. Period.
You can define more than one trigger and separate them with a semicolon (;).
Currently, garlic-player supports six kind, of triggers in
- Network Trigger
Furthermore, it supports the same value types like dur-attribute (media, indefinite, and clock value).
Wallclock supports the ISO-8601 datetime specification with repeat periods.
The company IAdea adds with weekday an interesting non-standard feature, which garlic-player also supports.
This can be very helpful, if you want to trigger repeatedly different opening times in the week in shop or common in retail.
It is possible to include ISO 8601 compatible periods for repeats. The format is: [datetime]P[YY][MM][WW][DD][T[hH][mM][s[.f]S]]
You can also limit the repeats
You can study a sophisticated real-world example for wallclock triggers.
There are two opportunities, the SMIL syncbase (begin|end) or the similar beginEvent/endEvent. We focus first on syncbase. You can trigger a start or stop of a media with a start or stop of another media. The media which acts as trigger must define a unique ID.
When the video starts in zone 1 it triggers the video.jpg to be shown in zone 2. After ending, it triggers the stop of video.jpg and the beginning of end.jpg.
Compare to the sim event-syntax:
Why are there two Opportunities?
SyncBase is a relict of SMIL 1.0. In this way SMIL 3.0 stay compatible with older SMIL files.
With accesskey you can define a user interaction through a keyboard or sensors (if supported).
Real-world example for accesskey-triggers
Touch or Mouse Click
The event activateEvent defines an activity via touch screen or mouse click. You have to specify an explicit media ID for that, too.
This activateEvent will work on images and videos media. It makes no sense to use it while displayed websites or widgets as there are interactive by default and the click will be gone through to website.
In case of a widget, you should better use the network triggers, which we discuss next.
Real-world example for activateEvent
This is not standard and added by IAdea, but it is so useful, that we implemented it also to the garlic-player from release 0.6.0.
Some SMIL player include a local http-server for serving a restful API. That means that you can control the player via network. That gave us four great opportunities:
- External applications can control player in their network.
- As widgets are local running websites they can use this API and pass elegantly the above-mentioned clicks or touches to the player to start specific commands, change playlist etc.
- You can create a web UI on a second screen, which control the presentation screen.
- It is possible to use a QR-Code or EAN-Code scanner to control the presentation.
Additional Clock Times
In every trigger, you can also set an additional clock time value. Let's take the last network trigger as base for the example.
SMIL supports positive and negative values. Garlic-player currently supports only positive values.