57 |
def __init__(self, dict): |
def __init__(self, dict): |
58 |
# Add default values below |
# Add default values below |
59 |
self.continuous = 1 |
self.continuous = 1 |
60 |
|
self.minfilter = "LINEAR_MIPMAP_LINEAR" |
61 |
|
self.magfilter = "LINEAR" |
62 |
|
|
63 |
# Update from specified values |
# Update from specified values |
64 |
self.__dict__.update(dict) |
self.__dict__.update(dict) |
78 |
initialized = 1 |
initialized = 1 |
79 |
global ptextures |
global ptextures |
80 |
ptextures["RGB2"] = map(NamedTexture, [ |
ptextures["RGB2"] = map(NamedTexture, [ |
81 |
{"name" : "rgbw1", |
# {"name" : "rgbw1", |
82 |
"args" : [tres, tres, 0, 3, "RGB", "RGB", "fnoise", |
# "args" : [tres, tres, 0, 3, "RGB", "RGB", "fnoise", |
83 |
["scale", "2.5", "freq", "1", "df", "2", "bias", "0.5"]], |
# ["scale", "2.5", "freq", "1", "df", "2", "bias", "0.5"]], |
84 |
"scale" : 1./8, |
# "scale" : 1./8, |
85 |
}, |
# }, |
86 |
|
|
87 |
{"name" : "rgbw2", |
{"name" : "rgbw2", |
88 |
"args" : [tres, tres, 0, 3, "RGB", "RGB", "fnoise", |
"args" : [tres, tres, 0, 3, "RGB", "RGB", "fnoise", |
104 |
}, |
}, |
105 |
|
|
106 |
{"name" : "checkerboard", |
{"name" : "checkerboard", |
107 |
"args" : [64, 64, 0, 3, "RGB", "RGB", "geometric", ["type", "1"]], |
"args" : [4, 4, 0, 3, "RGB", "RGB", "geometric", ["type", "1", "scale", ".5", "bias", ".5"]], |
108 |
"continuous" : 0, |
"continuous" : 0, |
109 |
"scale" : 1./64, |
"scale" : 1./8, |
110 |
|
"minfilter" : "NEAREST", |
111 |
|
"magfilter" : "NEAREST", |
112 |
}, |
}, |
113 |
|
|
114 |
{"name" : "cone", |
{"name" : "cone", |
117 |
}, |
}, |
118 |
|
|
119 |
{"name" : "checkerboard2", |
{"name" : "checkerboard2", |
120 |
"args" : [64, 64, 0, 3, "RGB", "RGB", "geometric", ["type", "3"]], |
"args" : [2, 2, 0, 3, "RGB", "RGB", "geometric", ["type", "3", "scale", ".5", "bias", ".5"]], |
121 |
"continuous" : 0, |
"continuous" : 0, |
122 |
"scale" : 1./64, |
"scale" : 1./8, |
123 |
|
"minfilter" : "NEAREST", |
124 |
|
"magfilter" : "NEAREST", |
125 |
}, |
}, |
126 |
|
|
127 |
{"name" : "saw", |
{"name" : "saw", |
128 |
"args" : [64, 64, 0, 3, "RGB", "RGB", "geometric", ["type", "4"]], |
"args" : [64, 64, 0, 3, "RGB", "RGB", "geometric", ["type", "4"]], |
129 |
"continuous" : 0, |
"continuous" : 0, |
130 |
"scale" : 1./64, |
"scale" : 1./8, |
131 |
|
"minfilter" : "NEAREST", |
132 |
|
"magfilter" : "NEAREST", |
133 |
}, |
}, |
134 |
|
|
135 |
{"name" : "triangle", |
{"name" : "triangle", |
136 |
"args" : [64, 64, 0, 3, "RGB", "RGB", "geometric", ["type", "5"]], |
"args" : [64, 64, 0, 3, "RGB", "RGB", "geometric", ["type", "5"]], |
137 |
"scale" : 1./2, |
"scale" : 1./2, |
138 |
}, |
}, |
139 |
|
|
140 |
|
{"name" : "stripe", |
141 |
|
"args" : [2, 2, 0, 3, "RGB", "RGB", "geometric", ["type", "6", "scale", ".5", "bias", ".5"]], |
142 |
|
"continuous" : 0, |
143 |
|
"scale" : 1./8, |
144 |
|
"minfilter" : "NEAREST", |
145 |
|
"magfilter" : "NEAREST", |
146 |
|
}, |
147 |
]) |
]) |
148 |
|
|
149 |
def getPaperTexture(type, gen): |
def getPaperTexture(type, gen): |