Interactive flash content on iOS - ios

I want to play interactive (user inputs/actions) flash contents-videos on the iOS devices. I am having flv files in which user can have their inputs like option selection, page turn etc.
I am having 2 approach about the functionality. Please correct if I am wrong.
1.Adobe-air can be used on the iPad devices. Does it have the ability to parse flash content run time? (use flash content as resources/bundle)
2.With the help of FFMPEG lib flash files/videos will work, but will it provide user actions/interactions?

No to both. Adobe Air can only be used to create applications. You can't actually play flash files using it. FFMPEG will only play flash videos, it will not allow interaction.
Basically, if you have flash interactive content that you want to display on the iPhone you are going to have to think of a different way to present it.

Since air 3.8 it got much more easier to run swf content from ios - but it is a pain if your content is external yes...
Also I was able to play dynamic video using starling and flv in the background at 12fps on ipod and 24fps on iphones and ipads.
The key there is how you upload the bitmapData to the GPU:
flash.display3D.textures.Texture(videoLayer.texture.base).uploadFromBitmapData(bitmapData);
Where videoLayer is a Starling Image and bitmapData is a drawn bitmapData from the video.
The rest of the code is trivial stuff that you can find easily online, but the Texture.uploadFromBitmapData is what really made a performance difference.
See it in action in the app store: https://itunes.apple.com/app/id723967141?mt=8

Related

Any way to enable user interaction while viewing fullscreen video in iOS browsers?

