video.Maru
by polyGeek polyGeek logo



 

miscellaneous controls

June 24th, 2007 . by polyGeek
polyGeek TV Watch the video tutorial covering how to use the miscellaneous controls

There are a few other controls that don’t really fit into any particular category.

The startPlay button is there for you to create the interface like youTube made popular. You can place this startPlay MovieClip over the videoWindow. When the video loads it will automatically pause - even if the play/pause button has an instance name of play_btn.

When the user clicks the startPlay MovieClip it will vanish and the video will begin playing.

The loop control is very easy to use. It can be a MovieClip or TextField just so long as the instance name is loop. It obviously causes the video to play again when it reaches the end.

The back# control is a shortcut for jumping backward in the video by a set number of seconds. As a for instance. If you created a MovieClip with an instance name of back5 then when the user clicked on it the video would jump back approximately 5 seconds.

Note: Flash video can only seek - jump - to a video keyframe. When you use the seek method() in Actionscript it will seek to the nearest video keyframe. The more keyframes the finer the scrubbing and jumping is but the filesize will be larger.

The buffer# controls how many seconds of video get buffered before playback begins. For instance if you created a MovieClip with an instance name of buffer5 then the first five seconds of the video would buffer before playback begins. This does not mean that it would pause for five seconds. Hopefully it would only take 2-3 seconds to buffer 5 seconds of video. Otherwise you are streaming at about the same rate that the video is playing and playback will likely be choppy. In that case you should re-compress your video file to a lower data rate.

If you would like to enable smoothing for the video then create a MovieClip with an instance name of smoothing. This acts as a sort of smart blur to your video and can improve the apparent quality in some instances. Especially if you are stretching the video’s width/height during playback.

If you would like for the video to pause on the last frame of the video then create a MovieClip, it can be off Stage, with an instance name of pauseOnLastFrame.

For debugging purposes there is another boolean toggle called verbose. If you create a MovieClip with the instance name of verbose it will trace messages to the Flash Authoring tools Output window. This will display things like video status, the various MovieClips that were found, and not found, etc. This will have no effect on display or playback when viewed by your users.

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • Technorati
  • del.icio.us
  • Facebook
  • Google
  • StumbleUpon

11 Responses to “miscellaneous controls”

  1. comment number 1 by: Josh

    Lovin the new site Dan! Hey what are the chances that there is (or will be) a function to not start pre-loading the video thats cued to be played- eg: it only starts buffering in when the user clicks play. I just have some big video files in several players on a page and wish to save bandwidth etc and not have the user load them all unless actually wanting to view… do you know want i mean?
    Any thoughts appreciated! Cheers Josh ;)

  2. comment number 2 by: polyGeek

    @Josh, That’s a great suggestion. I’m going to bake this into the startPlay button.

  3. comment number 3 by: kym

    Does anybody else have plobrems with the “loop” function ?
    Have tried both options with no luck !
    My movieclip with instance name of “loop” is on the same layer as everything else, and am outputting as flash “8″ - the .fla was made from an .avi with sorenson, and I cannot find any reference to looping in that.
    Just thought I would post incase someone else had the same plobrem and had a solution.
    Awesome flash/video tool bTw

  4. comment number 4 by: polyGeek

    @Kym, I’ll shoot you an email and try to help you out with your problem.

  5. comment number 5 by: chris

    i’m trying to enable smoothing. a few details I don’t understand. is it an empty movie clip? or do i need to draw an object? at what level and on what layer does it need to be located? is there any actionscript involved for this method of implementation? thanks for this great tool! i can’t download video so great at the moment, otherwise i’m sure your tutorials explain this…

  6. comment number 6 by: polyGeek

    @Chris, The smoothing MovieClip can be anything you want. It just needs to have an instance name of “smoothing”. I’d make it a TextField, with a text value of “smoothing” and then hit F8 to make it a MovieClip. Then give it the instance name “smoothing” and you’re done.

    You can place it off the stage so that it can’t be scene outside of the authoring environment. You should place it on the same level or nested inside something on the same level as the video.Maru SWC.

    And no, there’s no code to write.

  7. comment number 7 by: nathan

    Newbie to videoMaru
    Having real problems making my vid stop on the last frame. Tried pauseOnLastFrame without any success.

    Any ideas?

  8. comment number 8 by: polyGeek

    @Nathan, sometimes the problem is with the video itself. Videos that are encoded with the Flash Encoder always seem to work. But people using other encoders have had problems.

    Could that be the situation with you?

  9. comment number 9 by: modoguy

    Your work is an inspiration. Thanks for sharing with the Flash community!

  10. comment number 10 by: SJunkie

    It seems that if an mp4 (h.264) clip is loaded, buffer is disregarded and the file plays only as soon as it has been fully downloaded.

    :(

  11. comment number 11 by: polyGeek

    @SJunkie, You’re talking about H.264 in general, correct? Because I don’t think videoMaru will play anything other than an MP3 or FLV right now - although it’s on the list.

    I haven’t experimented with playing H.264 encoded files yet. My guess is that it may require FMS3 to play them before the file is completed it’s download. Seems I read something about that before but I’m not certain.

Leave a Reply

Name

Mail (never published)

Website