ActionScript 2.0 :: Loading JPG Images Into Movie Clips, Then Drawing A Border Around Them?

Aug 26, 2009

i am loading JPG images into movie clips, then drawing a border around them with this code:

Code:
var frameColor:Number = 0xffffff;
var lineThick:Number = 1;[code]..............

i am resizing the movieclips (and thus the contained pictures) down to 160 x 120, but those pixel values didn't work in my lineTo statements. i multiplied them by 3, using 480 and 360 and it works better. however, the behavior isn't consistent. i am attaching a picture so you can see how the border is too tall on some of the images.so, is there a better way to use pixel dimensions with lineTo? does the scaling factor between flash vector units and pixels change between movieclips depending on what content i load into the movie clip?

View 1 Replies


Similar Posts:


ActionScript 3.0 :: Loading Images Into Movie Clips Onto Stage

Jun 2, 2011

I'm having an issue with placing images loaded from an XML file in placeholders within movie clip instances on the stage. It'll load an image onto stage, but only one image. I'm kinda at a loss at the moment.

Code:
import com.greensock.TweenLite;
import com.greensock.easing.Back;
import com.greensock.loading.*;
import com.greensock.loading.display.*;
import com.greensock.events.LoaderEvent;
[Code] .....

View 6 Replies

ActionScript 2.0 :: Loading Images To Duplicated Movie Clips?

Jul 26, 2007

I have a problem in loading pictures to duplicated movie clips. I have a dynamic sliding menu and I wanna load images to submenus. However I havent succeeded yet.

Here is the code:

setProperty("Rub", _visible, false);
setProperty("subrub", _visible, 0);
bas._visible=false

[Code].....

View 3 Replies

Dynamically Loading Images From A JSON Feed Into Individual Movie Clips

May 22, 2009

I'm dynamically loading images from a JSON feed into individual movie clips and then adding the clips to the stage(both by addChild)--basically creating thumb tiles. I've added a click handler to do something when the MC is clicked. WHAT'S MY PROBLEM: The problem I have is that the MC is clickable, but the content is not. For instance, the clip has a white box in it, and the loaded image is made slightly smaller and centered to give a white border around the pic. An empty clip loaded to the stage works fine, and the white border around the image is clickable, but the image is not.

View 1 Replies

ActionScript 2.0 :: Adding Border To Movie Clips?

Jan 15, 2009

I have a scrolling image strip that loads images from xml. I was wondering how I could attach a border to the movie clips that the images are loaded into. I know how to use the drawing API, but I can't seem to attach a border to each movie clip. I'm posting the code below.

Code:

