Re: waste of RAM/bug in render.c?
Wolfgang Spraul <[email protected]>
| Newsgroups | gmane.comp.video.graphicsmagick.core |
|---|---|
| Organization | Q AG |
| Message-ID | <[email protected]> |
> My question was about the 'length' calculation in lines 2031-2047.
Sorry, I got confused with all the numbers...
The lines I'm talking about are magick/render.s:2731-2747:
alpha=bounds.x2-bounds.x1;
beta=bounds.y2-bounds.y1;
radius=sqrt(alpha*alpha+beta*beta);
length=(size_t) (2*ceil(MagickPI*radius)+6*BezierQuantum+360);
if (i >= (long) (number_points-length))
{
number_points+=length;
MagickReallocMemory(primitive_info,
number_points*sizeof(PrimitiveInfo));
if (primitive_info == (PrimitiveInfo *) NULL)
{
ThrowException3(&image->exception,ResourceLimitError,
MemoryAllocationFailed,UnableToDrawOnImage);
break;
}
}
Wolfgang
-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html