|
Home > Archive > Macromedia Flash Server > August 2005 > FLV + Subtitles
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane. 2005-08-09, 8:45 pm |
| I'm sure this has been discussed before, but after checking the wikki, I
am still wondering as to the best method to accomplish multi-language
subtitles with my FLV's. Currently, I have multiple .xml docs that have
the subtitles defined in seconds, and I'm parsing the proper language XML,
and adding the subtitles as cuePoints to the mediaPlayer.... I'm sure
there is a much better way to do this, as I'm loosing sync when I switch
movies (weird how removeAllCuePoints doesn't seem to be working the way I
expected it to)...... anyways, can someone point me in the right
direction?
Thanks everyone,
AC
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
| |
| Stefan Richter 2005-08-09, 8:45 pm |
| http://www.buraks.com/captionate/
-----Original Message-----
From: flashcomm-bounces-1Ss2GqJETD3yZ38Mhd3e/9ZfFG6BLHNm@public.gmane.org
[mailto:flashcomm-bounces-1Ss2GqJETD3yZ38Mhd3e/9ZfFG6BLHNm@public.gmane.org] On Behalf Of
acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane.org
Sent: Tuesday, August 09, 2005 2:47 PM
To: FlashComm Mailing List
Subject: [FlashComm] FLV + Subtitles
I'm sure this has been discussed before, but after checking the wikki, I am
still wondering as to the best method to accomplish multi-language subtitles
with my FLV's. Currently, I have multiple .xml docs that have the subtitles
defined in seconds, and I'm parsing the proper language XML, and adding the
subtitles as cuePoints to the mediaPlayer.... I'm sure there is a much
better way to do this, as I'm loosing sync when I switch movies (weird how
removeAllCuePoints doesn't seem to be working the way I expected it
to)...... anyways, can someone point me in the right direction?
Thanks everyone,
AC
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
| |
| Simon Lord 2005-08-09, 8:45 pm |
| I have a working solution for SWF's which *might* be of some help to
you:
(1) I based my multi-language caption files on XML and included a
*frame number* to display the caption. It looks something like this:
<node>
<node frame="1" caption="" />
<node frame="5" caption="Welcome to smoke, we smoke..." />
<node frame="20" caption="timings within an HD project." />
</node>
(2) The project makes use of a custom player control in which I have
the following .as code (trimmed down for simplicity and I skipped the
step where I load the XML file which is represented as langnotes
below):
onClipEvent (enterFrame) {
// ------------------------------------------------
// POST THE ACCOMPANYING CAPTIONS FOR THE MOVIE CLIP
// ------------------------------------------------
for (var i = 0; i < langnotes.length; i++) {
if (movieArea._currentframe >= Number(langnotes[i].frame)) {
captions.captionLang.text = langnotes[i].caption;
}
}
}
}
.... you can swap languages, mess with the timeline and it never fails.
Not sure how well this translates to FLV as I honestly have not done
much work with that format as of yet. Hope it gives you a few ideas.
(I'd love to show off and point you to an example which is currently
online, but the client posted the material early while they crank out
the english, french and japanese XML caption files - so you wouldn't
actually see the captions for another week or two.)
On Aug 9, 2005, at 9:46 AM, acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane.org wrote:
> I'm sure this has been discussed before, but after checking the wikki,
> I
> am still wondering as to the best method to accomplish multi-language
> subtitles with my FLV's. Currently, I have multiple .xml docs that
> have
> the subtitles defined in seconds, and I'm parsing the proper language
> XML,
> and adding the subtitles as cuePoints to the mediaPlayer.... I'm sure
> there is a much better way to do this, as I'm loosing sync when I
> switch
> movies (weird how removeAllCuePoints doesn't seem to be working the
> way I
> expected it to)...... anyways, can someone point me in the right
> direction?
>
> Thanks everyone,
>
> AC
>
> =-----------------------------------------------------------
> Supported by Fig Leaf Software - http://www.figleaf.com
> =-----------------------------------------------------------
>
> To change your subscription options or search the archive:
> http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
>
>
Sincerely,
Simon
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
| |
| acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane. 2005-08-09, 8:45 pm |
| Thanks for the link, I was looking at this tool earlier... I am actually
hoping to create this functionality using Client Side actionScript. Am I
wasting my time?
I've got it pretty close now... just wondering as to other suggested
methods using AS2.0
Thanks again,
AC
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
| |
| acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane. 2005-08-09, 8:45 pm |
| Thanks simon, my XML looks very similar to yours, I'm doing:
<subtitles>
<caption seconds="2">This would be caption to apprear at 2
seconds</caption>
<caption seconds="10">This caption would display at ten
seconds</caption>
..etc
</subtitles>
Then of course in my flash, I load the approapriate language xml file, and
use then add cue points while looping through the nodes
it looks something like
<inside the onLoad method>
var xnRoot:XMLNode = this.firstChild
for(var i:Number = 0; i < xnRoot.childNodes.length; i++) {
_root.mediaDisplay.addCuePoint(xnRoot.childNodes[i].firstChild.nodeValue,
xnRoot.childNodes[i].attributes.seconds)
}
then I'm setting up a listener to listen for the cue points and displaying
the text... running into a few problems at this point... just wondering if
I'm on the right track 
Thanks again,
AC
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
| |
| Stefan Richter 2005-08-09, 8:45 pm |
| I think you are. While I do not use different languages I have a similar app
which syncs Flashpaper slides toa video, works well and in the same way by
simply checking ns.time.
Stefan
-----Original Message-----
From: flashcomm-bounces-1Ss2GqJETD3yZ38Mhd3e/9ZfFG6BLHNm@public.gmane.org
[mailto:flashcomm-bounces-1Ss2GqJETD3yZ38Mhd3e/9ZfFG6BLHNm@public.gmane.org] On Behalf Of
acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane.org
Sent: Tuesday, August 09, 2005 3:30 PM
To: FlashComm Mailing List
Subject: Re: [FlashComm] FLV + Subtitles
Thanks simon, my XML looks very similar to yours, I'm doing:
<subtitles>
<caption seconds="2">This would be caption to apprear at 2
seconds</caption>
<caption seconds="10">This caption would display at ten
seconds</caption>
..etc
</subtitles>
Then of course in my flash, I load the approapriate language xml file, and
use then add cue points while looping through the nodes
it looks something like
<inside the onLoad method>
var xnRoot:XMLNode = this.firstChild
for(var i:Number = 0; i < xnRoot.childNodes.length; i++) {
_root.mediaDisplay.addCuePoint(xnRoot.childNodes[i].firstChild.nodeValue,
xnRoot.childNodes[i].attributes.seconds)
}
then I'm setting up a listener to listen for the cue points and displaying
the text... running into a few problems at this point... just wondering if
I'm on the right track 
Thanks again,
AC
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
| |
| Beto A 2005-08-09, 8:45 pm |
| I haven't actually tried this but couldn't you, if you where streaming, g=
et the stream time and just show the appropriate text info from your xml?=
=20
acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane.org wrote:Thanks simon, my XML looks very similar to y=
ours, I'm doing:
This would be caption to apprear at 2=20
seconds
This caption would display at ten=20
seconds
...etc
Then of course in my flash, I load the approapriate language xml file, an=
d=20
use then add cue points while looping through the nodes
it looks something like
var xnRoot:XMLNode =3D this.firstChild
for(var i:Number =3D 0; i < xnRoot.childNodes.length; i++) {
_root.mediaDisplay.addCuePoint(xnRoot.childNodes[i].firstChild.nodeValue,=
=20
xnRoot.childNodes[i].attributes.seconds)
}
then I'm setting up a listener to listen for the cue points and displayin=
g=20
the text... running into a few problems at this point... just wondering i=
f=20
I'm on the right track 
Thanks again,
AC
=3D-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=3D-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
=09
---------------------------------
Start your day with Yahoo! - make it your home page=20
=3D-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=3D-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
| |
| acolpitts-lrT4F1HGyz9Wk0Htik3J/w@public.gmane. 2005-08-09, 8:45 pm |
| This seems to be working great for me now, silly me, the problem was I
wasn't removing the listener when changing videos!!! so the listener was
doubling up, causing the cuePoints index to be incorrect. less
sleep... more coffee
Thanks again everyone!
AC
=-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
|
|
|
|
|