My research tells me that there is now way to escape fullscreen video viewing in iOS browsers on iPhone or iTouch. It also seems there there is no way to modify the native controls that are displayed along with the video. Is the user in a total blackbox while viewing video in this case?
I'm trying to find someway for a user to indicate that they like a video as it is playing. Is there anything I can do that isn't a hack? If not is there any indication from Apple that they will ever be willing to change this? I'd rather not make an app out of this project.
You actually can play a video in line on an iOS browser, if this is what you are aiming for although there are restrictions - updated answer:
Play video inline in a browser on iOS
Safari on large screen iOS (iPad) should support inline video (I don't have iPAD hand to verify this still works...).
Safari on 'small screen' iOS (i.e. iPhone) will not support inline video as standard. There is at least one workaround which will allow it but this does bypass much of the native video playback performance gains so it may not meet your needs. It is a work in progress still as you will see from the link, but try the demo on an iPhone browser - you need to hit the small play button beside the video, rather than the one on top of the video at the time of writing:
https://github.com/newshorts/InlineVideo
Playing inline in a UIWebView on iOS
Take a look at this Apple Developer page:
https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIWebView_Class/index.html#//apple_ref/doc/uid/TP40006950-CH3-SW31
In particular:
allowsInlineMediaPlayback
A Boolean value that determines whether HTML5 videos play inline or use the native full-screen controller.
and:
Discussion
The default value on iPhone is NO.
In order for video to play inline, not only does this property need to be set on the view, but the video element in the HTML document must also include the webkit-playsinline attribute.

blackberry OS 10 development to share screen

Is it possible to create an application for BBOS10 that shares screen to other phone/PC on wifi network just like Radmin on Windows?
I presume you are talking about sharing the screen regardless of content, rather than sharing the screen for a specific application that you have written.
I am not aware of any "API"s for doing this.
This leaves, I believe two options, which are loosely:
capture screen shots and forward these
capture a video of the screen and forward that
Now the screen shot API has been available since fairly early on in BB10 evolution. To use it you would just create a background Thread and take screen shots at regular intervals, which you would then send, presumably over a socket interface, to the receiving user. I suspect The biggest issue with this is that it is likely to be extremely data heavy, since the screen shots are complete images, as opposed to a streaming video which is (in my understanding) typically a series of diffs from the preceding frame.
Until very recently, it has not been possible to capture video of the BB screen, but it seems with 10.2, you now can. Please review this Thread:
Capture Video
on the BB10 forum.
Looking at this, it would appear you can capture each video frame and forward that, or presumably, capture the entire stream and forward that.

autoplay html5 video with external link on mobiles

I have created a web page that auto plays a full screen background video.
On top of the video is a div that contains text & a link to an external site - this works fine in all desktop browsers.
How do i recreate the same setup to play on mobile devices - would I need to use javascript in order to achieve this?
I have spent many hours trawling google for a definitive answer and am now very confused.
Thanks in advance.
Autoplay for HTML5 video is not allowed on mobile devices such as iOS or Android. You can read this for the whys and hows on iOS.
On iPhone the video plays in the default (fullscreen) Quicktime player. So there is no real background notion (this could be accomplished in a native app where inline playback of video is allowed but not in the Safari/web browser). You would need to stick to an image I guess.
On the iPad or on Android in order to accomplish what you want you will need to bind your video tag to a touch event/button (like when a user 'touch' to enter your site), and on this event initiate the play sequence for the video (in your case the video being set to occupy the full width and height of the viewport).
Thanks

NetStream http Video not playing on IOS device

I am trying to play a video on iPad, my code is below :
public function init_RTMP():void
{
videoURL = "http://rest************_iphone_high.mp4";
vid = new Video();
nc = new NetConnection();
nc.addEventListener(NetStatusEvent.NET_STATUS, onConnectionStatus);
nc.connect(null);
}
private function onConnectionStatus(e:NetStatusEvent):void
{
if (e.info.code == "NetConnection.Connect.Success")
{
trace("Creating NetStream");
netStreamObj = new NetStream(nc);
metaListener = new Object();
metaListener.onMetaData = received_Meta;
netStreamObj.client = metaListener;
netStreamObj.play(videoURL);
vid.attachNetStream(netStreamObj);
addChild(vid);
}
}
when i play it on my system it is working fine, but when i create a IOS app of it and installs on device, it shows white blank screen.
If anyone have same problem or any idea please share with me.
As VC.One pointed out, AIR for iOS does not play most (but not all, it will occasionally play a very specific encode type) h.264 encoded videos. There are three solutions:
As VC.One said, you encode as FLV. Doing this is not good and I would not recommend it. FLV is not hardware accelerated (unless things have changed recently and I have not seen the updates) and will run entirely off the CPU meaning your app will run slowly and the app will eat battery much quicker than normal.
Use StageWebView, in which case you just plug in the URL to the video and it will play the video using the native video player. This has the down side in that you cannot skint he player and you cannot control it. Once it begins playing, you have no control over it except for unloading the page. This works very well, however, and is fairly easy to implement, though the video will appear on top of the stage (it is not in the Display List).
The last option is to use StageVideo. This will play videos using the native framework, so you can easily play h.264 and it will be hardware accelerated. Additionally, this is just a NetStream player so you have full control over it. And best yet, it has no chrome so you can build a player around the video screen. However, like StageWebView, StageVideo is not in the Display List. But unlike StageWebView, it is rendered directly on the stage, below everything else. So the app itself will cover the video. You can get around this by creating a class to mask your app around the video, but it is incredibly difficult to properly pull off. It took me about 12 hours to create my StageVideo player and the masking class, plus another half day later on fixing issues with the masking class and how it handles DPI changes (hint: do NOT set applicationDPI if you are using Flex)
As always, make sure your AIR SDK is up to date as well. 3.5-3.7 have all added a ton of new features and bug fixes for iOS applications so updating to AIR 3.7 might actually solve or make your issue less of a problem (I don't think it will, but it is always worth a shot, right?)
See this link:
Netstream video not playing on iPad
Basically it was fixed by encoding the video file as FLV not MP4.

How do I make my HTML5 video player autoplay on iPad, like filmon.com?

I'm trying to create an HTML5 video player to automatically start streaming video. I searched a lot but I didn't achieve my goal.
Then I found www.filmon.com, where all videos start to play automatically on iPad.
Does anyone know how they did it? I looked at their JS files, but I cannot make mine start automatically.
Apple has specifically disabled every method and workaround to autoplay video on iPads and iPhones (the "autoplay" attribute, and Javascript solutions like triggering hidden link's "onclick" event).
I have yet to find a way to autoplay on iPads and it looks like Apple is continuing to squash all efforts to do it. They state, "In Safari on iPhone OS (for all devices, including iPad), where the user may be on a cellular network and be charged per data unit, autobuffering and autoplay are disabled. No data is loaded until the user initiates it."
As a quick update I just checked out Filmon.com and the videos there no longer seem to be autoplaying on an iPad. Example: http://demand.filmon.com/distant-roads-173-cnd-ontario-ca-1 autoplays on Chrome, but not on the iPad.
I don't think that iphone or ipad play streams automatically due to high traffic.
Why don't you play it manually using script at document ready?
somewhat like this:
window.onload=function(){
var audio = document.getElementById('audio');
audio.play();
}

Resources