Cue Points with netstream

I've created a custom object without the FlvPlayback
component. I used the following code:
var nc:NetConnection = new NetConnection();
nc.connect(null);
var ns:NetStream = new NetStream(nc);
myVid.attachVideo(ns);
ns.play("flv/home/intro.flv");
That flv file has embedded cue points. How do I access them?
I can access them easily if I were using the FlvPlayback component,
but I don't think the cue points are getting through the netstream.
Any ideas?

use the ns.onCuePoint event handler.

Similar Messages

  • Adding cue points to NetStream

    Hello I have been working on a project and have loaded videos using netstream.  I have several cue points that advance the timeline to a certain keyframe.  Would anyone have the script for NetStream that would do this, for example, when the video reaches cue1 it would advance the timeline to frame 10?
    Thank you so much for your help.
    mark.

    Since no one has yet posted on this, I'll re-post part of a response to another post which deals specifically with using cue points with a NetStream video player:
    OK, here is a working NetStream cue point:
    var ns:NetStream = new NetStream(nc);
    video_screen.attachVideo(ns);
    /* Name of your video, with correct path, goes here */
    ns.play("my_video.flv");
    ns.onCuePoint = function(evt:Object){
        trace(evt.name);
        trace(evt.time);
        if(evt.name == "jump_100") {
            trace("YO !Jump to 100!");
            gotoAndStop(100);
    Reading this code:
    set a new variable "ns" which is a new NetStream
    attach a video to "video_screen"... the instance name of the video on the stage
    now use that variable "ns" to play a video with file name "my_video.flv"
    use ns to listen for an "event" type cue point Object
    when the cue point is detected trace the event name and time
    if the event name is exactly equal to "jump_100"
    then trace "YO !Jump to 100!"
    and then gotoAndStop at frame 100
    For this exact code to work, your NetStream variable must be named "ns"
    In the video you play, there must be a cue point of the "Event" type with the name "jump_100"
    There must be at least 100 frames in the timeline.
    Take it in small steps;
    First make sure you can play the video using NetStream ... that's all.
    Next, add the trace to detect the cue point... if you can't detect it, of course it won't do anything.
    Only after you can successfully play the video and detect the cue point, should you attempt the cue point action (jump to frame 100).
    You can also add more "if" statements if there are multiple cue points.
    If cue point 1, then do this.
    If cue point 2, then do this.... etc.
    Best wishes,
    Adninjastrator

  • How to play a cue point with mixer

    I know how to play a cue point of sound with the method:
    sound(1).queue([#member: ...  #startTime: ... EndTime: ... ])
    How can I transfer the method of cue point using  the mixer?
    I need to have any hint about this because I must use both cue
    point with playrate, at my begginer level of knowledge I know that:
    1) I can't use "playrate" with  "sound(1).play()" method.
    With this method I can use cue point;
    2) I'm trying to know If I can use cue point with   mixer method.
    With this method I can use "playrate" .
    It is also for me important to know if it is possible or
    impossible to solve this problem in director.
    Thanks.

    iPhone 3gs, 4 or 4s?
    With the former two, just drag the videos to the desktop iTunes and sycnhronize to your iPad. They will be synched to the stock Videos.
    With the latter, you can either resize the video to 720p (or less) OR use a third-party app (It's Playing, AVPlayerHD, GoodPlayer being the best choices) to play it back. I'd go with the latter to avoid quality degradation and long-lasting reencodings.

  • I need help with my event-based cue points with audio

    Im having trouble with my video game project for my action script 3 class at school. Here is what i did, i made a game called Tailgate toss up. I filmed my character and rendered it in Adobe Premiere. I than brought my .mov file into After Effects and I put event-based cue points-
    my first cue point at 0:00:03:13 called "loop"
    my second cue point at 00:00:03:27 called "draw"
    my third cue point at 00:00:05:24 called "bang"
    my fourth cue point at 00:00:13:29 called "dead"
    my fifth cue point at 00:00:14:29 called "You Lose"
    my last cue point at 00:00:19:14 called "End"
    Here is my action script 3 code
    ///first frame:
    start_btn.addEventListener(MouseEvent.CLICK, startGame);
    function startGame(event:MouseEvent){
    gotoAndStop(2);
    SoundMixer.stopAll()
    stop();
    ///second frame:
    stop();
    var loopTime
    var hitHim:Boolean = false;
    var vConnection:NetConnection = new NetConnection();
    vConnection.connect(null);
    var vStream:NetStream = new NetStream(vConnection);
    var client:Object = new Object();
    client.onCuePoint = onCuePoint;
    vStream.client = client;
    var myVideo:Video = new Video(418, 480);
    myVideo.y = 0;  ///this adjusts where the video is, right now it is the size of the canvas which is 418,480
    addChild(myVideo);
    myVideo.attachNetStream(vStream);
    vStream.play("michelle.flv");
    var throw_bottle:Sound
    throw_bottle = new Sound(new URLRequest("audio/throw_bottle.mp3")); //change to button noise, will add sound into ae file
    target_mc.addEventListener(MouseEvent.CLICK, shoot);
    target_mc.buttonMode = true;
    target_mc.visible = false;
    draw_mc.visible = false;
    function onCuePoint(cuePoint:Object):void {
       if(cuePoint.name == "loop"){
    loopTime = cuePoint.time;
        if(cuePoint.name == "draw"){
    var randomLoop:Number = Math.random()*10;
    if(randomLoop > 2){
    vStream.seek(loopTime);
    }else{
    setChildIndex(target_mc, numChildren - 1);  
    setChildIndex(draw_mc, numChildren - 1);    
    target_mc.visible = true;
    draw_mc.visible = true;
    if(cuePoint.time == "5:24"){
    draw_mc.visible = false;
    target_mc.visible = false;
    if(!hitHim){
    vStream.seek(15);    
    if(cuePoint.name == "dead"){
    vStream.close();
    myVideo.clear();
    gotoAndStop(3);
    if(cuePoint.name == "end"){
    gotoAndStop(3);
    function shoot(event:MouseEvent){
    throw_bottle.play();
    hitHim = true;
    ///my third and last frame
    playAgain_btn.addEventListener(MouseEvent.CLICK, playAgain);
    function playAgain(event:MouseEvent){
    gotoAndStop(2);
    SoundMixer.stopAll()
    stop();
    When I have no audio it works perfectly, no problems. When I bring audio in i re-render it as a .mov file and bring it back into After Effects and add the cue points to it. Than i re-render it out again as a flv file. When i bring it into my flash project it will work when the looping variable does just one loop and my target will appear so you can click on it or not. But when the looping variable makes it loop 2 to 10 times it skips over the catching (the part of the clip if you clip the button) and goes directly to the dropping of the can, not giving you the option of clicking the button. So basically it skips the "draw" or second cue point of my game and goes to "You Lose" cue point.
    Any suggestions?

    Hi,
    The latest audio driver for your machine is on the following link.
    http://ftp.hp.com/pub/softpaq/sp59501-60000/sp59649.exe
    Regards,
    DP-K
    ****Click the White thumb to say thanks****
    ****Please mark Accept As Solution if it solves your problem****
    ****I don't work for HP****
    Microsoft MVP - Windows Experience

  • Cue points with Sound Forge 9.0a?

    Just upgraded from SF 6 to 9 … I haven’t needed
    cue points in a long time but it used to be as simple as saving a
    WAV file with markers in it. With SF 9 I have an option to save
    WAVs with and without meta data. Saving without meta data strips
    out the cue points (logical enough, reading the sound file back
    into SF 9 confirms the markers are gone) … saving with meta
    data creates a file Director 10.1 won’t read (“Having
    trouble reading file, Continue?) Has something changed? I’ve
    searched here and on the web at large and not seen any mention of
    issues between SF 9 and Director. I’ve tried two machines
    with the same result.

    Fixed it, sort of… Apparently by default Sound Forge
    doesn’t name the cue points at all and Director doesn’t
    like this (at least up to MX04, don’t know about 11). To
    create wav files with metadata that Director will read:
    In Sound Forge navigate to Options > Preferences >
    Labels.
    Check the box “label markers”, I also used the
    prefix and leading zero options
    Any new markers will now have labels
    For my present project I already had 83 cue points accurately
    positioned that I didn’t want to remake. In this case I
    renamed each cue point by hand, one at a time. Insanely tedious but
    better than marking the file again.

  • Cue points with MP3 files

    Can cue points be added to mp3 files to control the movie? I
    have used them in director, but an unsure if they can be used in
    flash.

    yes.
    myMedia.addCuePoint("name", 10);
    where 10 is the time at which to add the cue point to the MP3
    file.

  • NetStream Cue Points

    Tried adding cue points via as3 code but haven't been able to find anyway to accomplish this task. Read allot places that when you load a video via netStream you can't add cue points with actionscript. The only way is to embed the cue points is into the video. But this is not an obtain for me since someone else does the videos and they may change or be modified at some time. I can add actionscript cuePoints with the FLVPlayback component but I am looking for ways of increasing video performace.
    By the way what is the difference\advantage of using netStream over using the FLVPlayback component? Often wander this but haven't read anything to say one is better then the other when running video over the web.
    Thanks

    Thanks kglad. Being able to customize is always better in my flash world. LOL
    I'll have to stay with the FLVPlayback component as long as I have to use cue points in my videos.
    Thanks

  • Using event cue points to add buttons

    How do I go about having buttons display in an external flv file?  I know I can establish event cue points with Adobe media encoder.  I want the the buttons and graphics to appear and stay on the screen, even though the external flv loops.  Its been a long day and I have exhausted all other options, otherwise I would not have asked on here.  Thanks in advance.  Oh btw using Flash cs 5.5 and as 3.  thanks

    i just added x and y locations:
    Movie01.addEventListener(MetadataEvent.CUE_POINT,cuepointF);
    function cuepointF(e:MetadataEvent):void{
    trace(e.info.name);  // this will display your cuepoints when their dispatched.  you'll use if-statements below this line to add your buttons.  eg,
    if(e.info.name=="middle"){
    addChild(button1);  // assuming button1 is already created.
    button1.x=639;
    button1.y=140.5;
    it worked with no errors
    thanks again! 

  • Event Cue Points

    I am working with event cue points and I have it working with
    action script and embedded cue points. What I am trying to figure
    out is how to tie a specific events or movie clip with specific cue
    points. Right now all the movie clips play whenever I hit any cue
    point. I have not figured out how to tie specific cue points with
    specific events. Anyone have knowledge of this that can direct me
    properly. I would highly appreciate it. Thanks

    First of all thanks for the reply. I didn't explain myself
    well. I know about the stop frame on the first frame. My cue points
    are working. I want to be able to play different movies cued up at
    different times in the video. Right now all my movie clips play at
    all the cue points. I want a specific movie to play at a specific
    cue point then later in the video another different clip play at a
    difffent time element in the movie. Thanks. I really appreciate the
    help.

  • Cue points - listener vs event?

    I'm a little over my head here...
    I have a movie that loads an external flv. In the flv I have
    a cue point at
    the very end to mark the end of the movie. Once the flv is
    done playing,
    I'd like to advance to the next frame.
    There are a few posts here and there and I'm not sure if I'd
    be better
    testing for the end cue point with a listener or if it could
    be an event.
    Any help would be appreciated.
    I'm using Flash 8 Pro/PC

    David,
    >> There are a few posts here and there and I'm not
    sure
    >> if I'd be better testing for the end cue point with
    a
    >> listener or if it could be an event.
    Cue points are events, no matter how you handle them. There
    are three
    basic categeories of object functionality: properties
    (characteristics),
    methods (things the object can do), and events (things the
    object can react
    to). An "end" cuepoint is something your video object reacts
    to, so it's an
    event. How you *handle* (that is, manage) this event depends
    on how the
    object was written. Some objects, such as Button, TextField,
    and MovieClip
    instances require event handlers. Some require event
    listeners.
    I blogged on this just the other day, so for what it's
    worth, take a
    look here ...
    http://www.quip.net/blog/2006/flash/event-handlers-listeners
    Hope that helps.
    David
    stiller (at) quip (dot) net
    Dev essays:
    http://www.quip.net/blog/
    "Luck is the residue of good design."

  • Video Cue Point problem

    I have an FLV loaded into a video player component. The FLV
    has embedded cue points, from Flash video encoder:
    <mx:VideoDisplay id="vidScreen"
    cuePoint="cpHandler(event)" />
    And the handler:
    private function cpHandler(event:CuePointEvent):void {
    Alert.show(event.cuePointName);
    It works, since the Alert boxes open on cue and show the name
    of the cue point. However, if I try to get the array of cue points
    with something like trace(vidScreen.cuePoints) I get null. I need
    to get the array, since I want to do something on each of the items
    in the array of cue points. What am I missing here?

    You don't even need a cuepoint to do this.
    Using the FLVComponent or the VideoPlayer object, use the
    "complete" event to execute code. You set up an event listener
    object to listen to the video object (using
    videoobject.addEventListener(listenerObject) ), and create a
    function for the listener object to do when the "complete" event
    occurs (such as listenerObject.complete = function() { do whatever
    Here's a link to a useful pdf about the VideoPlayer object.
    http://download.macromedia.com/pub/documentation/en/flash/fl8/VideoPlayer.pdf

  • Need help with embedded cue points in FLV please (quickly/ :-))

    Here is my scenario - I have a flv streaming in a swf. All I
    want to do is to is call the cuepoint (event) in the flv, so that
    it will go to and play somewhere else further down the timeline of
    the swf - I don't think it should require much AS, but I haven't
    done much communication of this sort between an flv and it's parent
    swf. Any help would be greatly appreciated! Thanks.

    I figured it out. If anyone is interested, this the code snippet I found in Adobes help that allows you to access cue points and trigger events on flv's brought in with netstream:
    function onCuePoint(infoObject:Object):void
    trace("onCuePoint:");
    for (var propName:String in infoObject) {
    if (propName != "Run")
    RunCuePoint.visible=true
    else
    trace("parameters =");
    if (infoObject.parameters != undefined) {
    for (var paramName:String in infoObject.parameters)
    trace(" " + paramName + ": " + infoObject.parameters[paramName]);

  • Populating a ComboBox with names of all Cue Points

    I'm working with Flash CS4 and ActionScript 3.  I have a .flv file with about 30 cue points created in Soundbooth.  When I run my video my listener  picks up the cue points as expected.  What I am trying to do now is populate a combobox with a list of all the cue points in the .flv file.  Seems like it should be a super easy task to access an array of all the cue points in the .flv - but so far no luck.
    I am using FLVPlayback to run my video.
    Appreciate any advice as to how to access a list of all cue points.  Thanks.

    Got it!
    For anyone else looking, here it is:
    // this assumes you have a copy of FLVPlayBack downloaded to and instanced as my_FLVPlybk
    import fl.video.*;
    my_FLVPlybk.addEventListener(MetadataEvent.METADATA_RECEIVED,
        handleMetadata);
    function handleMetadata(e:MetadataEvent):void {
        var data:Object = e.info;
        recurseTrace(data, "");
    function recurseTrace(info:Object, indent:String):void
            for (var i:* in info) {
                    if (typeof info[i] == "object") {
                           trace(indent + i + ":");
                           recurseTrace(info[i], indent + " ");
                   } else {
                           trace(indent + i + " : " + info[i]);

  • Stopping streaming video with cue points

    I've been searching for a solution to this problem for weeks now. All i want to do is make a video streaming in a video object to stop on a cue point, and play from abother when a button is pushed. It's relatively simple, right? Wrong. Over a hundred $s in how-to books and several hours wasted searching online later and I have nothing. I have checked and re-checked the cuepoints are correct (i made them in flash video encoder CS3) and tried just about everything as far as AS is concerned. Here is my latest attempt: (obmintro is the player instance name, i have the rtmp info in source under player parameters and it plays fine)
    import fl.video.MetadataEvent;
    obmintro.addEventListener(MetadataEvent.CUE_POINT, cp_listener);
    function cp_listener(eventObject:Object):void
    if (eventObject.object.name == "site_end");
      obmintro.pause();
    //i have also used stop, stop("obmintro"); and i don't even know what else.
    please tell me what i'm doing wrong and how it's really supposed to be done. i'm feeling very hopeless and blonde right now. help a girl out?

    you're welcome.
    for anyone else with a similar issue, using the info property of the MetadataEvent is the correct way to proceed.  (that event has no object property.)

  • How to insert cue point in flv with cloud applications

    Hello,
    I'm new in creative cloud.
    With my previous version of adobe suite, with adobe media encoder, it was possible to insert cue point.
    In Adobe media encoder CC 2014 it seems not to be possible.
    Could you help me?
    Thanks.

    Thank you again Dima!!!
    Now I've CS6 now but the only way that I see to have flv is: Creates (I'm translating from my language) => Flash, from menu file.
    I need to insert cue point ("navigation" like in Media Encore Cs5.5).
    But the only marker that I see in CS6 is named "Chapter" (translating form my language).
    If I create an flv file (like above) I obtain two different flv files (one for chapter).
    Is there a way to insert inside the flv file the "navigation" cue points?
    Thank you again Dima.

Maybe you are looking for

  • Mobility Radeon 7500 OpenGL issues

    Whenever I attempt to use anything involving openGL, my CPU usage hits 100%. Complex openGL programs will drop to a framerate of less than 10, and sometimes crash Xorg.  How can I fix this? General system info: lspci 00:00.0 Host bridge: Intel Corpor

  • Printing non-latin characters

    If I wanted to print unicode characters in JSP, for example, arabic or japanese, what's the best way to go through with this? I tired the <%@ page contentType="text/html; charset=Windows-1256" %>but it won't work I tried this: <meta http-equiv="Conte

  • Using variables in Page processing

    I want to use variables (items) in Page processing - process - reset pagination for page(s) (PageID,PageID,PageID) and Page processing - Branches - Branch to page / URL - URL Is this possible, and if so How Fred.

  • Wireless ssid change

    Previously had an ssid configure as follows; dot11 ssid MYSSID    vlan MYVLAN    authentication open     guest-mode interface Dot11Radio0  ssid MYSSID But I want to replace it with this; dot11 ssid MYSSID-NEW    vlan MYVLAN    authentication open   

  • Overdelivery tolerance with partial GRs

    Hi all, We have the following scenario in a  purchase order with the delivery tolerance indicator: Qty in th PO 1000, overdelivery tolerance 10%, so we can accept until 1100. We can do 2 partial GRs like Firts GR for 500 Second GR for 600 But if we d