Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Memory Leaks In Flash? Cus My Program Is Using Over 235,000kbs Of Memory



ANY HELP APPRECIATED as i've spent 2 days on this (started 2 days 3 hours ago)... please help me

I have only 16 images in my program, its a slideshow, all my images have a small image selection which on(rollOver) shows that image in a bigger screen, however when my program launches, I do ctrl + alt + del, and my memory usage for that swf file I made is at 235,000kb of memory, and my laptop can't handle it, (its 70mb) and the original .fla file is (70mb)

Is there anyway to fix this, I belive my scripts are leaking, I know for a fact, im not cleaning my locals... or globals...

if I declare a variable should I set it to null?

Question 1: Should I remove local variables? if so how do I do it?
Question 2: Should I remove global variables? if so how do I do it?
Question 3: Any other things I need to know?

this is my code for start up, which hides all images not in the first 4 places (which is suppost to be visible) the others are turned invisible...

Code:
_global.b = Array();
_global.end = 16;
_global.b[0] = btn_1;
_global.b[1] = btn_2;
_global.b[2] = btn_3;
_global.b[3] = btn_4;
_global.b[4] = btn_5;
_global.b[5] = btn_6;
_global.b[6] = btn_7;
_global.b[7] = btn_8;
_global.b[8] = btn_9;
_global.b[9] = btn_10;
_global.b[10] = btn_11;
_global.b[11] = btn_12;
_global.b[12] = btn_13;
_global.b[13] = btn_14;
_global.b[14] = btn_15;
_global.b[15] = btn_16;
_global.X = 40;
_global.Y = 30;
var t:Number = Array();
for (var i:Number = 0; i<4; i++)
{
t[i] = (i*100)+80;
}
for (var i:Number = 0; i<_global.end; i++)
{
var b = _global.b[i]._x;
_global.b[i]._x = (i*100)+t[0];
if (b != t[0] and b != t[1] and b != t[2] and b != t[3])
{
_global.b[i]._visible = false;
}
else
{
_global.b[i]._visible = true;
}
}
code for scrolling through my list of images (as it only shows 4 on the screen at one time)

basically, each image is 90 * 68 (width/height) the X position of the first image is 80, and it increments by 100 each time, until the 5th image, in which its 30, the start up code above, spaces them out by 100 (as I normally dont have enough room to fit 16+ images spaced out by 100) it also does other things

Basically, t gets the X position of last image... then

And basically hides and unhides images pending if they're X position is 80, 180, 280, 380...


Code:
on(release)
{
var t:Number = 0;
for (var i:Number = 0; i<_global.end; i++)
{
t = (i*100)+80;
}
for (var i:Number = 0; i<_global.end; i++)
{
if (_global.b[i]._x > 79)
{
if (_global.b[i]._x == 80)
{
_global.b[i]._visible = false;
_global.b[i]._x = t+100;
}
if (_global.b[i]._x > 579)
{
_global.b[i]._visible = false;
}
if (_global.b[i]._x == 480)
{
_global.b[i]._visible = true;
}
_global.b[i]._x -= 100;


}
}
}
The next code is for "enhancing" my images a little bit, it increases its Width & Height by 30 and 40... and decreases by that on rollOut / dragOut

(as you can dragOut and rollOut doesn't happen therefore I need it so you can't "increase" the image height & width without decreasing when your mouse moves off it)

Code:
on(rollOver)
{
gotoAndStop(2);
var b = btn_1
b._width = b._width + _global.X;
b._height = b._height + _global.Y;
b._x = b._x - X/2;
b._y = b._y - Y/2;

}
on(dragOut)
{
var b = btn_1;
b._width = b._width - _global.X;
b._height = b._height - _global.Y;
b._x = b._x + X/2;
b._y = b._y + Y/2;
}
on(rollOut)
{
var b = btn_1;
b._width = b._width - _global.X;
b._height = b._height - _global.Y;
b._x = b._x + X/2;
b._y = b._y + Y/2;
}
Thats it, they're basically 1 of each different thing I have... it basically stays the same, I have 32 images (large_1-16, and small_1-16)

