Quantcast
Channel: Adobe Community : Unanswered Discussions - AIR Development
Viewing all articles
Browse latest Browse all 2010

Air, native process, bitmapData & sandbox

$
0
0

Hello !

 

First of all, sorry if my english is not perfect.

 

I'm doing some test with Air NativeProcess. I created an app connected to FFMPEG to read all video Format, as shown in this video tutorial

http://www.youtube.com/watch?v=6N7eN9wvAGQ

 

All works perfectly, but if I try to draw my video Object inside a BitmapData, I get the famous "Sandbox security error".

The thing I really don't understand is that all my files are local (the air app, ffmpeg and the video file).

 

I tryed to add a basic crossdomain.xml that allows all domains, but it didn't change anything.

I tryed to use 'Security.loadPolicyFile', but it didn't work

I tryed to use 'NetStream.checkPolicyFile' but it didn't work

I tryed to set NetStream.videoSampleAccess to true, but it didn't work

 

I saw somewhere on the internet that a solution exist for this problem with a RTMP connexion. the netstream need to send a command that solve the problem :

netStream.send("|RtmpSampleAccess", true, true);

 

But I am in local and it didn't work (I tryed it with a delay, without a delay, at all frames, but it didn't work...)

 

 

The weird thing is that it work very well if I use FFMPEG to create an image (not a video !) and get it with Loader.loadBytes.

In that case, I get the bitmapData successfully without any error.

 

This is great but I 'm still looking for 'the true' solution of this security problem, because it doesn't have any sense that it work with image but not with video ...

 

 

You can grab the file here (this is a flashDevelop project) : http://beginfill.com/ffmpeg/

(You need to add a file called 'test.avi' in the 'bin' folder ; it use the windows version of ffmpeg, if you 're using Mac OS, you can get ffmpeg on the link below - put the file in the "bin" folder and change the url to the at the beginning of the code - )

http://ffmpegmac.net/

 

Thanks !


Viewing all articles
Browse latest Browse all 2010

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>