Skip to main content
Inspiring
April 21, 2009
Answered

Policy file on rtmp video and BitmapData.draw()

  • April 21, 2009
  • 1 reply
  • 9886 views

Hi,

I hope there is answer to my dilemma from server side stand point.

I have a video asset that is streamed from rtmp. Say, url is: rtmp://blah.domain.com/directory/anotherone/asset.flv

I need to invoke BitmapData.draw() on this asset.

There is crossdomain.xml file on http://blah.domain.com/crossdomain.xml that allows all the domains.

When is instantiate stream I write:

stream.checkPolicyFile  = true;

Also I load crossdomain from http://blah.domain.com/crossdomain.xml and rtmp://blah.domain.com/crossdomain.xml

I tried all the combination of the above.

In all the cases when I try BitmapData.draw() - I am getting:

cannot access rtmp://blah.domain.com/directory/anotherone/. No policy files granted access.
         at flash.display::BitmapData/draw()

So, does it mean that each final folder has to have it's own crossdomain.xml? Even though the root directory has one?

Also, it feels that requesting crossdomain.xml from rtmp would be odd.

Is there way around it?

Can anyone try to resolve my confusion please?

Thank you.

    This topic has been closed for replies.
    Correct answer

    Flash Player clients are permitted to access data from streams in the directories specified in the Server-side ActionScript Client.audioSampleAccess and Client.videoSampleAccess

    properties:

    http://help.adobe.com/en_US/FlashMediaServer/3.5_SS_ASD/WS5b3ccc516d4fbf351e63e3d11a11afc95e-7ec3.html#WS5b3ccc516d4fbf351e63e3d11a11afc95e-7fcb

    HTH,

    Jody

    1 reply

    Correct answer
    April 21, 2009

    Flash Player clients are permitted to access data from streams in the directories specified in the Server-side ActionScript Client.audioSampleAccess and Client.videoSampleAccess

    properties:

    http://help.adobe.com/en_US/FlashMediaServer/3.5_SS_ASD/WS5b3ccc516d4fbf351e63e3d11a11afc95e-7ec3.html#WS5b3ccc516d4fbf351e63e3d11a11afc95e-7fcb

    HTH,

    Jody

    Inspiring
    April 21, 2009

    Jody,

    Thank you very much for your reply.

    To make sure I am clear on it. If  videoSampleAccess is set correctly - there is no need for crossdomain.xml. Is this correct?

    In other words, when Flash loads policy on the stream - it actually is looking for videoSampleAccess settings - not xml. Again, is my take correct?

    Thank you very much again.

    Andrei

    April 21, 2009

    Yes, that is correct!

    Jody