LOADING
Loading
Hi , welcome back.
LogoutLOGOUT
 
  Lost password?  
Hi
 




 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #4  
Old 05-29-2012, 04:31 PM
FlashMove's Avatar
FlashMove FlashMove is offline

FlashMove Master
 
Join Date: Jan 2000
Location: Singapore
Posts: 4,597
Rep Power: 10
FlashMove is on a distinguished road
Sorry for the late reply. Here's a would be solution.
Flash Player 11 has a 1 second lag when using seek(0) with NetStream.play or NetStream.stop.
The following code provides a more seamless loop - still not perfect, but much better.
Actionscript:
var mStream:NetStream;
var mDuration:Number;

...

addEventListener(Event.ENTER_FRAME, onEnterFrame);

...

function onEnterFrame(e:Event):void
{
    if( mStream.time > (mDuration-0.05) )
    { 
        if( mLooping )
        {
            mStream.seek(0);
        }
    }
}

function onMetaData(info:Object)
{
    mDuration = info.duration;
}
__________________
Actionscript tag . Donate Here . Testimonial . Join Flash Chat UserGroup . Twitter . Facebook
Reply With Quote
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Launch of new AIR 3.2, Flash Player 11.2 and Premium Features for Gaming FlashMove General Flash 1 04-17-2012 09:28 AM
Looping Problem & Restrict Downloading Query CL8N Flash CS3 / Flash 9 0 02-29-2008 05:44 AM
How to stop the looping? KOMPLEX21 Flash MX 1 07-03-2004 01:52 AM
Imported clip won't stop looping DreamThrall Flash MX ActionScript 2 09-06-2003 01:51 PM
Stop Looping ml323f Newbies 4 01-23-2003 02:18 AM




All times are GMT. The time now is 08:16 AM.