[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gzz-commits] gzz ./TODO gfx/demo/papertest.py gfx/libpaper/p...
From: |
Tuomas J. Lukka |
Subject: |
[Gzz-commits] gzz ./TODO gfx/demo/papertest.py gfx/libpaper/p... |
Date: |
Fri, 25 Oct 2002 09:50:44 -0400 |
CVSROOT: /cvsroot/gzz
Module name: gzz
Changes by: Tuomas J. Lukka <address@hidden> 02/10/25 09:50:44
Modified files:
. : TODO
gfx/demo : papertest.py
gfx/libpaper : papermill.py
Log message:
render to tex
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/TODO.diff?tr1=1.325&tr2=1.326&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gfx/demo/papertest.py.diff?tr1=1.43&tr2=1.44&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/gfx/libpaper/papermill.py.diff?tr1=1.57&tr2=1.58&r1=text&r2=text
Patches:
Index: gzz/TODO
diff -u gzz/TODO:1.325 gzz/TODO:1.326
--- gzz/TODO:1.325 Fri Oct 25 08:10:31 2002
+++ gzz/TODO Fri Oct 25 09:50:41 2002
@@ -15,17 +15,18 @@
- make callgl complain on broken stuff such as
the string "%(texid)s" in place of a number !!!!
ARGH ARGH ARGH
- + [GI03] update NV20/NV25 version of libpaper. Need HILO offset
textures.
- + [GI03] libpaper NV2x combined passes
+ - fix turbulence texture
+ + [GI03]libpaper NV2x combined passes
+ [GI03] think about modeling textures
+ script to save 100 textures every day
- jvk,marke:
- + [GI03] paper experiments
tjl, jvk:
- paper: small high-frequency components
+ [GI03] standard GL implementation of irregu
- [GI03] - one-pass edge impl
- [GI03] - think more about shape
+ - better sawnoise texture: less intermediate freqs
+ - renderable
+ - texture shading
+ - curved edges
+ - puzzle view
[GI03] - pieces
[GI03] - soft shadows of irregus- ?!?!?! Need algorithm...
- only very approximate needed
@@ -128,6 +129,8 @@
- dicing only when needed
- fill with fading color
- soft shadows
+ - polygon puzzle view
+ - shader for fBm for irregu
- PP [deadline 5.11]
- refactor
- make it work again
@@ -218,6 +221,8 @@
(current implementation is in gfx/libpaper/texcache.py)
+ for Documentation/TechReports/GzzTech, figure out how we can
use our bibtex file (in Documentation/Manuscripts) for citations.
+ - cleanup: remove x, y, z from HorizText: unnecessary now.
+ same for other coord-like things in renderables.
0.8alpha5: saving, loading etc. with mediaserver useful; tests
deetsay:
@@ -512,6 +517,8 @@
tjl,jvk:
- character indices in texture
+jvk,marke:
+ + [GI03] paper experiments
jvk:
- paper:
Index: gzz/gfx/demo/papertest.py
diff -u gzz/gfx/demo/papertest.py:1.43 gzz/gfx/demo/papertest.py:1.44
--- gzz/gfx/demo/papertest.py:1.43 Fri Oct 11 10:03:13 2002
+++ gzz/gfx/demo/papertest.py Fri Oct 25 09:50:43 2002
@@ -83,8 +83,11 @@
passmask = [1,1,1,1]
-def getpaper(seed):
- pap = ThePaperMill().getPaper(seed, passmask=passmask)
+def getpaper(seed, optimized=0):
+ if optimized:
+ pap = ThePaperMill().getOptimizedPaper(seed, w, passmask=passmask)
+ else:
+ pap = ThePaperMill().getPaper(seed, passmask=passmask)
#print "Pq: ",seed
return GLRen.createPaperQuad(pap, -1, -1, +1, 1, 0)
@@ -109,9 +112,12 @@
self.seed = 0
self.pq = None
+
+ self.optimized = ["not", "opt", "both"]
def initpaper(self):
self.pq = getpaper(self.seed)
+ self.opq = getpaper(self.seed, optimized = 1)
def key(self, k):
oldseed = self.seed
@@ -125,6 +131,8 @@
AbstractUpdateManager.setNoAnimation()
if k == "v":
self.seed = rng.nextInt(2000000000)
+ if k == 'o':
+ rotatelist(self.optimized)
if oldseed != self.seed:
self.pq = None
@@ -150,23 +158,46 @@
# vs.put(rectangle((1, 0.2, 0.4)), "re", 10, 100, 100, 300, 100)
- w2 = .5 * size.width
- h2 = .5 * size.height
+ w = size.width
+ h = size.height
- cs1 = vs.coords.affineCoordsys(0, 10, w2, h2, w2, 0, 0, h2)
+ cs1 = vs.coords.affineCoordsys(0, 10, 0, 0, w, 0, 0, h)
scale = zoom[0] / paperzoom[0]
- cs2 = vs.coords.affineCoordsys(0, 0, 0, 0, scale / w2, 0, 0, scale / h2)
+ cs2 = vs.coords.affineCoordsys(0, 0, 0, 0, scale / w, 0, 0, scale / h)
+
+ cs1left = vs.coords.ortho(cs1, 0, 0, 0, .5, 1)
+ cs1right = vs.coords.ortho(cs1, 0, .5, 0, .5, 1)
+
+ cs2left = vs.coords.ortho(0, 0, 0, 0, scale / w * 2, scale / h)
+ cs2right = vs.coords.ortho(0, 0, -1, 0, scale / w * 2, scale / h)
vs.matcher.add(cs1, "1")
vs.matcher.add(cs2, "2")
+ vs.matcher.add(cs1left, "1l")
+ vs.matcher.add(cs2left, "2l")
+
+ vs.matcher.add(cs1right, "1r")
+ vs.matcher.add(cs2right, "2r")
+
pscale = zoom[0]
#print "Seed: ",self.seed," pq ",self.pq
- vs.map.put(self.pq, cs1, cs2)
+ if self.optimized[0] == "not":
+ print "NOT"
+ vs.map.put(self.pq, cs1, cs2)
+ elif self.optimized[0] == "opt":
+ print "OPT"
+ vs.map.put(self.opq, cs1, cs2)
+ elif self.optimized[0] == "both":
+ print "BOTH"
+ vs.map.put(self.pq, cs1left, cs2left)
+ vs.map.put(self.opq, cs1right, cs2right)
+ else:
+ print "ARGH ",self.optimized
- cs3 = vs.coords.affineCoordsys(0, 0, 0, 0, h2, 0, 0, h2)
+ cs3 = vs.coords.affineCoordsys(0, 0, 0, 0, h/2, 0, 0, h/2)
vs.matcher.add(cs3, "txt")
putText(vs, cs3, str(self.seed), color=(0,0,0), x=0, y=.12, h=.2)
@@ -353,3 +384,4 @@
if not globals().has_key("window_resized"):
window_resized = 1
w.setLocation(0,0,1200,900)
+
Index: gzz/gfx/libpaper/papermill.py
diff -u gzz/gfx/libpaper/papermill.py:1.57 gzz/gfx/libpaper/papermill.py:1.58
--- gzz/gfx/libpaper/papermill.py:1.57 Wed Oct 23 12:55:20 2002
+++ gzz/gfx/libpaper/papermill.py Fri Oct 25 09:50:44 2002
@@ -138,8 +138,8 @@
pap.repeat = rootrep
return pap
- def getOptimizedPaper(self, seed, w):
- pap = self.getPaper(seed)
+ def getOptimizedPaper(self, seed, w, passmask = [1, 1, 1, 1, 1, 1, 1]):
+ pap = self.getPaper(seed, passmask)
# Now, we render a region.
v = pap.repeat._getSTVectors()