As3 I need to play mp4 video! I use FileReference (ByteArray)

This code do not work:
data - ByteArray
var nc:NetConnection;
                              var ns:NetStream;
ns.appendBytes(data);
nc=new NetConnection();
                                        nc.connect(null);
                                        ns=new NetStream(nc);
                                        var video:Video = new Video();
                                        video.attachNetStream(ns);
                                        ns.play(null);    
addChild(video);
Help me!

1. appendBytes understands FLV only by default.
2. In order to play mp4 (or any other than FLV format) you need to use appendBytesAction(NetStreamAppendBytesAction.RESET_BEGIN) so that Flash reads file correctly. This is quite a flaky proposition anyway.
3. appendBytes must be called after play(null) is called. Otherwise Flash throw an error.
Correct sequence:
     ns.play(null);
     ns.appendBytes(ba);
Incorrect sequence:
     ns.appendBytes(ba);
     ns.play(null);

Similar Messages

  • What code is needed to play mp4 video in IE9

    I have been everywhere looking for a solution to this. I only get references which talk about what the problems, the issues, and what needs to be done but does not provide the actual html code that should be inserted into DW that will actually make it work in IE9.
    I place .mp4, .ogv, .webm code that works in Chrome, Apple, Android, and Firefox browsers but NOT IE9. Can anyone help with this? It has been a very frustrating experience.
    Thanks!
    Jan

    Hi Hans,
    I try and am happy to acknowledge the help.
    I am an interactive course developer who has worked with Flash for over 12 years. It has been super for both the desktop and the web for my clients. I was able to produce one set of data that worked in all environments. Now that the Flash player in browsers is going away I must recreate the courses in html5. I have been using multi media since the beginning and now I find so many roadblocks for even the simple things that Flash handled automatically. Video is a prime example.
    Unfortunately all of the courses I have developed for the customers are proprietary to their internal workforce and I am unable by contract to share any. Sorry!
    In the example you provided, the video pops up in a separate player floating off the main page. Is it possible to embed the video in the page like the other formats I must use such as webm and ogv?
    Jan

  • I need to create an APP that runs on an Android Tablet to play mp4 video stored on the SDCARD.  I ha

    I need to create an APP that runs on an Android Tablet to play mp4 video stored on the SDCARD.  I have tried using VideoPlayer and passing NULL to the Connect() method, but while this will play a video from a shockwave SWF it will not play it as an APP from a .apk file.

    There are several apps in the App Store. Look at them to see what might meet your needs. There is a keynote app that might be best for you.

  • How to embed and play mp4 video in HTML AIR application?

    Adobe Air HTML / JS application compiled from SDK command line.  I am not using flash pro or flash builder to create the application.
    I was using dreamweaver but the dw air plugin seems to have stopped being developed so I switched to using the command line tools.
    I am creating desktop air application that has embedded mp3 audio and also I want to embed mp4 video.
    Using jQuery and the AIR js plugin I am able to play audio via buttons hooked up via jQuery and the AIR js plugin from the SDK.
    What I am doing is creating proofs for clients in AIR and sending link to the client to download the application.  I embed the media because I do not want to place them on a website where it could possibly be seen by non-clients and get picked up in the SE's.
    I am finding it hard to understand the AIR process for playing video.  I read that it is the same procedure as audio but it does not work.
    If it was hosted on youtube or somewhere embedding the web player would be simple, just copy paste some code and it works.  When actually embedding the video say mp4, f4v, mov, wmv or similar file formats I can't get AIR to play the video.  Audio, not a problem it works great.
    I would like to do the following with video.
    Embed the actual file in the AIR app.  I can do this, it gets embedded.
    Play, pause and stop the video - Can't get this to work
    Get the current stop point and be able to start the video by sending a start point - This is all working with audio I just want to do it with video.
    I have searched the forums, the search engines, youtube and read through the documentation on Air but the video does not work at all.
    I need code samples and direction on how to make an embedded video play inside of a desktop air application using the HTML / JS air model. I am using the command line tools to create the air package and test the air app.
    Please help if you have figured this out.
    Thank you.
    Not sure if this matters but I am using Windows 7 Pro 64bit as my development machine.

    In addition I also can not get html5 video to play in the adobe air app.  Would this issue be tied to the above?

  • Safari is not playing mp4 videos in iPad 2 (iOS 7.0.4)

    Dear All,
    I am trying to play mp4 videos on Safari in iPad 2 (iOS 7.0.4). The video files are uploaded in AWS. Everything works fine with iPad Chrome Browser. My problem is the videos are not playing on Safari in iPad 2 (iOS 7.0.4). The same videos are uploaded in localhost are playing fine on Safari in iPad 2 (iOS 7.0.4).
    Let me know the solution if some one knows.
    Thanks,
    Muruganandhan K

    Hello, Setya Widya. 
    Thank you for visiting Apple Support Communities. 
    Since you are experiencing multiple issues with Apps that require internet, this sounds like you may have an issue with your Wi-Fi connection.  Try going through the steps in the first article. 
    iOS: Troubleshooting Wi-Fi networks and connections
    http://support.apple.com/kb/TS1398
    I would also attempt to update the device using iTunes on your computer and test accessing these applications after the update. 
    Update your iPhone, iPad, or iPod touch
    http://support.apple.com/kb/ht4623
    Cheers,
    Jason H. 

  • How to play MP4 videos from library assets, not external source

    I can play MP4 video files all day long, as long as they are from an external source. How can I target via linkage MP4 video files in the library? I'm building a Kiosk application and can't have any external assets--only assets from the library. Please only post comments or solutions based on using the video object, not the Playback component. Thanks

    have been trying this too , the manual says FAT32 files, just my two cents for ya

  • Unable to sync my movies in the i tunes 11 library i try to add the mp4 video by using the add to library option but the movie does not sync while the music is syncing fine...

    i am unable to sync my movies in the i tunes 11 library i try to add the mp4 video by using the add to library option but the movie does not sync while the music is syncing fine...

    I had the same issue. What I did was save the movies on a thrid-party app like Download Manager Lite. Once downloaded, go back to itunes, go to your iDevice, go to apps and transfer the app, then scroll down and click on the app and from there you can send the movies to that app and WILL play. Can only hold up to 8 videos/movies (this is for iPod Touch 3G or better, iPhone 3s or better, iPad requires iOS 4.3 or better)
    YES THIS APP SUPPORTS .mp4
    From other ipod (nano, classic): I don't remember.
    If your just putting them on iTunes, it should show and play on iTunes no problem.
    Message was edited by: keeferaf

  • Converting Nokia N95 MP4 videos for use with Premiere Pro?

    What would you say the best way to convert Nokia N95 MP4 videos for use with Premiere Pro is?

    Sheesh.
    This "
    How do I convert my files?" entry at the PPro Wiki might offer some insight.

  • CorePlayer to play Flash video - anyone used it?

    Anyone know anything about this software?
    ApPARENtly it has been written expressly to decode flash video files more efficiently on older computers- any computers, really. There are versions of CorePlayer for pocket PC's, older versions of Windows, etc. but what really caught my eye is that there is a version just for PowerPC based Macs.
    As anyone in this forum will know, Adobe's current versions of Flash player are very badly optimized for PowerPC macs. Playing youtube videos (that used to show pretty smoothly) now takes 100% of CPU power while stuttering furiously, because, as I have read, the new decompression algorithms were not coded efficiently for our hardware. As a result we've been shut out of content that used to be accessible.
    Core Player costs $20 though, and there is no trial version. Plus there are no reviews of it on MacUpdate or Versiontracker. So I have no idea if it works. Anyone taken the plunge?
    edit I have a Ti book, which has more acute problems playing .flv files than the Al book.
    Message was edited by: andr nimm

    Currently there is no Flash support for Firefox on Android. Fret not though, there are mobile developers working on front-end Flash support currently and if all follows through you will see Flash support in the near future in a future release of Firefox Aurora.

  • Nokia Asha 205 Not playing Mp4 Videos

    I was using Nokia x2-01 before. Recently i purchased a Nokia Asha 205. I have tried to play all the video files but discovered that those in mp4 format only plays the audio part of the file and writes VIDEO NOT SUPPORTED on the screen. What can i do?

    You need to convert the videos to phone supported mp4, 240*320 resolution using format factory pc software and copy the videos to your phone.
    Hope this helps.
    -------------------If this post helped you, click on accept as solution.------------------
    -----------------------------Appreciate by clicking on white star.----------------------------

  • Version 10,0,32,18 fails to play MP4 video 10,0,22,87 does

    Does not work to play MP4 on websites
    example www.30atelevision.com
    version 10,0,32,18 installed -- this in on my computer
    It appears in fact that the file TIMELINE plays, but does not deliver video or audio.
    Works
    version 10,0,22,87 installed -- This will play MP4 as does Flash player 9.
    having Air installed appears to worsen situation
    Yet again ADOBE releases a product that is not backward compatible.
    Post solutions to help address this issue

    We are having the same issue
    We are using basic MP4 with H.264 codec as well
    www.30atelevision.com is where our player is
    all fine til the latest update.
    Adobe claims its not Flash Player. We are not convinced, as we have checked numerous files, reencoded and so on.
    I dont think they fully tested to confirm our suspicions. If we find a cure or have further information we will post it
    We do thank Adocbe for at least responding. Further checking is needed for this suspected bug

  • Playing MP4 videos on 4400 dmp

    Hi, it looks like MP4 is a supported file type -- at least in the media library on the DMM.  But, the videos do not play, all I get is a blank screen.  any suggestions?
    Rose Ann

    Hi Rose,
    Please review the "Table 2. Cisco Digital Media Player 4400G Product Specifications" in the DMP 4400G Data Sheet:
    http://www.cisco.com/en/US/prod/collateral/video/ps9339/ps7220/data_sheet_c78-480272.html
    You can't tell if the video will be supported just by its file extention. You need to check its video container, video codec, audio codec, etc.
    You may use Media Info (http://mediainfo.sourceforge.net) to check the details on your video file.
    I hope it helps.
    Fabio Bergamo
    Cisco TAC

  • Possible to play mp4 video uploaded to CC storage from my ipad?

    Uploaded mp4 video to my cloud storage for a client to review on ipad. Can't seem to play the video or download it though the ipad. Any ideas?

    I don't know which one to suggest, but I think you need a program forum for whatever Adobe apps you have on your ipad... maybe the digital editions forum or the touch apps forum?
    The Cloud forum is not about using individual programs
    The Cloud forum is about the Cloud as a delivery & install process
    If you will start at the Forums Index https://forums.adobe.com/welcome
    You will be able to select a forum for the specific Adobe product(s) you use
    Click the "down arrow" symbol on the right (where it says All communities) to open the drop down list and scroll

  • Play mp4 videos on ipad2

    I could not get to play videos on ipad2 using netstream and stagevideo. Which video control should I use to play videos on ipad?

    This is going to be difficult depending on a few questions.
    Where are the mP4 video stored? On computer, digital camera, or digital video camera, etc.?
    The easiest way:
    If they are on a digital camera or digital video camera, you may have to purchase Apple's camera connection kit.
    You maybe able to transfer the video from the respective camera source by plugging in the camera connector into the iPad, the plug your camera's USB cable into the camera connector. You need to initiate the camera's transfer mode to transfer the pictures and videos from the camera to the iPad.
    The videos maybe found in the Photos app rather than the Video app on the iPad.
    If this didn't work for the videos, then there is another procedure for getting videos onto the iPad, but it is a little more complicated to do and explain.
    Try this direction, first.
    If no joy, then the next method, be it more complicated, is the only other way to transfer video to the iPad.

  • Quicktime 7.7.4 will not play mp4 video

    I have several recorded videos saved in mp4 format that will not open in Quicktime. The audio plays, but the video is only a black screen. I have one mp4 file that I recorded a few days before the others that will open in Quicktime. All the files open in VLC, DivX, Adobe Premiere Pro 5.5, and Windows Media Player. I am using Windows 7 and I need to import these videos into Photoshop CS5.5 extended which it will not do if the files won't play in Quicktime. I've tried just about everything including re-recording, but my recording will only save in mp4 or flv. I have also uninstalled and re-installed quicktime, photoshop, and my recording device.
    The first two images are from files that will not play in Quicktime, no picture only sound. That last image is from a file which will play; both sound and picture.

    I have several recorded videos saved in mp4 format that will not open in Quicktime. The audio plays, but the video is only a black screen. I have one mp4 file that I recorded a few days before the others that will open in Quicktime. All the files open in VLC, DivX, Adobe Premiere Pro 5.5, and Windows Media Player. I am using Windows 7 and I need to import these videos into Photoshop CS5.5 extended which it will not do if the files won't play in Quicktime. I've tried just about everything including re-recording, but my recording will only save in mp4 or flv. I have also uninstalled and re-installed quicktime, photoshop, and my recording device.
    The first two images are from files that will not play in Quicktime, no picture only sound. That last image is from a file which will play; both sound and picture.
    Your video data rates are virtually nonexistent. (I.e., a "normal" quality AAC stereo track for a video file is typically recorded with a sampling rate in the 44.1 KHz at 128 Kbps to 48 KHz at 160 Kbps range.) As you can see in the inspector images the total audio plus video data rate allocated for your files are all little more than that required to support a "normal" stereo audio track. Recompress the files using a more realistic video data rate. Try something in 1.25 Mbps to 2.50 Mbps range as a starting point and determine the minimum level of quality you can live with here. (I.e., a typical VGA SD iPod file is normally compressed with a video data rate on the order of 1.5 Mbps to 1.7 Mbps.)

Maybe you are looking for