PDA

View Full Version : AVISynth and memory usage


neily
11th October 2002, 23:14
Hi,

I know that the question of AVISynth gobbling up memory has been raised on a few occasions before, and the normal advice is to use SetMemoryMax. But I can't help feeling that something is awry. Loading/executing scripts seems to lead to an ever increasing memory usage. This occurs in VDub as well as other apps. As an example, using VDub, and taking four files:

1. 'Long avi' - 352x288 HuffAVI 150,000 frames.
2. 'Long avs' - above AVI loaded with 'SegmentedAVISource'.
3. 'Small avi' - 16x16 uncompressed AVI, 5 frames, no sound.
4. 'Small avs' - above AVI loaded with 'AVISource'.

Looking at the memory usage of VDub when successively loading and playing these files gives:

Figures are in k and are open/play

Open VDub - 5,652k
Small avi - 5,676/5,824
Long avi - 6,436k/17,148
Small avi - 6,164/6,172
Small avs - 7,748/7,752
Long avs - 18,556/30,296
Small avs - 13,828/13,836
Long avs - 23,652/35,848
Small avs - 23,084/23,132
Long avs - 29,092/40,452
Small avs - 27,700/27,814
Long avs - 33,764,45,960
Small avs - 33,200/33,404
Long avs - 39,264/51,460
Small avi - 38,400/38,632
Long avs - 44,772/56,968

As you can see, each time an AVS is loaded, memory usage increases. Surely this can't be right. The same sort of thing happens whether SetMemoryMax is used or not. These figures are with SetMemoryMax(8).

Any comments?

Bionic-Badger
13th October 2002, 01:47
Speaking of memory, is there any real benefit of giving AVIsynth a lot of memory (like 512 megs) to work with?

-Bionic-Badger-