Anisotropic texturing overhaul and fixes to address some artifacts we'd noticed.

(a) Proper computation of the major axis on which to place the samples;
    previously, it was assuming the major axis was the same as the larger
    derivative.  That's true if the derivs are orthogonal in texture st
    space, but not for arbitrary angles.  Solving this fixes a number of
    artifacts, that tended to be only visible with added "blur", but were
    pretty ugly with blur discontinuities.
(b) Adjusted the strategy we were using for "conservative" dealing with
    extreme anisotropy to get a better visual result.
(c) Eliminate a 2x error where we were not distributing the samples far
    enough along the line.
(d) Apply Gaussian weights to the samples.

Along the way, I added some new tests and testtex options to help with the 
debugging.  You may notice some code (that doesn't run by default) at the end 
of texturesys.cpp that generates sets of derivatives randomly, then makes 
graphs plotting the derivatives, the ellipse that is fit to them, and the 
sample positions and weights.  This was really important to my debugging this 
and convincing myself that I finally have it right.


You can merge this Pull Request by running:

  git pull https://github.com/lgritz/oiio lg-texblur

Or you can view, comment on it, or merge it online at:

  https://github.com/OpenImageIO/oiio/pull/417

-- Commit Summary --

* New texture tests
* IC/TS attribute 'substitute_image' lets you force all texture refs to a 
single image.
* oiiotool --fill
* New testtex options: --aniso, --stblur
* safe_sqrtf clamps to avoid NaN
* Anisotropic texturing overhaul and fixes.
* Update testsuite reference images

-- File Changes --

M src/CMakeLists.txt (2)
M src/doc/imagecache.tex (8)
M src/doc/texturesys.tex (3)
M src/include/fmath.h (9)
M src/libtexture/imagecache.cpp (12)
M src/libtexture/imagecache_pvt.h (1)
M src/libtexture/texture_pvt.h (26)
M src/libtexture/texturesys.cpp (445)
M src/oiiotool/oiiotool.cpp (56)
M src/testtex/testtex.cpp (28)
A testsuite/texture-blurtube/ref/out.exr (0)
A testsuite/texture-blurtube/ref/out.tif (0)
A testsuite/texture-blurtube/run.py (5)
M testsuite/texture-fat/ref/out.exr (0)
M testsuite/texture-filtersize/ref/out.exr (0)
M testsuite/texture-grid/ref/out.exr (0)
M testsuite/texture-overscan/ref/out.exr (0)
M testsuite/texture-skinny/ref/out.exr (0)

-- Patch Links --

  https://github.com/OpenImageIO/oiio/pull/417.patch
  https://github.com/OpenImageIO/oiio/pull/417.diff

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenImageIO/oiio/pull/417
_______________________________________________
Oiio-dev mailing list
[email protected]
http://lists.openimageio.org/listinfo.cgi/oiio-dev-openimageio.org

Reply via email to