0 Replies Latest reply on Nov 20, 2012 11:51 AM by FactorThree

    Why doesn't Air Application properly display Video???

    FactorThree

      I have an Air Application that I created using Flash Builder 4.6 on Windows 7. It uses a VideoDisplay to show a video.

       

      The code for this is fairly basic:

       

      <?xml version="1.0" encoding="utf-8"?>

      <s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"

                             xmlns:s="library://ns.adobe.com/flex/spark"

                             xmlns:mx="library://ns.adobe.com/flex/mx">

           <fx:Declarations>

                <!-- Place non-visual elements (e.g., services, value objects) here -->

           </fx:Declarations>

           <s:VideoDisplay id="vidBox" autoPlay="true" x="6" y="11" width="95%" height="90%" scaleMode="zoom">

                <s:source>

                     <s:DynamicStreamingVideoSource host="rtmp://localhost/Player" streamType="recorded">

                          <s:DynamicStreamingVideoItem streamName="my_video.flv" />

                     </s:DynamicStreamingVideoSource>

                </s:source>

           </s:VideoDisplay>

      </s:WindowedApplication>

       

      All this is supposed to do is put up a video display and play my_video. The my_video.flv file is a 1- hour video.

       

      When this code is run, I do not see the video, but I see a lot of flashing colors and shapes. But then, I have another, browser- based application that is also pretty basic:

       

      <?xml version="1.0" encoding="utf-8"?>

      <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"

                      xmlns:s="library://ns.adobe.com/flex/spark"

                      width="100%" height="100%">

          <mx:Style source="PlayerClient.css"/>

          <s:VideoDisplay id="vidBox" autoPlay="true" x="6" y="11" width="95%" height="90%" scaleMode="zoom">

             <s:source>

                <s:DynamicStreamingVideoSource host="rtmp://localhost/Player" streamType="recorded">

                     <s:DynamicStreamingVideoItem streamName="my_video.flv" />

                </s:DynamicStreamingVideoSource>

             </s:source>

          </s:VideoDisplay>

      </mx:Application>

       

      This code uses the same VideoDisplay and the same my_video.flv file, but when this application runs it displays the video without problems. I get full sound and video when I run this application, but when I run the Air application I get scrambled gobbldegook.

       

      Has anyone seen this problem before??? Does anyone have any idea why the Air application is screwing up the video? Does anyone have any idea how to fix this and make the Air application display the video properly?

       

      Any help and/or insights would be GREATLY appreciated...