Bitmapdata question

I think this should be a fairly simple question for someone. I just finally got Flash 8 a few weeks ago (haha ya I know… about time). Anyway I was trying to play around with the bitmapdata class and I ran into a problem…

When I load a .jpg image from my server (local) and use the bitmapdata to .draw and copy it to another movieclip it works great but when I do the same thing but load a .jpg from another domain… it doesn’t work. What am I missing here? It’s even with the same pic but it seems flash isn’t letting me use the bitmapdata class on pictures from external domains? It does how ever work when I run it from flash just not on my server…

Here is an example (using Ordinathorreur’s code posted on this forum):


//import BitmapData
import flash.display.BitmapData;
//stop movie so it doesn't repeat over and over
stop();
//load a pic into an mc on the stage
content_mc.loadMovie("flash.jpg", 1);
//create a function that runs every frame (only for this example, it keeps running and you won't want that
_root.onEnterFrame = function() {
	//this is the interesting bit, basically the next line is your preloader 100% action, the pic has to actually have been fully loaded before we can do this
	if (_root.content_mc.getBytesLoaded() == _root.content_mc.getBytesTotal()) {
		//create a variable to hold the bitmapdata info
		myBitmapData = new flash.display.BitmapData(content_mc._width, content_mc._height, true, 0x00FFFFFF);
		//copy the bitmap into the bitmapdata variable we just created
		myBitmapData.draw(_root.content_mc);
		//now attach it to a different mc for the sake of example
		_root.content_mc2.attachBitmap(myBitmapData, 1, "auto", true);
		//rotate both movieclips so you can see the difference
		_root.content_mc._rotation = 30;
		_root.content_mc2._rotation = 30;
	}
};

now if you replace this line:

content_mc.loadMovie("flash.jpg", 1);

with:

content_mc.loadMovie("http://img68.imageshack.us/img68/6227/sig057rp.jpg", 1);

It will work when I run it in flash… but not when I upload it to my server. It does of course load the .jpg in the first movieclip just doesn’t seen to wanta be used with the bitmapdata class at all…again, this is only with .jpg’s from another domain. What am I missing here?

:ne:

I have never bumped a thread so please forgive me:hitman: . This is really got me puzzled as to why the bitmapdata would care if the loaded picture was from a local or external website becuase both load fine!!

Someone has gotta know. Scotty, Sen? What am i doing wrong?

Thanks!