3 Replies Latest reply on Jun 3, 2012 8:48 AM by leejk

    [SMP] [Flash Builder 4.6] Video not Working, Audio Working, ios5


      Greetings all,


      English is not my natural language so i'm sorry for any kind of mistakes i might do in this posts


      I have been struggling with this problem a week from now, i have searched this foruns and the web and i haven't found a solution yet, hope someone had the same problem as me and already found a solution to share.


      I'm developing a Flex Mobile Application to provide a list of live streaming channels and i have tried to achive the goal with OSMF through Strobe Media Playback component.


      It doesn't have to be with SMP, if someone has a solution with any kind of component that is working on ipad2 and iphone4 within ios5 i would be very thankfull. I also have tried a WebStageVideo in the past with html5 and was working well in iOS4 (that was my workaround), but when i updated to iOS5 this workaround isn't working now


      The issue with Strobe Media Playback is that I can see the video and hear the audio in Flash Simulator, all works very well in the simulator, but when i deploy to iPad2 and iPhone4, i can only hear the audio and there is no video, the screen is completly black. I have tried to change a few options in the parameters but still no luck so far.


      This is the environment that i am using :


      - Flash Builder 4.6

      - OSMF 2.0


      In the Flex Mobile Project that is created, i have changed the following options :


      - Removed "osmf.swc" from "Project Properties -> Flex Build Path -> Library Path -> Flex 4.6.0"

      - Added "osmf.swc" from OSMF-src download, to folder "libs" in Project Explorer

      - Added "assets.swc" to "Project Properties -> Flex Build Path -> Library Path -> Flex 4.6.0"

      - Added the following configuration in "Project Properties -> Flex Compiler" :  -define CONFIG::LOGGING false -define CONFIG::FLASH_10_1 true


      In myApp-app.xml :


      - Added the line : <renderMode>direct</renderMode>  


      I followed all the instructions in here :



      This is the code that i am using at the moment, taking the example above :


      Strobe Media Playback component - Mobile Example with Flash Builder 4.6


      <?xml version="1.0" encoding="utf-8"?>
      <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
        title="SMP Example">


         import mx.core.UIComponent;
         import mx.messaging.messages.ErrorMessage;
         import spark.components.Button;
         import spark.components.Group;
         import spark.transitions.CrossFadeViewTransition;
         public var $playerInstance:StrobeMediaPlayback;
         private var grp:Group = new Group();
         private var stream_url:String = new String();
         protected function init_stream(event:Event):void
          trace('----- init_stream ----------------------------------------------------------------');
           // UK ITV 3 HD (SD)
           stream_url = "rtmp://tv.tvsector.com/live/z120103.stream";
           _stage = systemManager.stage;
           _stage.align = StageAlign.TOP_LEFT;
           _parameters  =
             , controlBarMode:"docked"
             , controlBarAutoHide: true
             , autoPlay: true
             , playButtonOverlay:true
             , showVideoInfoOverlayOnStartUp: false
             , verbose: true
             , streamType:"live"
           var playerInstance:StrobeMediaPlayback = new StrobeMediaPlayback();
           playerInstance.initialize(_parameters, _stage, systemManager.loaderInfo, null);
           $playerInstance = playerInstance;
           var ui:UIComponent = new UIComponent();
           ui.addChild($playerInstance as DisplayObject);
           grp.percentWidth = 100;
           grp.percentHeight = 100;
          } catch (err01:ReferenceError) {
           trace ("Error when playing Streaming - ReferenceError : \n" + err01 + "\n");
          } catch (err02:Error) {
           trace ("Error when playing Streaming - Error : \n" + err02 + "\n");
          } catch (err03:ErrorMessage) {
           trace ("Error when playing Streaming - ErrorMessage: \n" + err03 + "\n");


         private var urlLoader:URLLoader;
         private var urlRequest:URLRequest;
         private var loader:Loader;
         private var _stage:Stage;
         private var _parameters:Object;
         /* static */
         private static const ALLOW_LOAD_BYTES_CODE_EXECUTION:String = "allowLoadBytesCodeExecution";
         protected function emptyCache():void
          if ($playerInstance.player.playing) {
           trace("video is playing we will try to pause and empty cache");
           this.destructionPolicy = "auto";
           trace("video paused and cache empty");
          } else {
           trace("video is not playing we will do nothing ...");




      Also tried with f4m streams and still got no video after the deployment in iPad2 and iPhone4, both with iOS5. What am i doing wrong ?


      Does anyone have a working example with any kind of component to play rtmp live video streams, or any kind of workaround, that really works in iOS5, deployed on on iPad2 and iPhone4 ?


      Many Thanks.