Page 1 of 1

Is video subtitling possible?

Posted: Wed Jul 31, 2013 6:58 pm
by windyjon
Hi,

Apologies in advance, I'm a total livecode newcomer, but would like some advice to know if something is theoretically possible.

I'd like to play video on a mobile device, but offer a range of selectable subtitles.
So far I've got a mobile control playing a simple video within a window in my app.
Underneath the video I've got a window area where I'd like to display my titles. Is there a simple way of pulling in something like an .SRT file and synching this with the video?

I'm clearly NOT asking anyone to do this, just want to know if livecode could handle this kind of thing on a mobile device, and maybe get a few pointers.

Thanks

Jon

Re: Is video subtitling possible?

Posted: Wed Jul 31, 2013 7:17 pm
by Simon
Hi Jon,
Welcome to the forum :)
There is a property "currentTime" (see the dictionary) this is what you'd use to sync your srt.

Simon

Re: Is video subtitling possible?

Posted: Wed Jul 31, 2013 11:34 pm
by windyjon
Thanks Simon,

CurrentTime - wonderful. Just found a reference to it at 'drat it won't let me post a URL', but Google turns it up quite quickly.
THink it will take me quite a bit more time to work out how to use this with an .SRT, but thanks v much for the heads up.I now have a direction to work towards. V helpful.

Cheers

Re: Is video subtitling possible?

Posted: Thu Aug 01, 2013 12:31 am
by windyjon
(Very irritating, I can't post URLs to this forum!!) Grr.

Just discovered Callbacks.
Seems they don't work on mobile devices, which is a great shame.

There's a great demo for an audio book at:
(aaauurgh, why won't it let me post a simple URL?)
and some info about Quicktime tracks at byu.edu :
(This is really irritating!)

But it seems that these techniques aren't available on mobile devices.
Am I correct?

Thanks

Re: Is video subtitling possible?

Posted: Thu Aug 01, 2013 1:33 am
by Simon
It looks like the callbacks are only for QT and as such... no Mobile :(
But as an srt contains the timing information you should, with a little math, be able to accomplish what you are trying to do.
currentTIme is in milliseconds and srt I think shows something like this:
00:13:16,380 --> 00:13:18,424
You've just got to convert that to milliseconds to determine when to show.

If you have specific questions I'd be happy to try and help.

Oh, and I think you have to have about 10 posts before you can post a link.

Simon

Re: Is video subtitling possible?

Posted: Thu Aug 01, 2013 12:36 pm
by Klaus
Hi John,
Simon wrote:...Oh, and I think you have to have about 10 posts before you can post a link.
Yep, Simon is correct! Very irritating, isn't it? 8-)


Best

Klaus