currently Iam Working on my Testapp Flash air 3.7 IOS IPAD.
MY app loads videos in h264 (mp4), it works fine in desktop but when I publish to my iPad or in Ipad Simulator the video is not visible. I habe packed the video files in IOS.
This is my function:
Please Help MAny Thanks
public function main()
{
stage.addEventListener(StageVideoAvailabilityEvent.STAGE_VIDEO_AVAILABILITY, onAvail);
}
private function onAvail(e:StageVideoAvailabilityEvent):void
{
stageVideoAvail = (e.availability == StageVideoAvailability.AVAILABLE);
initVideo();
}
private function initVideo():void
{
var nc:NetConnection = new NetConnection();
nc.connect(null);
var ns:NetStream = new NetStream(nc);
ns.client = this;
if(stageVideoAvail)
{
sv = stage.stageVideos[0];
sv.addEventListener(StageVideoEvent.RENDER_STATE, onRender);
sv.attachNetStream(ns);
trace('available');
}
else
{
var vid:Video = new Video(1371, 771);
addChild(vid);
vid.attachNetStream(ns);
trace('not');
}
ns.play('cam9.mp4');
}
private function onRender(e:StageVideoEvent):void
{
sv.viewPort = new Rectangle(0, 0, 1371, 771);
}