cliparray = [];
function loadXML(loaded) {
if (loaded) {

[Code]....

View 1 Replies

ActionScript 2.0 :: Drawing Line Between Two Movie Clips?

Mar 9, 2010

I've got two movie clips; right_hip and left_hip. How can I make it so a line is drawn between the two?And, as a precaution, how can I make one point offset? By that I mean if right_hip was a square, and it's registration point was on the left side, how do I make the line go to the centre of it?

View 7 Replies

ActionScript 3.0 :: Flash Drawing Line Between Duplicated Movie Clips?

Jul 9, 2010

wat i want to make.. is a graph plotter.. i add movie clips on the stage and a line should connect them all.. but im having a fkload of problems in solving that..here is the code for adding the movie clips.

function makeABox(e:Event):void {
var newBox:myMC = new myMC();
addChild(newBox);

[Code].....

View 1 Replies

ActionScript 2.0 :: Loading Resized Border Into Another Movie?

Jun 2, 2004

There is a code for the effect of resizing border in this tread: [URL]

Has anybody here loaded the picture+border (output of the code) into another movie through loadMovie?

View 9 Replies

ActionScript 2.0 :: Loading Dynamic Images Into All Clips

Oct 13, 2002

i know there been a lot of poasts on this but none of them. I am duplicating a movie clip called "thumb" on my main timeline. they are named by number (1 to 233) within each clip i would like to load an image

[Code]...

the reason i have put in 10.jpg is just to get it loading one image into all clips. But its not loading the image into any. the trace is bringin back each MC's name fine when i remove the if(_name != "thumb"){ it loads the image into the duplicated original MC so im completely confused. this is the duplication script on the first frame of my Main timeline

[Code]...

View 2 Replies

ActionScript 3.0 :: Drawing A Border Inside A Mc?

Mar 23, 2010

Flash draws borders centered on the edge of shapes. Is there an AS3 way to draw a border all inside a shape? I've got an image gallery and I'd like to create a rollover effect with a 4px border growing inside the thumbs. I can do it via timeline, but I'd like to do it via AS.

View 11 Replies

ActionScript 3.0 :: Drawing Border Around Arbitrary Shape?

Feb 12, 2009

Is it possible to draw a border around an arbitrary Shape (or Sprite) dynamically with ActionScript? From the IDE is really easy, just select the line color and click the Shape with the paint tool (S).

View 3 Replies

ActionScript 2.0 :: Dynamic Border Drawing Code?

May 2, 2006

Anyone know if there is some actionscript that could draw a border around a movieclip?

View 3 Replies

ActionScript 3.0 :: Drawing Sprite Border For Xml Driven MCs?

May 22, 2009

I'm having an issue trying to automatically create a Sprite border for movieclips generated by an xml file.

Here is my loop function :

Code:
function callThumbs():void {
for (var i:Number = 0; i < my_total; i++) {
var thumb_url = my_images[i].@THUMB;

[Code]....

All the pictures from the xml file do load, they all have the glowfilter effect but only the first one has border..

View 2 Replies

Actionscript 3 :: Drawing A Rectangle - The Border Is Partially Off-screen

Jan 10, 2011

I am drawing a rectangle at 0,0 with a line-style-thickness of 4px. It has height 100% and width 50%. The right-hand edge has a border 4px wide, but all 3 other sides are only 2px, suggesting the mid-point of the edge is classed as the border. Why isn't the edge drawn 'inside' the rectangle?

View 1 Replies

ActionScript 1/2 :: Loading Multiple Movie Clips Inside Another Movie Clip?

Mar 11, 2010

I was wondering about the flexability of loading movies into a movie clip. Currently, I am well able to load one movie into a movie "loader" clip, but thought maybe there is a way to load additional movie clips into that same "loader" clip, as i am starting to accumulate several different graphics that i need to have be inside movie clips so that i can make them change colors on the same frame when needed.
 
i shot from the hip and tried this code, but didnt have any luck:
 
mc_LCD_loader.attachMovie("hilight", "g", 1), ("header", "X", 1); mc_LCD_loader.g._x = 0; mc_LCD_loader.g._y = 1000;
mc_LCD_loader.X._x = 0; mc_LCD_loader.X._y = 1000;

[Code]....

View 9 Replies

Flash 9 :: Line Up Images In Different Movie Clips?

Oct 12, 2008

I have a movieclip, does some animations etc.

Is it possible to view that movieclip at the last frame on the stage, so that i can then line up items in another movieclip with it?

Driving me nuts trying to get the pixels perfectly lined from two different clips

View 3 Replies

Randomly Dynamically Load Images Into 4 Movie Clips

Jul 29, 2009

I am designing a website and have for locations I would like to load a random image from the same folder. Goals we'd like to accomplish with this:

1. We want images to load randomly from same folder
2. We don't want any duplicate images on the page at any one time
3. We have different size movie clips they are loading into.

Is there a way to accomplish this? What script do I use to resize the .jpg to fit whatever movieclip it's loading into and how to I tell it not to load an image that is already loaded in another movieclip?

View 1 Replies

Actionscript :: Flash - Export All Movie Clips As Images?

Aug 17, 2010

You can manually save some particular movie clip on a stage as an image by running "Export > Export Image". Is it possible to write an actionscript that would export all movie clips on a stage to images automatically? Or at least is there a way to automate this in any way?

View 3 Replies

ActionScript 3.0 :: Dynamically Adding JPG Images As Buttons Or Movie Clips?

Aug 27, 2008

Using an XML file, I am pulling a series of JPG images from my hard drive onto the stage. Each of these images will need to have different mouse events placed on them that will take the user to another part of the movie, or perhaps to a different scene.

The attached code successfully pulls the images to the stage -- as JPG images -- and spaces them. What i need to do is make each of them a
button or movie clip, each with a specific action (information which can be gleaned from the XML).

Eventually, I'll need to show images from this XML file based on user-selected criteria via some check boxes. And I'll also need to build some kind of "show next 9 images" and "show previous 9 images" functionality.

View 3 Replies

ActionScript 2.0 :: Laoding External Images Into Movie Clips In Different FRAMES

Aug 4, 2008

I generally don't mess with the timeline, but I need to for this project. In a nutshell: user can customize a product reference sheet with her choice of crossection, footprint, etc. All those choices exist as external swfs. In order to be legible, the reference sheet must be two pages.I know how to print multiple frames with Flash. But what I cannot yet achieve is loading external swfs into movieclips on different frames, and then print that. Here's my code from a test fla:[code]Now, this code will print both frames as separate pages, but the loaded image in printArea.holder2 does not print!

View 3 Replies

ActionScript 2.0 :: Building A Project That Loads 30 Images In To Empty Movie Clips?

Apr 20, 2005

I am building a project that loads 30 images in to empty movie clips. I want one of the images to apear on top randomly. What is happening now is that the first swf in my loop always shows up on top.Here is a link to waht i am doing:Here is some code i am working with:

Code:
// Random range
function randRange(min:Number, max:Number):Number {

[code].....

View 2 Replies

Loading Movie Clips From A Button?

Feb 28, 2010

I have three movie clips, called clip1, clip2, and clip3 that are in my library but not on the stage.

On the stage, I have a movie clip of a curtain that is a button. How can I make it so that clicking my button (which makes the curtain rise) will load and play one of the movie clips in the library?

View 1 Replies

ActionScript 3.0 :: Loading Movie Clips One After Another?

Feb 22, 2009

I have 16 movie clips on separeted layer on frame one on the timeline and I want to start one after another with a delay of one second between each of them. I feel like it should be easy, but I didn't find the solution so far. Anybody with a real life exemple, a tutorial or what method to use?

View 3 Replies

ActionScript 2.0 :: Loading Movie Clips?

Sep 30, 2003

have a movie and want to load external swf files into the middle section. my navigation allows users to access from 10 buttons. i can load the swfs either thru reateEmptyMovieClip, or loadmovieNum. but i can't seem to control the levels. that is previous movies can be seen underneath the new loaded movie... i need to clear previous movie clip before loading the next, i think??here is createEmptyMovieClip code.

this.createEmptyMovieClip("generic_mc",2);
generic_mc.x=0;
generic_mc.y=62;

[code].....

View 6 Replies

ActionScript 3.0 :: Loading And Unloading Movie Clips?

Mar 12, 2010

SO what I have here is a simple menu with 5 buttons. I have event listeners attatched to each button that loads an external swf each time each button is clicked. Im trying to wrap my head around a solution to unloading the movie clips. as it is each swf is just getting loaded on top of the other one when the button is clicked.

a sample of a button code is:
var hList = hardwareDisplay;hardware_mc.addEventListener(MouseEvent.CLICK, hListDisplay);function hListDisplay(event:MouseEvent):void{  hList = new

[code]....

View 5 Replies

ActionScript 2.0 :: Loading Data From Xml Into 3 Different Movie Clips?

Jan 28, 2009

I am trying to load data into 3 different movie clips. (content_mc, content2_mc and content3_mc). Each movieclip will get one image and two bits of text (picture, who and bios <== instance names)

Those 3 movieclips are inside of another movieclip, contentHold. That movieclip is setup to scroll vertically ( I was able to do that myself ).

SO my problem is I have that I can't figure out how to load the data into the 3 movieclips as I want to.

I have attached my .fla and .xml file from the project.

View 3 Replies

ActionScript 2.0 :: Loading Movie Clips From Library?

Jan 30, 2009

I'm new to AS but have some coding background (php, sql, vba) and some basic (non-AS) Flash skills.I want to create a bar chart a bit like this: http:[url].....Really would like some sample code if poss. This is my thinking:

1) Each section of the bar chart will be a movie clip, mc_2, mc_3 etc.

2) There will be an array with Qty, Type, Desc and Name of movie clip (e.g. mc_3).

3) There is a generic bar chart "block" movie clip in the library ("Block")

4) So I plan to loop through the array, attachMovie for each iteration, resize the Movie proportionate to Qty, and colour it by Type.

Problem is: (1) I don't know the right functions to use; (2) Are mc_2, mc_3 INSTANCES of my generic movieclip, "Block" ? (3) should the code sit on the timeline? (4) do i need an empty movie clip to attach the library item to?

Code:
Pseudo code:
n=length of array
for (var i:Number = 0; i < n; i++) {[code]....

The final thing would be a bit more complex with frames etc, but generating the movies would be a start.

View 2 Replies

ActionScript 3.0 :: Loading Different Movie Clips To ScrollPane?

May 6, 2010

The site is structured with all content inside entireSite, with two further movie clips nested myMenu, which contains all the button movieclips (rollovers etc) and AS to navigate the site and another entitled allPages which contains all the content.

on entrance to the site i want a grid of images appears which is scrollable using scroll pane. I have managed to achieve this just on a standalone .fla following this tutorial with the code

[URL]

scrollPane.source = myContent;
scrollPane.setSize(556, 300);

with the code sitting on the main timeline

now i have structired my site properly im having difficulty getting it to load correctly. I have the correct instance names for scrollpane and the linkage for the movie clip i want to load. im just wondering that now my scrollpane is nested in entireSite then allPages that the code will not recognise it?

How do i make it point to it? Also, as i move between different pages of the site more content will require a scrollPane, can i just use different instance names to do this?

Or should i go about removing the movieclip in scrollpane and adding a new one?

View 0 Replies

ActionScript 3.0 :: Dynamically Loading Multiple Movie Clips

Aug 11, 2010

I am trying to perform the following:
1. Create a series of movie clips on the stage
2. Give each one a specific name (i.e. movieClip1_mc)
3. Load an image into each one
4. Add three unique listeners to them (MOUSE_OVER, MOUSE_OFF and CLICK)
Afterwards I want to create one single function that will handle all the above boxes depending on which box is clicked.

Obviously the 1st part is simple enough and I have no problem there. Without relying on the "multiple movie clip" parts, I can easily handle the next three - just can't get it to work when working with multiple dynamic movie clips. Where I get stuck will always be giving each one a name and then moving forward. One big issue I continuously face is creating one dynamic function that will handle based on which movie clip the user interacts with.

View 10 Replies

ActionScript 2.0 :: Loading Random Movie Clips From An Array?

May 2, 2011

My project has about 30 movie clips in the library. With an action that comes up every few seconds, I'd like to randomly load one of those 30 clips onto the stage and have it play until it's done.

BUT - once a movie clip is already out, I don't want it to reset or come out again. I'd like the next action to randomly call out one of the remaining 29 clips.

Once each movie clip is done, I need some action to make it go back to the "available" list so that it can be called out again.

I'm guessing that I need to use attachMovie to call out the movie clips, and an array (maybe two) to make sure that I only get one instance of each movie clip. But after lots of searching and various dead ends, I'm just not finding exactly what is needed.

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved