Jump to content
Search Community

Apogee

Members
  • Posts

    9
  • Joined

  • Last visited

Profile Information

  • Location
    Tucson, AZ USA

Apogee's Achievements

2

Reputation

  1. OK. This works nicely! Thanks to Carl and Jack (from a previous post) Loads video at 7 second point, positions it in center and allows time for playback, then removes it from the stage followed by remaining animation content. Thanks again!!! import com.greensock.*; import com.greensock.easing.*; import com.greensock.loading.*; import com.greensock.events.LoaderEvent; import com.greensock.loading.VideoLoader; import com.greensock.loading.LoaderMax; var video:VideoLoader = new VideoLoader("bookcliffs.flv", {autoPlay:false, container:this}); video.load(); var timeline:TimelineMax = new TimelineMax(); video.content.x = -500 timeline.append(TweenMax.to(two1_mc, .5, {y:230, x:700, ease:Elastic.easeOut, delay:0})); timeline.append(TweenMax.to(two1_mc, 1, {x:700, Y:240, rotation:360, scaleX:1.5, scaleY:1.5})); timeline.append(TweenMax.to(two1_mc, 2, {y:-300, x:-750, z:-1000, delay:3, alpha:0})); timeline.append(TweenMax.to(TextThree_mc, .5, {x:700, y:227, scaleX:1.25, scaleY:1.25}), -1); timeline.append(TweenMax.to(TextThree_mc, .1, {rotation:0, x:700, y:227, scaleX:1.6, scaleY:1.6})); timeline.append(TweenMax.to(TextThree_mc, .8, {x:500, z:-1000, delay:1, alpha:0})); timeline.append(TweenMax.to(video.content, .5, {x:200, y:100, delay:-1})); timeline.addCallback(video.playVideo, 7); timeline.append(TweenMax.to(video.content, .5, {rotationY:60, x:1000, y:100, delay:10})); timeline.append(TweenMax.to(four1_mc, .5, {y:220, x:700, scaleX:2, scaleY:2, delay:-.5})); timeline.append(TweenMax.to(four1_mc, 1.2, {rotationX:30, rotationZ:30, y:245, x:700, scaleX:2.5, scaleY:2.5, delay:1})); timeline.append(TweenMax.to(four1_mc, .5, {rotationX:0, rotationZ:0, scaleX:2, scaleY:2})); timeline.append(TweenMax.to(five1_mc, 3, {x:800, y:240})); timeline.append(TweenMax.to(five1_mc, .5, {scaleX:3, scaleY:3})); timeline.append(TweenMax.to(five1_mc, .5, {rotationX:120, x:-100, y:30, z:-1000, delay:0, alpha:0}));
  2. OK. This works nicely! Thanks to Carl and Jack (from a previous post) Loads video at 7 second point, positions it in center and allows time for playback, then removes it from the stage. Thanks again!!! import com.greensock.*; import com.greensock.easing.*; import com.greensock.loading.*; import com.greensock.events.LoaderEvent; import com.greensock.loading.VideoLoader; import com.greensock.loading.LoaderMax; var video:VideoLoader = new VideoLoader("bookcliffs.flv", {autoPlay:false, container:this}); video.load(); var timeline:TimelineMax = new TimelineMax(); video.content.x = -500 timeline.append(TweenMax.to(two1_mc, .5, {y:230, x:700, ease:Elastic.easeOut, delay:0})); timeline.append(TweenMax.to(two1_mc, 1, {x:700, Y:240, rotation:360, scaleX:1.5, scaleY:1.5})); timeline.append(TweenMax.to(two1_mc, 2, {y:-300, x:-750, z:-1000, delay:3, alpha:0})); timeline.append(TweenMax.to(TextThree_mc, .5, {x:700, y:227, scaleX:1.25, scaleY:1.25}), -1); timeline.append(TweenMax.to(TextThree_mc, .1, {rotation:0, x:700, y:227, scaleX:1.6, scaleY:1.6})); timeline.append(TweenMax.to(TextThree_mc, .8, {x:500, z:-1000, delay:1, alpha:0})); timeline.append(TweenMax.to(video.content, .5, {x:200, y:100, delay:-1})); timeline.addCallback(video.playVideo, 7); timeline.append(TweenMax.to(video.content, .5, {rotationY:60, x:1000, y:100, delay:10})); timeline.append(TweenMax.to(four1_mc, .5, {y:220, x:700, scaleX:2, scaleY:2, delay:-.5})); timeline.append(TweenMax.to(four1_mc, 1.2, {rotationX:30, rotationZ:30, y:245, x:700, scaleX:2.5, scaleY:2.5, delay:1})); timeline.append(TweenMax.to(four1_mc, .5, {rotationX:0, rotationZ:0, scaleX:2, scaleY:2})); timeline.append(TweenMax.to(five1_mc, 3, {x:800, y:240})); timeline.append(TweenMax.to(five1_mc, .5, {scaleX:3, scaleY:3})); timeline.append(TweenMax.to(five1_mc, .5, {rotationX:120, x:-100, y:30, z:-1000, delay:0, alpha:0}));
  3. Hi Greensock fans! I'm trying to load a video into a TimelineMax which contains animated graphics and text symbols. I hope to make it something like a TV commercial or online promo. This code plays the animations, but the video doesn't load. If i use the timeline.addPause, nothing plays. If i change video autoPlay to true, video plays, but is not in sequence. import com.greensock.*; import com.greensock.easing.*; import com.greensock.loading.*; import com.greensock.events.LoaderEvent; import com.greensock.loading.VideoLoader; import com.greensock.loading.LoaderMax; var timeline:TimelineMax = new TimelineMax(); timeline.append(TweenMax.to(two1_mc, .5, {y:230, x:700, ease:Elastic.easeOut, delay:0})); timeline.append(TweenMax.to(two1_mc, 1, {x:700, Y:240, rotation:0, scaleX:1.5, scaleY:1.5})); timeline.append(TweenMax.to(two1_mc, 2, {y:-300, x:-750, z:-1000, delay:3, alpha:0})); timeline.append(TweenMax.to(TextThree_mc, .5, {x:700, y:227, scaleX:1.25, scaleY:1.25}), -1); timeline.append(TweenMax.to(TextThree_mc, .1, {rotation:0, x:700, y:227, scaleX:1.6, scaleY:1.6})); timeline.append(TweenMax.to(TextThree_mc, .8, {x:500, z:-1000, delay:1, alpha:0})); //timeline.addPause(); var queue:LoaderMax = new LoaderMax(); queue.append(new VideoLoader("bookcliffs.flv", {container:this, autoPlay:false})); queue.addEventListener(VideoLoader.VIDEO_COMPLETE, onComplete); function onComplete(event:LoaderEvent):void{ trace("video done playing"); timeline.play() } queue.load(); timeline.resume(); timeline.append(TweenMax.to(four1_mc, .5, {y:220, x:700, scaleX:2, scaleY:2, delay:0})); timeline.append(TweenMax.to(four1_mc, .5, {y:245, x:700, scaleX:2.5, scaleY:2.5, delay:1})); timeline.append(TweenMax.to(four1_mc, .5, {scaleX:2, scaleY:2})); timeline.append(TweenMax.to(five1_mc, 3, {x:800, y:240})); timeline.append(TweenMax.to(five1_mc, .5, {scaleX:3, scaleY:3})); timeline.append(TweenMax.to(five1_mc, .5, {rotationX:120, x:-100, y:30, z:-1000, delay:0, alpha:0})); Obviously, I'm missing something, maybe this isn't possible, but this would be of value to myself and others if it will work. Thanks in advance for the help. Much appreciated.
  4. Correction: http://www.nafri.gov/Flash/NAFA_9.11_SIM.swf
  5. Carl, Thanks again for your continuing support. There still seems to be a problem. Timeline runs, but video does not. I'll be studying addPause and LoaderMax for a couple of days, maybe determine what's wrong. Also making sure I have the latest v.12. Meanwhile, here's an interactive training support project I've done if you're interested. (It's not TimelineMax). http://www.nafri.gov/Flash/NAFA_9.11.swf Can select landscape, drag and drop symbols, etc. Hold down keys indicated under "Effects" to show smoke, drop water from planes, etc.
  6. Thanks again for the help Carl. This code gives me an error: expecting rightbrace before autoPlay. If I delete the autoPlay:false, there's no error, the animations run, but (as expected) the video plays in its own timeline. import com.greensock.*; import com.greensock.easing.*; import com.greensock.events.LoaderEvent; import com.greensock.loading.VideoLoader; import com.greensock.loading.LoaderMax; var timeline:TimelineMax = new TimelineMax(); timeline.append(TweenMax.to(two1_mc, .5, {y:230, x:180, ease:Elastic.easeOut, delay:0})); timeline.append(TweenMax.to(two1_mc, 1, {x:175, Y:240, rotation:0, scaleX:1.5, scaleY:1.5})); timeline.append(TweenMax.to(two1_mc, 2, {y:-300, x:-750, z:-1000, delay:3, alpha:0})); timeline.append(TweenMax.to(TextThree_mc, .5, {x:205, y:227, scaleX:1.25, scaleY:1.25}), -1); timeline.append(TweenMax.to(TextThree_mc, .1, {rotation:0, x:175, y:227, scaleX:1, scaleY:1})); timeline.append(TweenMax.to(TextThree_mc, .8, {x:500, z:-1000, delay:1, alpha:0})); //timeline.pause(); var video:VideoLoader = new VideoLoader("bookcliffs.flv", {container:this autoPlay:false}); video.addEventListener(VideoLoader.VIDEO_COMPLETE, onComplete); function onComplete(e:LoaderEvent):void{ trace("video done playing"); timeline.play() } video.load(); timeline.append(TweenMax.to(four1_mc, .5, {y:220, x:200, scaleX:2, scaleY:2, delay:.5})); timeline.append(TweenMax.to(four1_mc, .5, {y:245, x:550, scaleX:2.5, scaleY:2.5, delay:0})); timeline.append(TweenMax.to(four1_mc, .5, {scaleX:2, scaleY:2})); Also need to position the video. Should it be inside an mc? Your advice is much appreciated!
  7. Carl answered my first inquiry about using a short video (flv) as part of a TimelineMax project. Thank you Carl, but I don't know how to set up the pause(), addCallback, and resume(). Here's an abbreviated version with an example of what I'd like to do (red text): import com.greensock.*; import com.greensock.easing.*; var timeline:TimelineMax = new TimelineMax(); timeline.append(TweenMax.to(two1_mc, .5, {y:230, x:180, ease:Elastic.easeOut, delay:-1})); timeline.append(TweenMax.to(two1_mc, 1, {x:175, Y:240, rotation:0, scaleX:1.5, scaleY:1.5})); timeline.append(TweenMax.to(two1_mc, 2, {y:-300, x:-750, z:-1000, delay:3, alpha:0})); //pause the timeline: timeline.pause(); //tell the video to play: timeline.addCallback(playVideo, 0, ["video_mc"]); //resume the timeline when the video is done playing (VIDEO_COMPLETE event) timeline.resume(); timeline.append(TweenMax.to(TextThree_mc, .5, {x:205, y:227, scaleX:1.25, scaleY:1.25}), -15); timeline.append(TweenMax.to(TextThree_mc, .1, {rotation:0, x:175, y:227, scaleX:1, scaleY:1})); timeline.append(TweenMax.to(TextThree_mc, .8, {x:500, z:-1000, delay:1, alpha:0})); I've been through the forums and researched online but don't understand the correct sequence or how to set up the play function for addCallback or onComplete / VIDEO_COMPLETE event. Any help is much appreciated. Thanks in advance.
  8. Carl, Thanks for the quick reply. I've enjoyed all your tutorials and will continue to learn all that's available with Greensock. I guess I'm inspired by TV commercials which use text and graphics effects in conjunction with video. I think this might help engage our young students in firefighter training. Seems like the pause(), resume() approach might work. I'll keep working on it and stay tuned to this forum. Your help is much appreciated. Eric
  9. I'm trying to load a video (flv) into a TimelineMax sequence. Various animations should occur using text and graphic objects with "timeline.append...", then video should play through before next animation, etc. I've tried putting video in an mc,but it doesn't work. I'll learn and use LoaderMax to achieve this if it can handle text and graphic animations. Any help is appreciated. Thanks.
×
×
  • Create New...