ignotion Posted July 29, 2015 Share Posted July 29, 2015 Hello, I'm trying to loop a video and the video loops, but not at the end of the video, it's cut at approx 50% of the video. The video is 4 seconds long and at the half it just jumps to the end and starts the loop again. Any idea in how to prevent that? I'm loading the video with this line: var lVideoPlayer:VideoLoader = new VideoLoader("assets/myVideo.flv", {name:myVideo.flv,container:videosParents[_videoNdx], autoPlay:false, requireWithRoot:this.root, deblocking:1, repeat:(_videoNdx==1?-1:1),onComplete:_onConnect }); I would need perfect seamless loop, but hopping that way is hard. At the same time, the video triggers 2 events, right now I'm tracking that events using VideoLoader.PLAY_PROGRESS but perhaps it would be more efficient using cues? Well, thank you in advance, Toni Link to comment Share on other sites More sharing options...
Carl Posted July 29, 2015 Share Posted July 29, 2015 To loop the video please start with the code here: http://greensock.com/forums/topic/4570-videoloader-repeat/?p=14782 Due to some constraints of the Flash Player it is difficult to guarantee a perfect seamless loop. Link to comment Share on other sites More sharing options...
ignotion Posted July 30, 2015 Author Share Posted July 30, 2015 Hi Carl, thanks for answering. Isn't that the same than specifying repea = -1? As I can see on VideoLoader:_statusHandler, line 932: if (this.vars.repeat == -1 || uint(this.vars.repeat) > _repeatCount) { _repeatCount++; dispatchEvent(new LoaderEvent(VIDEO_COMPLETE, this)); gotoVideoTime(0, !_videoPaused, true); Link to comment Share on other sites More sharing options...
Carl Posted July 30, 2015 Share Posted July 30, 2015 either way should work. have you tried using a different video? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now