sagiadinos / garlic-player

Digital Signage Player based on SMIL
https://garlic-player.com
GNU Affero General Public License v3.0
82 stars 14 forks source link

iCal -> Wallclock repeat implementation #26

Closed jf133 closed 2 years ago

jf133 commented 2 years ago

Hi --

I like this project and interested in its extensive use. Curious, is there a way to implement rrule for easy datetime interpretation of repeating of slides, etc?

Thank you!

JF

sagiadinos commented 2 years ago

Hello JF,

I am uncertain if I understood what you mean with "datetime interpretation of repeating".

There is a "begin" and "end" attribute in SMIL. There you can trigger repeats based on datetime (wallclock). http://www.a-smil.org/index.php/Wallclock https://www.w3.org/TR/SMIL3/smil-timing.html#q31

In the garlic-palyer /test/data/smil/ directory you will find some examples like this here: https://github.com/sagiadinos/garlic-player/blob/master/tests/data/smil/par/5_wallclock.smil

Hope this helps.

jf133 commented 2 years ago

Hi Niko -- I was essentially asking for a way to convert ical's repeat rule into the wallclock format to understand format for smil.

for example: DTSTART:20211220T020000Z RRULE:FREQ=WEEKLY;UNTIL=20220131T120000Z;COUNT=30;INTERVAL=1;WKST=MO would translate smartly into wallclock. I see there's a library to do ical->rrule implemntation here https://jakubroztocil.github.io/rrule/

Is there such a thing that smil can accept?

jf133 commented 2 years ago

I'm going to try to use the Wall clock conversion.

Thank you JF

sagiadinos commented 2 years ago

Oh, I overseen this.

Is there such a thing that smil can accept?

Yes, As I understand, wallclock and the repeat periods cover this. Periods have the same syntax as time intervals of the iso-8601 date. e.g. P1Y2M10DT2H30M