13 |
|
|
14 |
# Module pagespanview |
# Module pagespanview |
15 |
|
|
16 |
globalseedoffs = 0 |
globalseedoffs = -9 |
17 |
globalLOD = 0 |
globalLOD = 0 |
18 |
|
|
19 |
|
|
87 |
TexParameter TEXTURE_2D TEXTURE_WRAP_T REPEAT |
TexParameter TEXTURE_2D TEXTURE_WRAP_T REPEAT |
88 |
TexParameter TEXTURE_2D TEXTURE_MIN_FILTER LINEAR_MIPMAP_LINEAR |
TexParameter TEXTURE_2D TEXTURE_MIN_FILTER LINEAR_MIPMAP_LINEAR |
89 |
TexParameter TEXTURE_2D TEXTURE_MAG_FILTER LINEAR |
TexParameter TEXTURE_2D TEXTURE_MAG_FILTER LINEAR |
90 |
|
TexParameter TEXTURE_2D TEXTURE_MAX_ANISOTROPY_EXT 10 |
91 |
|
|
92 |
""" % locals()) |
""" % locals()) |
93 |
|
|
94 |
ppass.setTeardowncode("""PopAttrib""") |
ppass.setTeardowncode("""PopAttrib""") |
102 |
papo = mpap(nvcode.combinercode(""" |
papo = mpap(nvcode.combinercode(""" |
103 |
Enable REGISTER_COMBINERS_NV |
Enable REGISTER_COMBINERS_NV |
104 |
CombinerParameterNV NUM_GENERAL_COMBINERS_NV 1 |
CombinerParameterNV NUM_GENERAL_COMBINERS_NV 1 |
105 |
FCI A TEXTURE0 UNSIGNED_INVERT_NV RGB |
|
106 |
|
CI0 RGB A TEXTURE0 EXPAND_NEGATE_NV RGB |
107 |
|
CI0 RGB B ZERO UNSIGNED_INVERT_NV RGB |
108 |
|
CI0 RGB C ZERO UNSIGNED_INVERT_NV RGB |
109 |
|
CI0 RGB D ZERO UNSIGNED_INVERT_NV RGB |
110 |
|
CO0 RGB DISCARD_NV DISCARD_NV SPARE0_NV NONE NONE FALSE FALSE FALSE |
111 |
|
FCI A SPARE0_NV UNSIGNED_IDENTITY_NV RGB |
112 |
FCI B ZERO UNSIGNED_INVERT_NV RGB |
FCI B ZERO UNSIGNED_INVERT_NV RGB |
113 |
FCI C ZERO UNSIGNED_IDENTITY_NV RGB |
FCI C ZERO UNSIGNED_IDENTITY_NV RGB |
114 |
FCI D ZERO UNSIGNED_IDENTITY_NV RGB |
FCI D ZERO UNSIGNED_IDENTITY_NV RGB |
115 |
FCI G ZERO UNSIGNED_IDENTITY_NV ALPHA |
FCI G ZERO UNSIGNED_IDENTITY_NV ALPHA |
116 |
BlendFunc ONE ONE_MINUS_SRC_COLOR |
BlendFunc ONE ONE |
117 |
BlendEquation FUNC_REVERSE_SUBTRACT |
BlendEquation FUNC_REVERSE_SUBTRACT |
118 |
"""), pap = background.clone()) |
"""), pap = background.clone()) |
119 |
return (papw, pw, ph, papo) |
return (papw, pw, ph, papo) |
120 |
|
|
121 |
|
|
122 |
class CellPDFView: |
class CellPDFView: |
123 |
dicefactor = 1.0 |
dicefactor = 3.0 |
124 |
"""A view of a PDF file in a cell, spread out in space. |
"""A view of a PDF file in a cell, spread out in space. |
125 |
""" |
""" |
126 |
def __init__(self, cell): |
def __init__(self, cell): |
127 |
self.white = GLCache.getCallList("Color 1 1 1") |
self.contentcolor = GLCache.getCallList("Color 0.1 0 0") |
128 |
self.black = GLCache.getCallList("Color 0 0 0") |
self.black = GLCache.getCallList("Color 0 0 0") |
129 |
self.cell = cell |
self.cell = cell |
130 |
self.content = cell.space.cellTexter.getEnfilade(cell, None) |
self.content = cell.space.cellTexter.getEnfilade(cell, None) |
224 |
vs.map.put(self.irregu.frame, cs1into, irr) |
vs.map.put(self.irregu.frame, cs1into, irr) |
225 |
class ContentR(java.lang.Runnable): |
class ContentR(java.lang.Runnable): |
226 |
def run(rself): |
def run(rself): |
227 |
vs.map.put(self.white) |
vs.map.put(self.contentcolor) |
228 |
vs.map.put(self.irregu.content, cs1into, irr) |
vs.map.put(self.irregu.content, cs1into, irr) |
229 |
|
|
230 |
if showTessel: |
if showTessel: |
231 |
vs.map.put(GLCache.getCallList(""" |
vs.map.put(GLCache.getCallList(""" |
232 |
PushAttrib POLYGON_BIT |
PushAttrib POLYGON_BIT LINE_BIT ENABLE_BIT DEPTH_BUFFER_BIT |
233 |
PolygonMode FRONT_AND_BACK LINE |
PolygonMode FRONT_AND_BACK LINE |
234 |
LineWidth 1 |
LineWidth 1 |
235 |
|
Disable DEPTH_TEST |
236 |
""")) |
""")) |
237 |
ContentR().run() |
ContentR().run() |
238 |
FrameR().run() |
# FrameR().run() Too much mess |
239 |
pp.run() |
pp.run() |
240 |
vs.map.put(GLCache.getCallList(""" |
vs.map.put(GLCache.getCallList(""" |
241 |
PopAttrib |
PopAttrib |