gzz-commits
[Top][All Lists]
Advanced

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

[Gzz-commits] gzz Documentation/Manuscripts/Irregu/Irregular_...


From: Janne V. Kujala
Subject: [Gzz-commits] gzz Documentation/Manuscripts/Irregu/Irregular_...
Date: Wed, 13 Nov 2002 06:33:38 -0500

CVSROOT:        /cvsroot/gzz
Module name:    gzz
Changes by:     Janne V. Kujala <address@hidden>        02/11/13 06:33:38

Modified files:
        Documentation/Manuscripts/Irregu: Irregular_shape_profiles.html 
        gfx/demo       : irregu3.py 
        gfx/libtexture : irreguedge.texture 

Log message:
        try irregu shader profile scaling exponents

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/Documentation/Manuscripts/Irregu/Irregular_shape_profiles.html.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gfx/demo/irregu3.py.diff?tr1=1.48&tr2=1.49&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gfx/libtexture/irreguedge.texture.diff?tr1=1.2&tr2=1.3&r1=text&r2=text

Patches:
Index: gzz/Documentation/Manuscripts/Irregu/Irregular_shape_profiles.html
diff -u gzz/Documentation/Manuscripts/Irregu/Irregular_shape_profiles.html:1.3 
gzz/Documentation/Manuscripts/Irregu/Irregular_shape_profiles.html:1.4
--- gzz/Documentation/Manuscripts/Irregu/Irregular_shape_profiles.html:1.3      
Sat Nov  2 09:51:36 2002
+++ gzz/Documentation/Manuscripts/Irregu/Irregular_shape_profiles.html  Wed Nov 
13 06:33:37 2002
@@ -99,7 +99,7 @@
           </td>
           <td valign="top">Up to 1D texture size<br>
           </td>
-         <td valign="top">No (thick border looks bad)<br>
+         <td valign="top">Yes, but as the scaling exponent grows from 0 to 1, 
the edge width becomes closer to constant displacement; also, non-linear 
scaling of thick edge may have visible spikes in derivative discontinuities<br>
          </td>
         </tr>
         <tr>
Index: gzz/gfx/demo/irregu3.py
diff -u gzz/gfx/demo/irregu3.py:1.48 gzz/gfx/demo/irregu3.py:1.49
--- gzz/gfx/demo/irregu3.py:1.48        Sat Nov  9 13:32:52 2002
+++ gzz/gfx/demo/irregu3.py     Wed Nov 13 06:33:37 2002
@@ -4,13 +4,13 @@
 
 ripple_scale = .25
 texsize = 256
-edgetexsize = 1024
+edgetexsize = 4096
 lodbias = 0
 edgelodbias = 0
 texscale = 1
 use_texture = 0
 
-scalings = [ "const", "sqrt", "linear" ]
+scalings = [ "0", ".5", "1" ]
 scaling = scalings[0]
 
 matrices = [ "1 0 0 0  0 1 0 0  0 0 1 0  0 0 0 1",
@@ -226,7 +226,9 @@
              ["line_width", "2",
               "col0", "1",
               "col1", "1",
-              "col2", "0"]],
+              "col2", "0",
+              "refsize", "16", # tex_scale * refsize
+              "scaling", str(scaling)]],
             shade_all_levels = 1)
         
         texenv = """
@@ -450,7 +452,7 @@
 
 
     print "Using", angles, "precomputed slicing angles"
-    print "Using", scaling, "scaling"
+    print "Using", scaling, "scaling exponent"
 
     global reinit
     reinit = 1
Index: gzz/gfx/libtexture/irreguedge.texture
diff -u gzz/gfx/libtexture/irreguedge.texture:1.2 
gzz/gfx/libtexture/irreguedge.texture:1.3
--- gzz/gfx/libtexture/irreguedge.texture:1.2   Mon Oct 28 09:19:46 2002
+++ gzz/gfx/libtexture/irreguedge.texture       Wed Nov 13 06:33:38 2002
@@ -9,6 +9,10 @@
     FPARAM(bias, 0);
     FPARAM(scale, 1);
     FPARAM(line_width, 2);
+    FPARAM(refsize, 256);
+    FPARAM(scaling, 0);
+
+    line_width *= pow(height / refsize, scaling);
 
     float col[3][4] = {
         { 1, 1, 1, 1 },




reply via email to

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