Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
sputn1k

LoaderMax VideoLoader videoPlay()

Recommended Posts

hi there guys, my first post here :)

 

thanks for greensock its the most amazing tweening tool!!

 

i have having an issue with LoaderMax using VideoLoader,

queue.append( new VideoLoader("video.f4v", {name:"video", estimatedBytes:3000, container:this, x:0, autoPlay:false}) );

function completeHandler(event:LoaderEvent):void {
var v = LoaderMax.getLoader("video").rawContent;
v.playVideo();
}

i have also tried;

LoaderMax.getContent("video").rawContent;

but both doesnt work?! - if i set the VideoLoader autoPlay:true video plays back ok. so i know its working just can figure out the correct syntax any help would be very much appreciated.
 

cheers

Link to comment
Share on other sites

The playVideo() method is associated with the VideoLoader instance, not the rawContent. 

 

Try this:

var v = LoaderMax.getLoader("video");
v.playVideo();
Link to comment
Share on other sites

  • 1 month later...

@jack - thank you very much that is working.

 

i have one other issue, when using this "visible:false";

queue.append( new VideoLoader("video.f4v", {name:"video", container:this, autoPlay:false, visible:false}) );

on the "function completeHandler";

var video  = LoaderMax.getLoader("video").rawContent;

LoaderMax.getContent("video").visible = true;
//LoaderMax.getContent("video").rawContent.visible = true; //tried both 

video.playVideo();
Link to comment
Share on other sites

ok it is working now.. (maybe flash playing up) sorry for the confusion thanks again!

  • Like 1
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×