Flasher Archive
[Previous] [Next] - [Index] [Thread Index] - [Previous in Thread] [Next in Thread]
| Subject: | onClipEvent and memory use |
| From: | Helen Triolo |
| Date: | Sun, 04 Mar 2001 02:49:52 -0000 |
I've been curious about how both duplicating movieclips and using
onClipEvent(enterFrame) affect memory use, so I did some tests.
I ran 3 movieclips which have onClipEvent(enterFrame) routines in them:
#1 has one clip whose properties get altered, #2 has a clip that's
duplicated 100 times and then all are deleted and it begins again, and
#3 duplicates a new clip randomly every 20-30 frames, sets various
properties and deletes it after about 100 frames (all the while
generating new clips every 20-30 frames and setting their properties).
All of the clips have a button that turns a variable on/off -- the
onClipEvent checks this variable and if it's off, it doesn't do anything
else (but Flash still has to execute the onClipEvent(enterFrame) every
frame to check that variable). This is what the CPU use looked like
(roughly):
% used after: 1min 2min 3min 4min with button turned off on all 3
---- ---- ---- ---- -------------------------------
IE5.5 20 35 40 50 0 (amazing)
NN4.7 50 55 60 65 35
In IE, if I turned clip 1 or 2 back on, it hardly mattered, but turning
on #3 made the CPU jump up immediately to 50% again. In Netscape,
turning 1 or 2 back on bumped the CPU use back to 40%, and turning #3 on
made it 70%. So it obviously does pay to give the user the option to
"turn off" duplicating if possible, so your movie doesn't swallow their
CPU whole. For reference, I'm running W2k on an AMD Duron overclocked
to 800MHz w/256M memory. Ok, that's the end of my little Saturday night
FYI.
Regards,
Helen
-------------------------------------------------------------------
1240 Flash Answers from 424 people: http://i-technica.com/flashlist
[Previous] [Next] - [Index] [Thread Index] - [Next in Thread] [Previous in Thread]

