Copy link to clipboard
Copied
Hi all,
I am having Fast - Forward and Rewind Functionality in my Custom Video Player, Which I done by calling seek method on regular interval . which works fine. but for same cases , the video playHeadTime get changed , but the frame does not change with that, and video's playHeadTime and Frame does not come with sync.
No idea how to make it woking.
Can anybody have any idea on that??
Thanks
Meghana
Copy link to clipboard
Copied
show me the code.
Copy link to clipboard
Copied
Here is My Code
private function StartForward(evt:MouseEvent)
{
trace("StartForward Called");
SeekSpeedFor = SeekSpeedFor +10;
trace("SeekSpeed: " + SeekSpeedFor);
SeekPointFR = myVid.playheadTime;
trace("Initial PlayHead Time: " + SeekPointFR);
myVid.stop();
RewindFlag = false
ForwardFlag= true;
myVid.addEventListener(Event.FRAME_CONSTRUCTED,OnConstructFrame);
}
public function OnConstructFrame(evt:Event):void
{
if(ForwardFlag)
{
if(myVid.playheadTime >= SeekPointFR)
{
trace("Before Seek Cal.: " + SeekPointFR);
SeekPointFR = SeekPointFR + SeekSpeedFor;
trace("After Seek Cal.: " + SeekPointFR);
myVid.seek(SeekPointFR);
if(SeekPointFR > ftime)
{
ForwardFlag=false;
myVid.removeEventListener(Event.FRAME_CONSTRUCTED,OnExitFrame);
}
}
}
}
I guess issue may be of buffer... i have set bufferTime to 30 sec.... for a 60 min video i get frame changed after 15-20 min video get played.. this is my guess.. plz help me out if anybody have idea.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now