[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Public WebGL] WebGL NPOT texture support

On Nov 17, 2011, at 5:51 PM, Mo, Zhenyao wrote:

> On Thu, Nov 17, 2011 at 5:38 PM, Glenn Maynard <glenn@zewt.org> wrote:
> On Thu, Nov 17, 2011 at 8:20 PM, Mo, Zhenyao <zhenyao@gmail.com> wrote:
> 1. Require that the context by default act as if there is no NPOT support.
> 2. If context.getExtension("...texture_non_power_of_two") is called, and the extension is supported, enable NPOT support.  I suppose the function does not need to return anything, or could return an empty interface.
> 3. The context may now use NPOT features.
> People are objecting exactly what you just proposed.  It's never a plan to incorporate NPOT into core webgl 1.0.
> He didn't propose adding it to the core, he proposed adding it as an extension.
> I understand, but his assumption is that people were objecting adding NPOT to the core, that's why he proposed adding it as an extension.  So I clarify that adding to the core is never a plan.

NPOT is in the core. It has always been in the core. The only things missing (which is what the extension adds) is the ability to mip-map and repeat such textures.

Aside from the general argument about whether it's appropriate to add extensions without universal support, there's another argument against OES_texture_npot. It in particular has the danger of fragmenting WebGL content. It's a feature that makes it a little easier for an author to write certain types of content. In some cases, an author might see that this extension is available on the platform she happens to be using and therefore turns it on and uses it to make it easier to write the content. Now this content won't work at all on any platform without that support and we have fragmentation.

It would be useful for authors to chime in about the downside of not having the capability of tiling or mip-mapping npot textures. Why not make any texture you want to tile into a power-of-two? Is it a space savings issue? An image quality issue? What are the cases where mip-mapping an NPOT texture is important?

I ask this because, if it's a matter of convenience, it really seems like it would damage interoperability in WebGL and I think that is a very bad thing at this stage.

If you compare that with a more major feature, like geometry shaders, then I think the response is different. Geometry Shaders is a major feature and there is no way an author could create a fallback in their content that would do many of the things they can do. So someone using an extension like this would be targeting the platforms that support it and no others. Or maybe the author would create completely separate, simpler content for other platforms, so everyone was included in some way.

I'm much less against this sort of extension because it's enabling WebGL to go in completely new directions, and allows authors that they have no chance of doing any other way.

Anyway, I just wanted to express that point of view, FWIW...


You are currently subscribed to public_webgl@khronos.org.
To unsubscribe, send an email to majordomo@khronos.org with
the following command in the body of your email:
unsubscribe public_webgl