[OpenJDK 2D-Dev] 6603887: Where are transparent areas filled with bgColor?
Jim.A.Graham at Sun.COM
Fri Sep 28 15:05:44 PDT 2007
Clemens Eisserer wrote:
> however on the other side it maybe uses more memory (haven't looked at
> the struct) so its a space/readability tradeof.
> Well but most time people prefer their code over others so I thought
> I am not in a good position to discuss this ;)
I think there are other areas where we waste even more memory than that
would account for - if we were worried about memory consumption at that
level. If someone wanted to go on a field day at the cost of our code
readability then the X11SurfaceData object could lose about 20 bytes
easily. It could lose another 48 bytes just by turning the rarely used
JDgaSurfaceInfo into a pointer, or perhaps make it an optional trailing
part of the structure for devices that don't have DGA.
> What do you think about using the boolean approach and masking the
> pixel-value in rgbToPixel()? Could it break things or limit
I'm not sure we need to worry about masking the pixel value at this
point if we use the boolean approach...
More information about the 2d-dev