To register for an Internet.com membership to receive newsletters and white papers, use the Register button ABOVE.
To participate in the message forums BELOW, click here


A Flash Developer Resource Site

Go Back   Flash Kit Community Forums > Flash Help > Flash ActionScript

Reply
 
Thread Tools Search this Thread Display Modes
Old 08-07-2007, 06:03 PM   #1
gartmann
Dogs Die In Hot Cars
 
Join Date: Jun 2003
Location: Sheboygan, WI
Posts: 109
Quick: Can a jpeg be moved out of one MC to another one?

I load a .jpeg into a movieClip and the mask runs. I need to beable to move the .jpeg to a seperate movieClip so I can load a new .jpeg into the original movieClip and run the mask again.

Can this be done?
__________________
The Dude Abides
gartmann is offline   Reply With Quote
Old 08-07-2007, 06:29 PM   #2
mneil
I want my 2 dollars
 
mneil's Avatar
 
Join Date: Mar 2007
Location: Bakersfield
Posts: 2,044
I'm sure there is a better way to do what you're asking than trying to move a bitmap around from one mc to the other. Explain what exactly you're wanting to accomplish and maybe we can find a better way.
__________________
http://www.mneilsworld.com/
Text Effects | Bubbles | Dynamic Resize
4 weeks , 20 papers ... thats 2 dollars .....Caassshhh!
mneil is offline   Reply With Quote
Old 08-07-2007, 06:36 PM   #3
gartmann
Dogs Die In Hot Cars
 
Join Date: Jun 2003
Location: Sheboygan, WI
Posts: 109
I have a multiple .jpegs loading into a MC one after another with a time delay and an entry masking transition. I need to move the .jpeg to a lower MC so it doesnt disaper when the next image transitions in.
__________________
The Dude Abides
gartmann is offline   Reply With Quote
Old 08-07-2007, 06:39 PM   #4
mneil
I want my 2 dollars
 
mneil's Avatar
 
Join Date: Mar 2007
Location: Bakersfield
Posts: 2,044
Instead of loading the all jpg into the same mc and fading you need to load each jpg into a separate mc and apply the transition. Just load one below the other and fade(or whatever the transition) out on top. When you get to the end use swapDepths or some other means of getting them on top of each other again and do your process again.
__________________
http://www.mneilsworld.com/
Text Effects | Bubbles | Dynamic Resize
4 weeks , 20 papers ... thats 2 dollars .....Caassshhh!
mneil is offline   Reply With Quote
Old 08-07-2007, 06:56 PM   #5
gartmann
Dogs Die In Hot Cars
 
Join Date: Jun 2003
Location: Sheboygan, WI
Posts: 109
Then I guess my question would have to be: how do I actionscript a mask to work on a specific movieClip.

ie. mask_MC.mask("container"+k);
__________________
The Dude Abides
gartmann is offline   Reply With Quote
Old 08-07-2007, 07:08 PM   #6
mneil
I want my 2 dollars
 
mneil's Avatar
 
Join Date: Mar 2007
Location: Bakersfield
Posts: 2,044
look into setMask. Make a movie clip to be used as the mask and then use

isMaskMc.setMask("maskedMc");
__________________
http://www.mneilsworld.com/
Text Effects | Bubbles | Dynamic Resize
4 weeks , 20 papers ... thats 2 dollars .....Caassshhh!
mneil is offline   Reply With Quote
Old 08-07-2007, 07:13 PM   #7
gartmann
Dogs Die In Hot Cars
 
Join Date: Jun 2003
Location: Sheboygan, WI
Posts: 109
I will monkey around with it in the morning. Thank you for your help
__________________
The Dude Abides
gartmann is offline   Reply With Quote
Old 08-07-2007, 07:27 PM   #8
gartmann
Dogs Die In Hot Cars
 
Join Date: Jun 2003
Location: Sheboygan, WI
Posts: 109
I got it to work.

just the opposite of what you thought but close:

maskedMc.setMask("MaskMc");

Here is my working code as of now:

Quote:
_global.k = 1;
function nextPic() {
clearInterval(setTime1);
trace(">> k = " + k);
var loadListener:Object = new Object();

loadListener.onLoadComplete = function(target_mc:MovieClip):Void {
trace(">> loadListener.onLoadComplete()");
target_mc.setMask(_root.picMask);
_root.picMask.gotoAndPlay(2);
if (_root.picMask._currentframe = _root.picMask._totalframes) {
setTime1 = setInterval(nextPic,5000);
}else if (k > 11) {
clearInterval(setTime);
}
}
loadListener.onLoadInit = function(target_mc:MovieClip):Void {
trace(">> loadListener.onLoadInit()");
}
if (k < 12) {
var container:MovieClip = empty.createEmptyMovieClip("container" + k, k);
var mcLoader:MovieClipLoader = new MovieClipLoader();
mcLoader.addListener(loadListener);
mcLoader.loadClip("http://www.address/madeup/" + k + ".jpg", "empty.container" + k);
k++
clearInterval(setTime);
}

}
__________________
The Dude Abides
gartmann is offline   Reply With Quote
Reply

Go Back   Flash Kit Community Forums > Flash Help > Flash ActionScript

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 05:21 PM.


internet.commerce
Be a Commerce Partner
 »  »  »  »  »  »  »
 »  »  »  »  »  »
 

    

Acceptable Use Policy


The Network for Technology Professionals

Search:

About Internet.com

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | E-mail Offers


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.