[Webkit-unassigned] [Bug 75779] [Texmap] Move surface management from TextureMapperNode to TextureMapper

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Jan 8 15:32:53 PST 2012


https://bugs.webkit.org/show_bug.cgi?id=75779





--- Comment #9 from Noam Rosenthal <noam.rosenthal at nokia.com>  2012-01-08 15:32:53 PST ---
(In reply to comment #6)
> btw, why doesn't the textureMapperNode have a ref to the textureMapper? instead of passing it thru the options?
Because TextureMappers might be changed... they're tied to the painting context. You shouldn't really use TexftureMapper, except for during paint.

> 
> > Source/WebCore/platform/graphics/texmap/TextureMapperNode.cpp:28
> > +
> > +PassRefPtr<BitmapTexture> TextureMapper::acquireTextureFromPool(const IntSize& size)
> > +{
> 
> Why make this part of the TextureMapper? And not a singleton TexturePool? Is it not singleton in nature?
No, it has to be cleaned up together with other TextureMapper-bound resources.

> 
> > Source/WebCore/platform/graphics/texmap/TextureMapperNode.cpp:51
> > +        // We choose the smallest texture that is equal or larger than the required size.
> > +        if ((textureSize.width() < size.width() || textureSize.height() < size.height())
> > +            || (newTextureSize.width() >= size.width()
> > +                && newTextureSize.height() >= size.height()
> > +                && newTextureSize.width() * newTextureSize.height() <= textureSize.width() * textureSize.height())) {
> > +            continue;
> > +        }
> 
> Couldnt this be styled a bit nicer?
Will do.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list