They're exactly the same size, but I wasn't sure if I could use 1 image twice, for different things (they're size is 2500 * 1900 give or take a 100 or so)



ActionScript.org Forums > ActionScript Forums Group > ActionScript 2.0
Posted on: 03-04-2007, 02:34 AM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

How Can I Check My Program For CPU Usage And Memory Leaks?
I made a dynamic animation swf. I'd like to make it as lightweight as possible. Does anyone know of any tools or tricks or tips on how to optimize my code?

-thanks

Memory Leaks In AS2
Hey folks,

I am working on some *AS2* code.

Problem: Basically, I'm loading my SWF file in Firefox; and the memory
used is going upwards nonstop. After a couple of minutes, all system
resources are used and I need to restart the browser. I suspect
(obviously) a memory leak or the garbage collection not doing its proper
job.

Question: Is there some tools I can use to diagnose this problem and
retrace where the leak is coming from. Ultimately is there some garbage
collection optimization I should be aware of?

Thanks

Memory Leaks
I have a project that has a memory leak, and I'm having difficulty finding it. I've narrowed it down to a small code block, which includes changing the values of two dynamic textfields, one of which is html, and loading a jpeg into a container clip. All these objects are contained in a single movie clip, and the values loaded into them are stored in arrays.

Has anyone experienced memory leaks caused by html enabled textfields? It seems at this point as if the html textfield may be the cluprit. Is there a list of known memory leak causes online?

Memory Leaks Over Weeks
hi,
a very rare question i'm sure.
i've made a flash movie that runs on a display. this movie may run without being turned off for up to 6 months.
as it runs the memory it takes up increases. about 1mb a day.

how can i clear the memory?

Memory Leaks And SOAP
I have been reading about web services and how you can either use Flash Remoting or SOAP - But there are some serious memory leaks if you use SOAP. Does any know if this has been fixed?


Thanks

How To Detect Memory Leaks?
Just wondered how to detect them and what's the remedy?

Thanks again!

AS3 - Tackling Memory Leaks
So I've been working on a fairly large, AS3 app for some time now. It has tons of graphics, sounds, animations, a couple video clips, and almost 500 external class files or so. I'm just starting to notice that after extended play, some of the animations start acting a little choppy. I'm guessing I've got a memory leak.

I've determined / tracked these down before using Valgrind, but never had a reason to track them down in an AS app. Besides the obvious "dig through the code" and "handle memory efficiently to begin with" (which I thought I had), any extra tips to tackling memory leaks in AS3?

Thanks,
~JC

How To Find Memory Leaks (FlvPlayer)?
Hello,

I created an application(uses FlvPlayer), which load .flv file from outside.
If I will load.flv file many times, it increases flashplayer's size drastically. Each time it increases the size by 10MB. After 30-35 attempts, it stops playing sound, it only play the video(It goes in mute mode).

Would you please tell what is the best way to dispose/distroy the loaded resource from FlvPlayer?
What things I must consider while working with FlvPlayer?
And why the FlvPlayer is playing video properly but not playing audio file?

I would appriciate your response.
Thank you.

REMOVED_FROM_STAGE, RemoveEventListener(), Contains() And Memory Leaks
Hullo! This is my first post here.

I have been (teaching) scripting for many years with various systems including OOP Flash, and so I am not a beginner. I am using CS3, fwiw.

For my own projects I mostly use classes, which behave exactly as I expect them to, but I get unexpected results when putting code and display objects into the timeline during authoring. I am rather obliged to use scripts and display objects in the timeline because I am teaching ActionScript 3.0 to absolute beginners, and I know from bitter experience that going straight to classes is too great a first step.

In particular, I have various problems understanding AS3's event listener mechanism, especially as it relates to garbage collection with display objects placed on the timeline during authoring.

The problems outlined below mostly do not pertain to display objects added and removed with addChild() and removeChild() respectively.

I am sure this is 'old news' for many of you, but I haven't really been able to find solid, concise information about when (or whether) to use removeEventListener in relation to removeChild() and/or timeline navigation. I'm also having a hard time understanding the 'use weak reference' property, which appears to be relevant here somehow.

My own conclusions are that it is a wise 'rule of thumb' to removeEventListener for every event attached to a movieClip, when the movieClip is taken off stage (for example when navigating to part of the timeline where the clip is not present). That's a big pain in the AS3, especially for beginners, and perhaps worse still for those coming from AS2. Nobody likes cleaning up, least of all beginners and people that never had to clean up before.

It might be 'memory safe' (i.e. leak-free) to leave mouse and key events hooked up (how could we test, anyway?), but stuff like ENTER_FRAME definitely needs to be killed off, or the display object will just keep on keeping on, even when it's no longer 'there'.

It appears to me that the REMOVED_FROM_STAGE event is ideal for this kind of 'cleanup', no? I understand that REMOVED happens just before the object has been removed, whereas REMOVED_FROM_STAGE happens just after.

The docs are not entirely clear to me on the specific subject of display objects placed on the timeline during authoring, which are 'removed' because of timeline navigation, and whether this is supposed to be the same thing as removeChild(). My tests indicate that it is not the same thing at all.

One thing is for sure, display objects placed on the timeline in authoring do indeed get a REMOVED_FROM_STAGE event when the playback head leaves their 'scope' in the timeline.

My questions, then:If I have the 'useWeakReference' parameter as true, when I add an enterframe event listener, is it correct/by design that an object 'removed' from the stage as a result of timeline navigation continues to receive enterframe events? When does such an object get garbage-collected, then? Does the useWeakReference parameter have any meaningful effect at all when adding an enterframe event handler?

Also, what is the 'correct' frame rate to expect when an object has been removed? (Individual timelines can have their own framerate).

It seems to me that these display objects accumulate in RAM, and therefore represent a memory leak - which is what 'useWeakReference' is supposed to prevent, no? This makes me worry about leaving mouse and key events hooked up to no-longer-present movieclips, because every time we return to the timeline scope of those objects, new instances are created.

The docs say that contains() returns "true if the child object is a child of the DisplayObjectContainer or the container itself", but my tests indicate a quirk:

If the object was put on stage, and 'taken off' in a Flash timeline (rather than with addChild/removeChild), the contains() method returns true even AFTER the object is gone. Is this an error of documentation, or my own misunderstanding?

According to the docs, the parent property of a display object is set to null when the object is removed from the stage. (i.e. sometime after REMOVE and sometime before REMOVED_FROM_STAGE), but event.target.parent appears to point to the old value, even in REMOVED_FROM_STAGE events.

I even tried using a timeout of a few seconds, to give Flash a chance to set parent to null (I had to use a class to make this work), but as long as the display object was put on stage in Flash, rather than with addChild(), parent is never set to null after removal, and stage.contains(theNoLongerPresentMovieClip) will continue to return true. This strikes me as downright wrong. Works fine with objects added dynamically, however.
Is it possible to get a list of all the listeners attached to an object? I can't find anything in the docs about it.


To test this, put a movieclip (instance name "m_mc") in frame 1 only of a 2 frame movie. Notice that the parent of the dynamically added/removed object is set to null correctly, but the parent of the object added in authoring remains fixed.


ActionScript Code:
// script for frame 1

// test with object added to stage in authoring (m_mc)
m_mc.addEventListener(Event.ENTER_FRAME, foo, false, 0, true);
m_mc.addEventListener(Event.REMOVED_FROM_STAGE, foo);

// test with dynamically adding and removing a display object:
var m2_mc = new MovieClip();
m2_mc.addEventListener(Event.ENTER_FRAME, foo, false, 0, true);
m2_mc.addEventListener(Event.REMOVED_FROM_STAGE, foo);
trace("**"+stage.contains(m2_mc));
addChild(m2_mc);
trace("**"+stage.contains(m2_mc));
removeChild(m2_mc);
trace("**"+stage.contains(m2_mc));

// leave timeline scope of m_mc
//removeChild(m_mc); comment this back in for 'more correct' behavior
gotoAndStop(2);

function foo(e) {

    var et = e.target;
    var kids = stage.getChildAt(0)["numChildren"];
    var report = "";
    report += (et.name + " just got a " + e.type + " event.
");
    report += ("Main timeline has " + kids + " children.
");
    report += ("Parent of " + et.name + " is " + et.parent + "
");
    report += ("stage.contains(" + et.name + ") " + stage.contains(et) + "
");
    trace(report);
    trace("");

}

Notice also that contains() returns true in both cases in the REMOVED_FROM_STAGE event handler, but in the dynamically added/removed object, contains() functions as advertised thereafter.

This appears to indicate that event.target.parent is NOT null during a REMOVED_FROM_STAGE event, which is contrary to what the docs imply. What then is the difference between REMOVED and REMOVED_FROM_STAGE?

BTW if you removeChild(m_mc) just before going to frame 2, this discrepency disappears. Hmm. Shouldn't Flash just remove the thing properly in the first place?

Thanks in advance for anything which may enlighten me!

Memory Leaks With Socket And Loader
Hi,

I wrote a flash app that connects to a server ( with Socket() ) which sends out packets of binary data which represent jpeg images that form a video stream ( about 6 images/second ). I then store this data into a ByteArray and load it with Loader.loadBytes(). I works really great with one exception: it leaks memory horribly. I can't figure out exactly why it's leaking. I have read up a lot on Flash garbage collection, but I can't seem to find the problem.

Thanks!

Timer And SetInterval Leaks Memory
Set up a timer to tick every second (or an interval). Monitor the memory usage of your application.

You'll see that it tags on like 10kb to the memory usage every 5-6 ticks. This never gets freed.

Had something really simple like;


ActionScript Code:
public function main()         {            _timer = new Timer(1000);            _timer.addEventListener(TimerEvent.TIMER, report, false,0, true);            _timer.start();        }        private function report($e:TimerEvent):void        {                }


And nothing in the fla. So it literally does nothing but tick every 1 seconds and this increases the memory usage with 10-15kb every 4-5 seconds. I let it run for an hour and it never gets freed.

What sort of evil BS is this

Turn Memory Card In Memory Game
Are there still no way of rotating a bitmap in flash with descent result? A property that I dont know of..?!=)

Flash 5 Out Of Memory?
Hi im getting an error message from flash 5 running on win 98.
Ive imported a sequence of GIF's and made them into a movie, when i try to place the movie onto the stage where im working flash starts to carry out the command but fails with an out of memory message telling me to use the GET INFO command with the FINDER?
Can anyone help me?
Thanks in advance
Les

Memory And Flash
What is it talking about.....I work with large programs everyday that uses up alot of memory and flash dosent seem like a memory buff....everytime i try to do anything intensive in there the whole program freezes on me and says something about "you need more memory to allocate more memory to flash please quit the program and goto the get info" ... What in the world is it talking about ... where is this get info at?

Flash With Memory ?
Hello !

I would like to make a screensaver with posibilitys to make
notes like 3M post-it notes, the flash file should "remeber"
the input that the user writes.

Is this possibel ??!!

I have the tools to make screensaver in Flash, but how to make such
a flash file ??

Thanks
Swed

Flash's Memory
hi all,

does anyone know how to increse flash's memory cos i am wanting to open a file i did along time ago and cant because flash says there is not enough memory allocated (or something along those lines)

is there any way i can fix this?

thanks

Does Flash Have A Memory?
Hey,
i'm using a preloader i developed for a presentation i am setting up for the web. The preloader is commanded to load pictures and swfs and works fine, but my problem is that because currently the files loaded are local (on my computer), it is impossible for me to test loading times.
I have created some code (using arrays and loops) that remembers the path of all files it has been asked to preload. Then, if flash detects that a new file that it has been asked to load has in fact been loaded before, not to bother with preloading the file. When i test this on my computer though, i cannot be sure of the results, because as the files are local, they (may) take no longer to load than a file that has already been loaded before (if flash has a memory!)

Essentially i am asking, Does flash remember files it has previously loaded, in which case massively reducing loading times. EG If i was to load a 2MB picture, would it load any quicker the second time i loaded it?

Cheers

Flash In Memory
Have been wondering for some time now why flash stores values in memory 8 times what is expected. By this I mean if a variable was supposed to hold say a time, 2 seconds, the value stored in memory would be 16. Any particular reason for this ?

Flash With Memory ?
Hello !

I would like to make a screensaver with posibilitys to make
notes like 3M post-it notes, the flash file should "remeber"
the input that the user writes.

Is this possibel ??!!

I have the tools to make screensaver in Flash, but how to make such
a flash file ??

Thanks
Swed

Flash With Memory ?
Hello !

I would like to make a screensaver with posibilitys to make
notes like 3M post-it notes, the flash file should "remeber"
the input that the user writes.

Is this possibel ??!!

I have the tools to make screensaver in Flash, but how to make such
a flash file ??

Thanks
Swed

[help] Flash Memory?
Okay, hopefully this problem makes sense and I'm not just being stupid haha

I have a flash document on my website and only users that are logged in can see this flash file.

Inside this flash file I can a "tutorial" MC that shows up when the flash file loads.
This MC can be closed and then everything inside the flash file can be viewed.

What I need to happen is that if the user has viewed this flash file before (it has been opened at some stage while they were logged in) then the "tutorial" mustn't show up.

So basically the "tutorial" MC must only be visible the first time they open that flash file.
Is this possible?

How do I script it so that the file knows if this user has been here before. I'm so stumped by this.

I would really appreciate any help or tips.

Thanks a million!

Flash With Memory ?
Hello !

I would like to make a screensaver with posibilitys to make
notes like 3M post-it notes, the flash file should "remeber"
the input that the user writes.

Is this possibel ??!!

I have the tools to make screensaver in Flash, but how to make such
a flash file ??

Thanks
Swed

[help] Flash Memory?
Okay, hopefully this problem makes sense and I'm not just being stupid haha

I have a flash document on my website and only users that are logged in can see this flash file.

Inside this flash file I can a "tutorial" MC that shows up when the flash file loads.
This MC can be closed and then everything inside the flash file can be viewed.

What I need to happen is that if the user has viewed this flash file before (it has been opened at some stage while they were logged in) then the "tutorial" mustn't show up.

So basically the "tutorial" MC must only be visible the first time they open that flash file.
Is this possible?

How do I script it so that the file knows if this user has been here before. I'm so stumped by this.

I would really appreciate any help or tips.

Thanks a million!

Memory Of Flash
Allright, here i go...

I am making a section of a website and it's all scripted, about 800 lines of codes. I don't say that it's right to do that, but, i wanted to try.... Anyway i use alot of oblect, variables, arrays etc... even if i delete them when i don't need them anymore, i might miss 1 or 2 (hahaha).

I know that kepp them in memory. This section is attached via attachMovie... when i don't need the section anymore, i just do a remove movieclip but that does'nt do what i want.

Is there a function in flash, that if i remove a clip, from the stage, every variable, array, mc, object...in that clip is also deleted ?

If i want to accelerate flash or don't make it lag, it would be great..

Any idea? please share,

thx

How Can I Allocate More Memory To Flash?
I saw the next message when I open a flash file(FLA).

There is not enough memory to open this scene. Your document
is not damaged and may be safely saved.
To increase availabe memory, close open documents or quit
and use the Get info command in the Finder to allocate
more memory to flash.


My question is how I can more memory to flash.
Where is the "Finder" and the "Get info command"?

Thanks in Advance.

Change Memory Available To Flash
I have been getting an error in FLash 5 that says I have insufficient memory to place a movie clip in my main timeline. It also says to quit Flash and use the Get Info command in the Finder to allocate more memory to Flash. My system has over 780MB RAM so I should be able to do this. I just don't know what the flippin Finder is, and where the Get Info command is either.

Can anyone answer this

Allocate More Memory To Flash.....
i can't seem to figure out how to allocate more memory to flash. i'm working on some video and it show's this error message about how i need to allocate more memory to flash.
it also said to goto finder and use the get info command. i really need some help..
thanks in advanced...

J

I Need More Memory Allocation To Flash
I can not publish my latest project because it has reached a size where upon publication I get the following.

"Error creating flash movie, there was not enough memory available"

This occures in both my flash MX and flash 5 versions........

How can I allocate more memory to flash? (both versions if there is a difference)

I am on a PC with 128 RAM ............

Another question as long as I am here. When publishing in MX I get a background hiss/popping when streaming sound, so I've been forced to save as Flash 5 and publish in my old program where the streaming sound comes out clear....
Any Ideas? Is this a bug in MX?

Thanks,,,,,

Flash Memory Problem
Can anyone help me. I am trying to open a file in flash mx
and the following error appeared.

"there is not enough memory to open this scene. You document is not damaged and may be safely saved.
To increase available memory, close open documents or quit
and use the get info command in the finder to allocate more
memory to flash."

My computer is a P4 at 1.6Ghz and 512MB RAM and i haven't anything open besides flash. I tries to change the virtual memory but it did work. And what the hell is the get info
command in the Finder??

Flash Player Memory
Hello,

I am trying to build a photography site with pictures loaded individually as movies - what is a reasonable max size of total movies loaded into the player so as not to detract from the efficiency or speed of playback??

Osc

Flash Hasn’t Enough Memory? Please Help Me?
hi,

I have flash mx 2004 professional with the update installed. I have made a flash movie with it and it was all working perfectly when I tested it.

The following day after loading up my computer like I normal do. I went to open my flash movie to carry on working with it but I get the following message when I tried to open the file:

"There is not enough memory to open scene. Your document is not damaged and may be safely saved. To increase available memory close open documents or quit and use get info command in finder to allocate more memory to flash"

I have tried close all none essential programs down, but the same thing still happens. I have 1G! ddr memory so that has to be enough to run flash and a Intel P4 3G processor so I got enough processing power and more than enough hard drive space spare!

What’s wrong? I can open all my other flash file with out hassle but just this one movie will not open and I really need it!

It say's "To increase available memory close open documents or quit and use get info command in finder to allocate more memory to flash"

I have no idea how to do that! I am new to flash and have no idea how to increase the memory allocation to flash!

Can some one please help me by telling me what I can do or need to do to fix the problem and how to do it in a basic concept so I understand please?

Thank in advance =0)

Cheers

Flash Hasn’t Enough Memory? Please Help Me?
I have flash mx 2004 professional with the update installed on a PC. I have made a flash movie with it and it was all working perfectly when I tested it.

The following day after loading up my computer like I normal do. I went to open my flash movie to carry on working with it but I get the following message when I tried to open the file:

"There is not enough memory to open scene. Your document is not damaged and may be safely saved. To increase available memory close open documents or quit and use get info command in finder to allocate more memory to flash"

I have tried close all none essential programs down, but the same thing still happens. I have 1G! ddr memory so that has to be enough to run flash and a Intel P4 3G processor so I got enough processing power and more than enough hard drive space spare!

What’s wrong? I can open all my other flash file with out hassle but just this one movie will not open and I really need it!

It say's "To increase available memory close open documents or quit and use get info command in finder to allocate more memory to flash"

I have no idea how to do that! I am new to flash and have no idea how to increase the memory allocation to flash!

Can some one please help me by telling me what I can do or need to do to fix the problem and how to do it in a basic concept so I understand please?

Thank in advance =0)

Cheers

Flash Hasn’t Enough Memory? Please Help Me?
I have flash mx 2004 professional with the update installed on a PC. I have made a flash movie with it and it was all working perfectly when I tested it.

The following day after loading up my computer like I normal do. I went to open my flash movie to carry on working with it but I get the following message when I tried to open the file:

"There is not enough memory to open scene. Your document is not damaged and may be safely saved. To increase available memory close open documents or quit and use get info command in finder to allocate more memory to flash"

I have tried close all none essential programs down, but the same thing still happens. I have 1G! ddr memory so that has to be enough to run flash and a Intel P4 3G processor so I got enough processing power and more than enough hard drive space spare!

What’s wrong? I can open all my other flash file with out hassle but just this one movie will not open and I really need it!

It say's "To increase available memory close open documents or quit and use get info command in finder to allocate more memory to flash"

I have no idea how to do that! I am new to flash and have no idea how to increase the memory allocation to flash!

Can some one please help me by telling me what I can do or need to do to fix the problem and how to do it in a basic concept so I understand please?

Thank in advance =0)

Cheers

Flash MX Memory Usage
Do objects automatically get garbage collected when there's no more references to them, or do they just sit around until the script ends?

Flash Memory Game Help
how could i make a memory game like this one

http://pbskids.org/caillou/games/memory/index.html

I just want it so when you choose a correct match then it will say at the bottom of the screen *whoo hoo* or whatever

Flash Memory Game
how could i make a memory game like this one

http://pbskids.org/caillou/games/memory/index.html

I just want it so when you choose a correct match then it will say at the bottom of the screen *whoo hoo* or whatever

Increasing The Memory In Flash MX
how do I increase the Virtual Memory in flash Mx?

Memory Size For Flash Mx?
Hi, I am using a Powerbook G4 os 10.3.3 with 1.5 GHz and 512 MB DDR SDRAM.

Flash MX is a little slow at the moment, What is the right amount of memory to give to this program?

At the moment it is on minimum 64000 KB

Preffered 128000 KB



Thanks for your help

Flash Player Memory
I created a movie that is about 2 minutes long and has an audio file playing all throughout it, as well as some images popping up. The projector file is about 5 MB. It runs fine on some machines but on others that are slightly older the audio skips.

The weird thing is, on one of these older machines, I accidentally double clicked the exe file twice...causing two instances of flash player to run. I quickly closed one of them and realized the remaining one seemed to now play without skipping.

So I started wondering if Flash Player automatically allocates a certain amount of memory for itself and by opening 2 and then closing 1 I got twice the allocated memory. Does anyone know if this could be true and how much memory Flash Player 7 allocates? And also is there a way to allocate more?

Giving Flash More Memory
When i go to publish a mp3 file I get a message about Flash is out of memory. How do you give flash more memory? I am using windows 98. I cant seem to find out ho wto do this. any help would be great.
thanks

Flash MX 04 Runs Out Of Memory?
So, basically I get an error whenever I try to export a movie (very large one, with a couple of embedded vidoes).

The problem is that the export option hangs for a while and then I get an error telling me the operation could not be completed because there was not enough memory. Now I'm wondering what's wrong, I left a lot of virtual memory in additioin to a gig of actual ram.

I probably wont be able to figure it out and so I am wondering how to have a button load a new movie when clicked.. sort of like when you have different scenes.. and you link a button... with action script and it can go to a certain frame or scene. I was wondering if I could do that with an external movie (note I would also like a back option/button to go back a scene and forward).

Does anyone know how to do this? Thanks


I am thinking this type of linking is possible and would appriciate it for those who help but I am just wondering what could be done when linking scenes was not really an option?

I also had a question on flash's new way of exporting movies.. is there anyway of doig it frame by frame like before, the new way is just not what I need right now.

Memory Usage By Flash
i building a appliction using flash mx and swf studio 3.1.
i have problem with memory usage that build up , slow down the computer and causing bugs...
I solve this by minimize and maximize of the appliction, by really like a way to tell my flash application what is memory usage of that app.
any one know a way to do that?

thanks
kuller

Flash 6 Memory Usage
Hey guys and gals, Does flash 6 have any type of memory control?

I have an app that is dynamicly loading pictures externally using .loadMovie and when I want to goto the next picture, I .unloadMovie the current picture and .loadMovie the next one. This does not seem to remove the old picture out of memory because I hit an *out of memory* error when I hit my 1.1meg limit when more than 1.1 meg worth of pictures have been loaded. (not at one time)

Any Ideas?

EDIT: I would also like to know if any newer flash versions have any kind of memory control if flash 6 doesnt.

Flash 8 Memory Usage
hi there, I created a flash screen presentation of my portfolios (flash 8 pro) and noticed that the memory usage is pretty high.

To give you an overview of what's happening, in the beginning there's a short intro (memory usage bout 20mb), then it transitions into the main menu screen where there are buttons to jump to diff. parts of the presentation and a main animation, (nearly the whole part of the animation when it's running, memory goes up to bout 30-40mb, then when it's near the end, it jumps to bout 100-130mb+, if IIRC)

When i click on a button to go the the main collection portion of the presentation, memory usage jumps again to a whopping 220-250mb+ region and when I continue to navigate to other parts it goes up to nearly 300-320mb and that's the max it goes.

Now I have a lot of ram in my system so I didn't notice anything, I was told this by a friend of mine who was looking at my stuff on his PC and that's when i realised flash is using a lot of RAM.

2 questions, is this normal and is there anyway to make it utilize less RAM?

Thanks in advance for any help rendered and have a nice day!

Best regards,
Wen

[F8] Flash Memory Optimization
I need to optimize this code to make it less processor intensive...
it;s killing the application when it runs...

//"leaf" is a movieclip with 9 frames with different leaves each frame

//first frame of actual movieclip "leafMaker"
#include "mc_tween2.as"

fallDistance = 25;
fallSpeed = 3;
spawnRate = 1;
angleVariance = 45;
gravity = 45;
totalLeafTypes = 9;

var depth = 1;
var spawnNum = 0;
var spawnTotal = spawnRate;

this.onEnterFrame = function(){
if((spawnNum++)!=spawnTotal)return;
spawnTotal+=spawnRate;

this._parent.attachMovie("leaf","leaf"+ this.depth , this.depth++)
this._parent["leaf"+ this.depth ].gotoAndStop(Math.round(Math.random()*totalLeafTyp es))
this._parent["leaf"+ this.depth ]._rotation = this._parent.leafMaker._rotation*Math.PI;
this._parent["leaf"+ this.depth ]._x = this._parent.leafMaker._x;
this._parent["leaf"+ this.depth ]._y = this._parent.leafMaker._y;

myRandomAmt = ((Math.round(Math.random()*angleVariance)) - (angleVariance/3));

myAngle = (this._parent.leafMaker._rotation + myRandomAmt) * Math.SQRT2/1.745329E-002;
myX = this._parent.leafMaker._x + (Math.cos(myAngle)*fallDistance);
myY =this._parent.leafMaker._y + (Math.sin(myAngle)*fallDistance);

this._parent["leaf"+ this.depth ].roundedBezierSlideTo( myX, myY-gravity,myX,myY+gravity,fallSpeed);
//this._parent["leaf"+ this.depth ].xSlideTo(myX,fallSpeed);
//this._parent["leaf"+ this.depth ].ySlideTo(myY,fallSpeed)
this._parent["leaf"+ this.depth ].alphaTo(0,fallSpeed)
};

Thanks..

Flash Consumes Memory
Hi!

I have a fairly big swf file, mainly consisting of a sequence of images. The file itself is about 14MB. However, when I run it in a browser, it consumes 300MB of memory. Even though it caches the images and so on, 300MB memory consumption seems like a major overkill. I plan to redo the image sequence to a more low-quality version, but still can't see why the browser needs to consume such extreme amounts of memory. Any ideas why this happens?

- Peder -

How Is Flash Held In Memory
In the past my websites usually consisted of 2 frames, with the top frame holding the logo, menu, and etc and built in flash, and the bottom frame with the asp, html pages. Due to the recent flaw in XP, frames are not working right for me, and i am forced to build nonframe sites.

My question: Once the .swf has been loaded onto a page, when the user goes to a new page that references the same .swf (in file name and location) does flash player re download the complete swf or does it simply pull from the Internet Explorer temp files located on the local computer? I know i should know this but I've never read up on it.

Thanks!

Does Flash Leak Memory?
Does flash need its variables and bitmap data variables set to null after it is finished using them all ? I ask because i know when writing AJAX and other scripting languages need variables set to null or some other method in order to combat memory leaks.....does flash leak memory like those other scripting languages? ....what is the best steps when writing code to ensure flash doesn't leak memory ?



PHP Code:



function clearit(){
    trace("yes");
    snapshot1 = null;
    snapshot2 = null;
    j = null;
    bitmap_mc1 = null;
    bitmap_mc2 = null;
    output_vid = null;
}

Flash Memory Leak
is there any way around the flash memory leak?

Copyright © 2005-08 www.BigResource.com, All rights reserved