Load Dynamically Jpgs Into Flash?
Hi,
does someone know how to load dynamically jpgs from a certain directory into flash and work with them and to alter certain properties such as alpha, brightness, etc.
Are you able to do this with Action-Scripting or something else. It just has to work locally not over Web....
Would be very grateful for any help.
Thx Charly
FlashKit > Flash Help > Flash ActionScript
Posted on: 05-12-2002, 09:26 AM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Dynamically Load Jpgs In MC ?
is there a way jpgs can be dynamically loaded into a graphic symbol inside a movie clip without an event handler?
can the jpgs be put in an external folder where they can occasionally just be swapped out in the folder and it will be automatically updated in the .fla movie?
thanks! any help appreciated...
How To: Load Dynamically Jpgs
i've been constructing a site that will have roughly 250 images. A friend of flash told me that i should load them dynamically. I have no idea what this means or how to do it. I've been learning from books, but i can't get any helpful information in this regard. can someone direct me to a tutorial that specifically deals with jpgs? or tell me how i can move forward?
much thanks in advance.
A
Dynamically Load A Series Of Jpgs
Here's the problem, I'm trying to make a photo gallery of sorts for my digital pictures to send to relatives. I have a series of images IMG_001, IMG_002, IMG_003, etc... What actionscript can I put on VCR style buttons that will load the next Jpg?
For example
on (release){
emptyMC.loadMovie("IMG_00[n].jpg");
}
MovieClip Load Jpgs Dynamically
hey everybody,
i´m trying to load an external jpg to be displayed as a thumb dynamically into a movie clip.
that works with no problem.
the thumb then shall be clicked -
a bigger jpg is loaded into another movie clip. no problem either.
i´d like to make sure the movie clip loading the thumb is invisible until the external jpg has loaded.
there´s my problem.
does anybody know?
thanks,
moe
Help - Dynamically Load JPGs With Button Actions
Hi – I hope you can help me out with this.
I need help with how to dynamically load in numerous .JPGs to a movie clip (Flash MX).
Additionally, once the .JPG are dynamically loaded in, I need to be able to assign a button actions to some of them.
I’ve posted a link to the .SWF file and the .FLA file so that you can see how this function behaves and what I’m hoping to do.
Dynamically Creating MCs To Load External JPGs Into
Hi,
I'm trying to create a slideshow that loads pics (jpg) from an external folder ("pics/") into dynamically created MCs.
What I want is for the script to detect how many pics are in the folder (for future changes), create as many instances of the MC, and load the pics into each one. The MCs will need to take the W and H of the pics, and line up next to each other. This last part is not as important, I'm just wondering how to determine the number of pics in the folder. Do I need XML or will AS 1.0 or 2.0 do this?
Thanks!
mira
Dynamically Creating MCs To Load External JPGs Into
Hi,
I'm trying to create a slideshow that loads pics (jpg) from an external folder ("pics/") into dynamically created MCs.
What I want is for the script to detect how many pics are in the folder (for future changes), create as many instances of the MC, and load the pics into each one. The MCs will need to take the W and H of the pics, and line up next to each other. This last part is not as important, I'm just wondering how to determine the number of pics in the folder. Do I need XML or will AS 1.0 or 2.0 do this?
Thanks!
mira
Load External JPGs, Dynamically Resize Box...
I have seen this done quite often, but am not sure how it's done. I'd like to create an XML based photo gallery and have them placed in a box with a 1pt frame. When the images load in, if they are a different size, I would like to see the frame tween to the new size.
I kind of have it working, but it's not very pretty compared to the others I have seen. Anyone have an easy solution to this?
Thanks!
Dynamically Load Jpgs From Text File When Button Pressed
I have several buttons that each have a instance name. How can I load when I press a button load the right image dynamically into a mc.
I would like to define all my jpgs in a txt file.
example:
instance name jpg
1 450.jpg
2 122.jpg
3 542.jpg
...
Solution To Load Delay When Dynamically Loading Images - JPGS & GIFS?
Hi all, just set up an online interactive which dynamically loads images (JPEGS & GIFS) and text as required.
I set it up like this so that the client can easily replace text or images in future without needing to mess with the Flash files. Here's a code example:
loadMovie("image1.jpg", _root.bg.Background);
holder._x = 500;
I've made the images as small as they can be, but when testing it, I see that there is still a delay as each image is being called up - in some instances long enough for the user to wonder if it's working or not.
I also notice that when certain images are dynamically loaded for a second or third time, they are called again from the server - the file that was loaded already is not used.
Is there a way to pre-load all these images to prevent these issues?
Or any other solution or ideas would be helpful
Dynamically Loading JPGs From A URL Into Flash
Is it possible for the FLASH movie to dynamically pull gif / jpg images from a specified URL?
For some website I created the client is forced to come to me to get changes made. I was wondering if I could set it up so they could changed images on their server space and the flash site I designed will dynamically load them from the URL and place them in the movie.
I assume this is possible, I just have no clue how to go about doing it.
Any help / guidance is greatly appreciated!
Thanks
Glenn
Importing .jpgs Dynamically In Flash
Does anyone have a tutorial/.fla which shows how to import a .jpg dynamically into a flash movie.
Is it possible to have a preloader showing this image being loaded into the .fla?
Thanks in advance!
J
[Flash 8] Help With Loader_Mc An Dynamically Loading Jpgs
Hello, I am trying to dynamically load .jpgs into an Mc, and have this code on the loader clip
Code:
var loader:MovieClipLoader = new MovieClipLoader();
loader.addListener(this);
function onLoadInit(_mc:MovieClip) {
gotoAndPlay(2);
};
loader.loadClip("img/fan.jpg", _root.jpg_holder);
it works fine but i want to make it so it works for all the .jpgs i am trying to load not just "img/fan.jpg". is there someway to do this easily? i´m sure there´s a simple solution but just has´nt hit me yet.
cheers if you can help.
mike
Did You Know That Flash MX Can Only Load JPGs Of A Certain Type?
For some reason I could only get Flash MX to load one of three JPGs I had. The reason was that the one JPG used "Baseline Standard" instead of "Progressive". When I switched the other two JPGs it loaded fine. Interesting problem. Just thought I would let others know of it, in case you encounter it yourself.
Load Folder Of JPGs Into Flash
Hi all,
Does anyone know if it is possible to load a folder of JPGs into Flash? I have an online graffiti board application (see www.aegreen.co.uk/telematics) and would like to display the images created on an "online whiteboard" as it were but this would involve reading the folder the JPGs are stored in and loading them all in. Anyone know?
Thanks!
Flash Player 6 Won't Load JPGs W/ AOL 9.0
Last edited by PEDALSPEED : 2003-11-05 at 12:17.
One of our other developers had a problem with users on dial-up AOL.
Article:
When developing the website, one of the major issues was compatibility. The client wanted to be able to reach as many people as possible. This meant it had to work in all major browsers on both PC and Mac platforms. One of the biggest problems we had with this was JPEG loading. Over slower connections AOL will convert the JPG format into the more compressed ART file format for faster download speeds. This is a problem for Macromedia Flash Player because it cannot load the ART file format. The only fix for this problem was to change the file extension of the JPG to something else (such as FPG). This tricks AOL and the FPG file is not compressed. Macromedia Flash MX can still read the FPG as a JPG and the player can import the image.
:::SOURCE
::TECHNOTE
This is a new issue and the technote is new, so I thought it was worth posting.
Looking For A Script To Load Jpgs Into A Flash Movie....
Hello,
I need to load jpgs into a flash movie by clicking a next/prev button. The catch is that there might be as many as 200 pictures, so I would like to find the most efficient way of doing this.
thanks in advance for your help.
Load External .JPGs Into Flash Movie
I have recently completed working on a Flash MX 2004 file that displays a panoramic photo that can manipulated using interactive controls (plays forward, reverse, zoom in/out, etc.). However, the .jpg image was imported into the Flash file. I would like to be able to load the graphic externally (using actionscript?) to be able to change it with another .jpg of the same size/dimension without opening the .fla. Does anyone have any suggestions?
Thanks
Center Of Jpgs Shift As They Load In Flash Slide Show ?
Take a look at this slide show
Watch the center of the third image that loads, it also happens with a couple of others in this swf.
I've seen this now in several slide show type swfs I've created. Anyone have an idea what causes this and if there is a way to avoid it ?
Another Guy In Need Of Dynamically Importing Jpgs
hi,
i was wondering if i could dynamically upload different jpgs in a swf file. i have a client that wants to change the pictures they want to show in their flash movie. how can i do this w/o them using flash?
i thought maybe letting them name the jpgs 1, 2, 3, and 4 and that would allow for changing the pictures, but how could i upload, and update them to the swf?
grant
Inserting Jpgs In Dynamically
Here's a little intro to what I'm doing:
The site will have a movieclip of jpgs that scroll up and down the side of the screen. I want to be able to add or delete thumbs without modifying too much of the flash code. There's no server side support on this web server so I'm thinking about reading in some kind of data from a text file.
The problem:
I don't know how to dynamically insert jpgs into a movieclip. I tried the LoadMovie function but then I'd still have to insert the jpg into it somehow. Ideally, I'd like to create one movieclip and duplicate it with a different jpg in each one and place them all onto the big movieclip that will be scrolled. Any suggestions?
HELP!!!!
HELP Loading JPGs Dynamically
does anyone know of a method for loading JPGs dynamically into a movie clip? I'm not sure if this is even possible. My goal is to be able to have a JPG in a directory on my site, then be able to the movie, most likely through a text file, the file name of the JPG, it's height and width. I'm basically just trying to avoid having to create an SWF every time I want to add a JPG to the site.
Any help or suggestions regardiing how to accomplish this is gratly appreciated.
Thanks.
Dynamically Loaded Jpgs
I have read the threads about loading jpgs dynamically, and they have been very helpful. Now I have written code so it loads the jpg's when I run the swf on my Mac, and everything works fine. But I posted it to the website and it doesn't work when I try to view it from there. The main swf loads but when I click on the thumbnail to spawn the full size jpg, everything works as it should except it doesn;t load the jpg. I ensured that I put the jpg's in the same directory as the source swf.
Any thought would be greatly appreciated.
Brian
If you want to view it, go under the 'women' section, then click on any of the 4 thumbnails...
http://www.brianschnapp.com/nonnino/
Loading JPGs Dynamically
I am making a movie which has got huge no of big photos and the swf file is always reaching a size of 922kb to 1 mb.
Pls. tell me how to call the images dynamically then I think the size will go down.
Loading JPGs Dynamically
I can load JPGs dynamically into my movie.
However, I need multiple instances of this JPG on my stage. It seems that I cannot duplicate the movieClip containing the loaded JPG, while keeping the JPG intact.
Does this mean that the only way is to load multiple instances of this JPG?
Loading Jpgs Dynamically
I would like to be able to incorporate an image that has either been uploaded or that is from a database into a flash movie. How would I go about doing this?
What would happen in the case where the image is extremely large or extremely small - can you tell Flash to shrink/enlarge the dynamic image to a specified size?
I must apologize in advance as I am by no means an actionscript expert.
I appreciate your help
Loading Jpgs Dynamically
I have written this script to have external jpgs load into my file but the jpgs don not seem to want to load into my file. here is the scrip. Does anyone know why they won't load. Thanks
Code:
var slides;Array = new Array(["Transworld Snowboarding", "image0.jpg"], ["686", "image1.jpg"], ["Acadmey", "image2.jpg"]);
var currentSlide:Number;
function changeSlide(number:Number){
if (number >= 0 && number < slides.length) {
currentSlide = number;
title_txt.text = slides[number][0];
loadMoive (slides[number][1], "placeholder_mc");
}
}
changeSlide(0);
prev_btn.onRelease = function(){
changeSlide(currentSlide - 1);
}
next_btn.onRelease = function(){
changeSlide(currentSlide +1);
}
Dynamically Loading Jpgs
I am having problems dynamically loading a jpeg. I am trying to make it load into a movieclip with the instance name SAINTPICS5. As you will see from the code I am simulaniously trying to to move via a button from within a movie (this.)up and along the main time line to frame 16. Here I have a stop action and another movie which has an instance name 'cd'. I am successfully navigating to frame 16 and 'cd' is playing but the jpeg isn't loading.
Any help greatly appreciated
Thanks
Mark
(code on the button)
on (release) {
//Movieclip GotoAndPlay Behavior
this._parent.gotoAndPlay("16");
//End Behavior
}
on (release) {
this._parent.cd.SAINTPICS5.loadMovie("http://www.markwaterfield.com/images/bt.jpg");
}
Dynamically Importing Jpgs
hi using flash 8
I want to dynamically import jpgs that have different widhts
my xml looks like this:
<gallery2>
<pic>
<image>gallery2/images/p1.jpg</image>
<caption></caption>
<thumbnail>gallery2/tn/p1.jpg</thumbnail>
<size>272</size>
</pic> etc...
and the actionscript like that:
function thumbnails_fn(k) {
thumbnail_mc.createEmptyMovieClip("t"+k, thumbnail_mc.getNextHighestDepth());
tlistener = new Object();
tlistener.onLoadInit = function(target_mc) {
target_mc._x = hit_left._x+(target_mc._width+5)*k;
target_mc._width = [size]
target_mc.pictureValue = k;
target_mc.onRelease = function() {
p = this.pictureValue-1;
nextImage(); etc...
as you can imagine - IT DOES NOT WORK --- PLEASE HELP!!! HOW TO SET THE SIZE OF THE LAODED IMAGE DYNAMICALLY AND NOT FIXED.
Dynamically Loading Jpgs
Okay the problem is i need to load jps dynamically and store each one in a seperate movie clip that can be attached using attachMovie();. Now is this possible?
Dynamically Creating Jpgs
Does anyone know anything about dynamically creating jpgs from a flash movie? So, for instance - someone can create an image on an interactive flash page - then download it as a jpg. I've heard a rumour that its possible. Maybe using php or whatever.
any ideas?
Dynamically Loaded Jpgs At A Different Scale?
I need to borrow someones brain power!! Can anyone modify FLASH MX's dynamically imported jpg viewer, so that you can set the scale of the jpg being imported? Ex( importing the image at 50% of it's original size.
If you can figure that out, I would also like to have a button that could be used to blow up the image once it's loaded into the target
Loading Jpgs Dynamically -- Preloader Help
Here's the deal...
I have a mainmovie.swf which loads various MC's into it.
Each of these MC's dynamically loads a jpg file to use as a background which an animation occurs over top of. Each MC has it's own preloader which uses the getBytesTotal/loaded method, but it doesn't seem to take into account the jpg it has to load into itself.
So, what happens, is if your connection is a little slow, the animation starts to happen b4 the pic is loaded...LAME!
I see 3 possible solutions...
make the preloader count the bytes of the jpg as well
make another preloader for the jpg loading (argh)
make a lot of frames between the jpg frame and the rest of the animation (double argh)
Hopefully someone can help.
Thanks in advance!
RH
Positioning Dynamically Loaded Jpgs
I've used this to load a jpg dynamically:
loadMovieNum("R&A_2000.jpg", 1);
but of course it appears at 0,0 postion
what is the code to set the position differently?
hope someone can help.
Printing Dynamically Loaded JPGs
Can't seem to find any reference to this problem...
Trying to print out a movieClip that itself contains thumbnails that have been dynamially loaded into empty movieclips.
Problem is when I print it out not all of them are included in the page even though I have set the bounding box to be being big enough and have tested with huge sizes of the bounding box ending in strange effects... making the images smaller or bigger than their original size etc.
Here is a link to the site - http://www.bccreate.com/simonRoberts/ and click on V26
Click on the small "c" in the box at the bottom of the site and you will get a contact sheet come up that will load all the images (28 thumbnails).
Once they are all loaded a "print" button will appear in the bottom right hand corner.. click it and try printing it out to an Acrobat file to see what I mean.
This button has the correct scripting simply to print the movie with all the image movies in it: I have dabbled with the whole "bmovie", "bframe" and "bmax" settings but none of them print all the pictures which should fit onto one A4 piece of paper at their normal size. Also put the single #p frame and #b frame... these are not the solutions to the problem?
I have tested it by printing to an Acrobat file to save paper.
Maybe this is one for the mdoerators to solve?
Flash's printing seems to be very limited and a bit buggy... anyone else experience this problem?
Cheers
Dynamically Loading JPGs Into ScollPane
Hello All,
Please need a little help:
I am trying to dynamically loading jpg files into a MC ScrollPane, which loads correctly, however, the image is not displaying or scrolling correctly. The image shows up way at the bottom right and does not fully scroll.
Sample: http://www.wrstarkey.com/test/ob.html
Source: http://www.wrstarkey.com/test/OnlineBinder2.fla
I have tried using:
on (press) {
_level0.mypane2.tmp_mc.setScrollPosition(0, 0);
_level0.mypane2.tmp_mc.loadMovie("optimized/001AD-optimized.jpg", 0);
}
I would greatly appreciate any help/advice any one can offer.
Thank you,
Todd
Dynamically Loading JPGs Compression
Hi, I've made a portfolio viewer that loads JPGs dynamically using Ralf Siegel's ImageBox component. Now, I have a question.
How can I make a JPG to hold it's original compression?
When I export my Portfolio's SWF from Flash, I give it "JPEG Quality: 100", but the JPGs it loads, show up crappy. Even though I've made those JPGs without compression.
So, is there a way through actionscript or whatever to load the JPG, and setting export compression to none? Such as when you import a JPG, and then you go to the library and set it's properties.
Any help would be greatly appreciated.
Thanks in advance
Adrian
Dynamically Loading Images (Not Jpgs)
I am only able to dynamically load jpegs and swfs?
Or is there a way to load images of other file types?
The only method I know of is using:
loadMovie()
Thanks !!!
with much love,
Preloader For Dynamically Loading Jpgs
hello,
i've created a slideshow....a very simple one where the jpgs dynamically load every 100 frames or so.
does anyone know of a preloader that will load all the images in the beginning so my slideshow won't hiccup and stutter as it does? i don't need percentages or anything like that, but a simple preload bar would be good.
thank you!!
julia
OnLoad + Dynamically Loaded Jpgs
Hi All,
I'm trying to solve a problem that I see others may have resolved. Problem is, I can't find an answer that works.
I've got a MC on my stage, called rImage;
I'm got the following code:
Quote:
_root.rImage.onLoad = function(){
trace("rImage loaded");
}
lImage.loadMovie(imgPath);
My problem? the onLoad function never gets called. The image DOES get loaded. I just never get told when. Very aggravating.
Can anyone offer a fix?
ps: I've found a reference on the forum to an extension that fixes this problem, but it is no longer available. Anyone have one?
thanks
Progress On Dynamically Loaded .jpgs
Need some direction. I am pulling in a series of jpgs dynamically [via php / xml], and need to run a check on whether or not the entire file has loaded. The code I am using below definitely works in loading my dynamic jpg:
this.mc_holder.loadMovie(_root.basehref + _parent.slidelocation[_parent.currentslide]);
What is the best methodology to check to see if it is fully loaded? I have tried variations of the following:
bytes_loaded = Math.round(this.mc_holder.getBytesLoaded());
bytes_total = Math.round(this.mc_holder.getBytesTotal());
getPercent = bytes_loaded/bytes_total;
this.loadText = Math.round(getPercent*100)+"%";
if (bytes_loaded == bytes_total) {
gotoAndPlay("fadein");
}
But the problem is that they always post 100%, even when the file is not loaded. I have a fade on the file once it is loaded that I would refer to if I could run the check. Any ideas?
Resizing Jpgs Loaded Into A Mc Dynamically
I have a drag and drop card wizard. Where there are at least 3 hit test areas. If the hit test is true the dragable button loads a external jpg into the mc holder.
What I would like to do is have the jpeg dynamically resize to fit the empty mc. Each hit area/mc holder for the jpeg are different sizes, so I would like the jpeg to accomadate the mc holder.The mc holders need to be a set size.
Any help with this is so appreciated! Thanks all in advance.
Not Showing All Dynamically Loaded JPGs?
Hi I've made the following FLASH app which dynamically loads JPG's into a row of images check out
http://www.lichinger.dk/testshop/get_artist_images.html
However not all of the images are loaded? Any idea why? I know that FLASH doesn't like progressive JPG's, and the images I use are all-nonprogressive.
Caching And Dynamically Loading Jpgs
I'm making a SWF where I want to have a tile of image with 6 repeated jpgs used. I ended up setting up a 4x6 grid of movie clips and then calling loadMovie on each clip to load in a random jpg (1 of the 6 jpgs).
When testing with the bandwidth simulator, I was concerned because it appears that the swf will download each call to the jpgs over and over rather than caching. I would figure that if clip1 uses jpg1, then if clip8 also uses jpg1, there would be no download hit, but that's not what the bandwidth simulator is showing.
I even set up 6 invisible clips off the stage and pre-loaded the jpgs into them, but no luck. Also, I tried duplicateMovieClip on those 6 clips and the duplicated clips would not preserve the loaded jpg.
My question is there a way to cache dynamicly loaded jpgs at the beginning of a movie and then re-use those jpgs without getting a download hit?
Thanks,
Dennis
Loading .jpgs Dynamically Without Delay
im using a loadMovie code to load a few .jpgs sporadically throughout a timeline.. but there is always a few seconds delay for the .jpg to actually load. is there a way i can preload all dynamically loaded images so when the loadMovie code comes along.. those images show instantly? i appreaciate any ideas you might have. thanks
Dynamically Loading Jpgs Size.
Hello !
I tried to search forums, but did not find anything that could solve my problem. Here it is : Im trying to make dynamic gallery with loading 3 pictures under the text. Text part works fine, but is there any way to add onEnterFrame function to these babys :
Code:
for (i=1;i<=this["pilte"+a];i++)
{
_root.mload.L.createEmptyMovieClip("pxc"+a+"p"+i,a+""+i);
_root.mload.L["pxc"+a+"p"+i]._x = _root.mload.L["pxc"+a+"p"+(i-1)]._x+50;
_root.mload.L["pxc"+a+"p"+i]._y = _root.mload.L["gtxtsisu"+a]._y+_root.mload.L["gtxtsisu"+a]._height+10;
_root.mload.L["pxc"+a+"p"+i].loadMovie(_root.host+"/pics/"+this.id+"/"+i+".jpg");
_root.mload.L["pxc"+a+"p"+i].onEnterFrame = function ()
{
if (_root.mload.L["pxc"+a+"p"+i]._width > 0)
{
_root.mload.L["pxc"+a+"p"+i]._width = 40;
_root.mload.L["pxc"+a+"p"+i]._height = 30;
}
}
}
This is a cycle inside another cycle, but this one is with the prob.
As you can see, i tried to add onEnterFrame func to each one mc, i also tried it just _root.onEnterFrame =
and this.onEnterFrame =
Is there any other way to resize those jpgs?
thnx,
Manrico
Masking Dynamically Loaded Jpgs
I'm loading in jpgs via an XML array. The jpgs load into the 'holder' movieclip, but the mask doesn't work, it just sits on top of the image. Is there something I'm missing? Thanks for your help.
ActionScript Code:
// Load mask movieclip
attachMovie("mc_mask", "mcMask", getNextHighestDepth());
mcMask._x = 190; mcMask._y = 49;
var x:XML = new XML();
x.ignoreWhite = true;
var paths:Array = new Array();
x.onLoad = function(success) {
var links:Array = this.firstChild.childNodes;
for(j=0; j<links.length; j++) {
paths.push(links[j].attributes.path);
}
holder.loadMovie(paths[0]);
}
holder.setMask(mcMask);
|