gzz-commits
[Top][All Lists]
Advanced

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

[Gzz-commits] manuscripts/AniFont anifont.tex probe.mp


From: Tuomas J. Lukka
Subject: [Gzz-commits] manuscripts/AniFont anifont.tex probe.mp
Date: Tue, 30 Sep 2003 07:20:56 -0400

CVSROOT:        /cvsroot/gzz
Module name:    manuscripts
Branch:         
Changes by:     Tuomas J. Lukka <address@hidden>        03/09/30 07:20:56

Modified files:
        AniFont        : anifont.tex probe.mp 

Log message:
        The probe algorithm

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/manuscripts/AniFont/anifont.tex.diff?tr1=1.4&tr2=1.5&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/manuscripts/AniFont/probe.mp.diff?tr1=1.3&tr2=1.4&r1=text&r2=text

Patches:
Index: manuscripts/AniFont/anifont.tex
diff -u manuscripts/AniFont/anifont.tex:1.4 manuscripts/AniFont/anifont.tex:1.5
--- manuscripts/AniFont/anifont.tex:1.4 Tue Sep 30 06:46:18 2003
+++ manuscripts/AniFont/anifont.tex     Tue Sep 30 07:20:56 2003
@@ -49,7 +49,29 @@
 }
 \end{figure*}
 
-- ASSUMPTIONS: pixel/texel translation invariance, both in screen and 
texture-space
+- ASSUMPTIONS: pixel/texel translation invariance, both in screen and 
texture-space,
+  driver not detecting software and applying different rules, driver
+  not changing algorithm for screenshot images / moving images, ...
+
+- define separate texture $T_n$ for each mipmap level, with exactly one light
+  texel at that mipmap level, all other texels and mipmap levels middle gray(!)
+  (we define $T_n$ to be the 1x1 texture, $T_{n-1}$ to be the 2x2 texture etc.
+  Non-square mipmap hierarchies are a simple generalization)
+    
+    - gray so we see also if there are negative weights in the filter!
+
+- select the texture coordinates for a single-pixel quad where you want
+  to see contributions: $(s_0, t_0), (s_1, t_1), (s_2, t_2), (s_3, t_3)$.
+  In reality, only a triangle gets used so these should be linearly obtained
+  from three coordinates but it's still easier for a human to understand these
+  as quads
+
+- For each miplevel texture, render a one-pixel quad for each texel at that 
level,
+  with texture coordinates shifted by multiples of $1/s_n$ where $s_n$ is the
+  length of the mipmap side on level $n$.
+
+- Resulting image gives contribution from each texel on a mipmap level
+  to the final image, PROVIDED ASSUMPTIONS HOLD.
 
 
 - utility in our free software OpenGL libvob system
Index: manuscripts/AniFont/probe.mp
diff -u manuscripts/AniFont/probe.mp:1.3 manuscripts/AniFont/probe.mp:1.4
--- manuscripts/AniFont/probe.mp:1.3    Tue Sep 30 07:12:47 2003
+++ manuscripts/AniFont/probe.mp        Tue Sep 30 07:20:56 2003
@@ -25,9 +25,9 @@
 
 cornermeas = 5pt;
 
-def stlabel(expr x, y, side) =
-    (TEX("$\eqalign{(s_0 + " & (decimal x) & "/" & (decimal side) &",\cr " &
-       "t_0 + " & (decimal y) & "/" & (decimal side) &")}$" 
+def stlabel(expr ind, x, y, side) =
+    (TEX("$\eqalign{(s_"&(decimal ind)&"0 + " & (decimal x) & "/" & (decimal 
side) &",\cr " &
+       "t_"&(decimal ind)&"0 + " & (decimal y) & "/" & (decimal side) &")}$" 
     ) scaled .8)
 enddef;
 
@@ -43,19 +43,19 @@
                gridc(xoffs+x,yoffs+y,  1, -1) -- cycle;
 
            dotlabel.urt(
-               stlabel(x, y, side),
+               stlabel(0, x, y, side),
                gridc(xoffs+x,yoffs+y, -1, -1) 
                );
            dotlabel.ulft(
-               stlabel(x+1, y, side),
+               stlabel(1, x+1, y, side),
                gridc(xoffs+x,yoffs+y, 1, -1) 
                );
            dotlabel.lrt(
-               stlabel(x, y+1, side),
+               stlabel(2, x, y+1, side),
                gridc(xoffs+x,yoffs+y, -1, 1) 
                );
            dotlabel.llft(
-               stlabel(x+1, y+1, side),
+               stlabel(3, x+1, y+1, side),
                gridc(xoffs+x,yoffs+y, 1, 1) 
                );
            




reply via email to

[Prev in Thread] Current Thread [Next in Thread]