Page 1 of 1

CGapiSurface used as a mask Question

PostPosted: Jan 15, 2003 @ 6:15pm
by me2
CGapiSurface* mask = new CGapiSurface();
mask->CreateSurface(NULL,width,height);

mask->FillSurface
(NULL,RGB(0,alpha,0),NULL,NULL);


MyQuestion:
How much memory will be allocated for the mask?
size of (RGB)*width*height or
sizeof(G)*widht*height?
(the R and B component are 0)

Note that keeping memory only the G component of the surface is enough ...
[/code]

PostPosted: Jan 15, 2003 @ 11:56pm
by Hosed

PostPosted: Jan 17, 2003 @ 9:50am
by me2

PostPosted: Jan 18, 2003 @ 12:12am
by Johan
Basically it could.. But all mask operations would have to be modified. It also would mean very little performance gain.

PostPosted: Jan 20, 2003 @ 9:59am
by me2
So, shall we see it in the next version of GapiDraw?

I think that is worth to implement ...
or maybe implement a new CGapiMaskSurface class that would be memory optimized and some drawing methods using it ...
I prefer the first option
Of course, as you said, there would be other thing that would need touch ...