Rename 'bilinear' scaling filter to 'trilinear'
authorEmmanuele Bassi <ebassi@linux.intel.com>
Fri, 16 Mar 2012 12:05:11 +0000 (12:05 +0000)
committerEmmanuele Bassi <ebassi@linux.intel.com>
Fri, 16 Mar 2012 12:33:40 +0000 (12:33 +0000)
commitae554a5061b64ee7b4d157f91467c19ce74495fa
tree9aaf46406a952396a73a099a4cb1999baa60bb08
parentb44290c4369e86f8fff19bf4ccbb0cb7a5268cdc
Rename 'bilinear' scaling filter to 'trilinear'

Yes, it's not really the proper GL name for a linear-on-every-axis of a
texture plus linear-between-mipmap-levels minification filter, but it
has three redeeming qualities as a name:

  - LINEAR_MIPMAP_LINEAR sucks, as it introduces GL concepts like
    mipmaps in the API naming, while we're trying to avoid that;
  - people using GL already know what 'trilinear' means in this context
    without going all Khronos on their asses;
  - we're using 2D textures anyway, so 'linear on two axes and linear
    between mipmap levels' can be effectively approximated to
    'trilinear'.

I mean, if even the OpenGL official wiki says:

  Unfortunately, what most people think of as "trilinear" is not linear
  filtering of a 3D texture, but what in OpenGL terms is GL_LINEAR mag
  filter and GL_LINEAR_MIPMAP_LINEAR in the min filter in a 2D texture.
  That is, it is bilinear filtering of each appropriate mipmap level,
  and doing a third linear filter between the adjacent mipmap levels.
  Hence the term "trilinear".
                -- http://www.opengl.org/wiki/Texture

then the horse has already been flogged to death, and I don't intend to
be accused of necrophilia and sadism by flogging it some more.

Prior art: every single GL tutorial in the history of ever;
CoreAnimation's scaling filter enumerations.

If people want to start using 1D or 3D textures they they are probably
going to be using Cogl API directly, and that has the GL naming scheme
for minification and magnification filters anyway.
clutter/clutter-actor.c
clutter/clutter-enums.h
clutter/clutter-paint-nodes.c
tests/interactive/test-canvas.c
tests/interactive/test-image-box.c