2 Replies Latest reply on Apr 14, 2010 9:30 AM by punknrollDD

    add native Video Object to osmf

    punknrollDD

      Hi, for some strange reasons I had to construct a native video, netconnection and nestream object. Can I add this native Video object to my mediaPlayer.media because my whole player is based on osmf and i don't want to rewrite everything without osmf.

       

      thanx.

        • 1. Re: add native Video Object to osmf
          bringrags Level 4

          To pass in your own NetStream, you'd need to define a custom NetLoader subclass that overrides the createNetStream method, and use that object as a parameter to VideoElement.

           

          To pass in your own NetConnection, you'd need to create a custom NetConnectionFactoryBase subclass that returns your NetConnection in an event when the create() method is invoked, and use that object as a parameter to your NetLoader.

           

          There's no "official" way to pass in your own Video.  However there's an undocumented (protected) createVideo method on VideoElement, which you could override to return your own Video object.  (Note that any undocumented API is subject to change, so you should try to avoid relying on them.)

          • 2. Re: add native Video Object to osmf
            punknrollDD Level 1

            Thanx Brian,

             

            your solution sound pretty complicated. I already subclassed the NetLoader Class to make the call to the FMS successfully, but now the next problem occurs. The stream stutters and hangs when the fms changes a video in the stream. I hope this can be solved too then i won't need pass my own Video object to the fms

             

            http://forums.adobe.com/message/2735481#2735481

             

            Thanks