views:

162

answers:

1

I am working on a Flash Video player and am implementing the ability to start a video at x time within the span of an FLV (served from FMS). I am able to start it x seconds into a stream without any issue using

netStream.play(source, startTime);

but as far as I can tell, it only supports seconds. I am looking to be able to give a start time (or even a seek time if that is supported) in milliseconds, or really anything more precise than whole seconds.

Anyone know of any way to achieve this even by monkey patching the fl classes?

Thanks,

Doug

+1  A: 

Well the seek will allow you to seek by a number of frames, but the spec says that it only seeks to the closes I-Frame in the FLV. That will become a problem with any method you use, because the I-Frames are the only ones that actually contain the whole picture frame (here's the gist of that).

Matti
Thanks for the answer. Unfortunately according to the NetStream doc, seek(offset); will still only support seeking to whole seconds: "offset:Number — The approximate time value, in seconds, to move to in a video file.". Because of our FMS I am able to seek to any second in the video without it snapping to the nearest keyframe, I'm ideally trying to get even more precise than that. Thanks for the help anyways.
DigTheDoug
If the offset var is a Number, you *should* be able to pass a fraction - eg netStream.play(source, 1.456)
Reuben