SecurityError: Error #2123: Security sandbox violation: BitmapData.draw


i know has been discussed few times , seems working no matter try unable overcome error.  in nutshell trying capture video frames , draw them bitmap using osmf (f4m's specifically).  have looked on , tried suggestions these discussions:

 

http://forums.adobe.com/message/3759490#3759490

http://forums.adobe.com/message/3744741#3744741

http://forums.adobe.com/message/3254112#3254112

 

what trying follows.

 

i created crossdomain.xml root (all testing on local web server), crossdomain looks this:

 

<?xml version="1.0"?>

<!-- http://www.foo.com/crossdomain.xml -->

<!doctype cross-domain-policy system "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">

<cross-domain-policy>

  <allow-access-from domain="*"/>

          <site-control permitted-cross-domain-policies="all"/>

  <allow-http-request-headers-from domain="*" headers="*"/>

</cross-domain-policy>

 

my load routine this:

 

_player = new mediaplayersprite();

addchild(_player);

security.loadpolicyfile(url.root + "/crossdomain.xml");

_player.resource = new urlresource(url.tostring());

_player.mediaplayer.addeventlistener(mediaplayerstatechangeevent.media_player_state_change , onplayerstatechange, false, 0, true);

 

then suggested in other discussions, don't try copy bitmap until playing state event in onplayerstatechange handler.  in handler set flag says ok copy bitmap , in onframeenter handler if flag set attempt copy bitmap.

 

i not sure quite else try next.  have monitored traffic test page , can see crossdomain.xml gets loaded, video loads , can hear until can fix of course can not see it.

 

i not sure if matters displayobject holds code never gets added stage.  because exposes bitmap property other objects can access when want , use video data.  mention because maybe security model not completed until gets added stage? 

 

any appreciated.  thanks!

i still stuck on this.. condition occurs seems when netstream.appendbytes being used, checkpolicyfile has no effect.  oversight adobe or there way work around this?


thanks.



More discussions in Developers


adobe

Comments

Popular posts from this blog

Warning, the Safe Path is not accessible vm3 - Joomla! Forum - community, help and support

uppercase letters in url - Joomla! Forum - community, help and support

Joomla! Update is not offering Joomla 3 - Joomla! Forum - community, help and support