1 |
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.3//EN" "https://www.web3d.org/specifications/x3d-3.3.dtd">
|
3 | <X3D profile='Immersive' version='3.3' xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='https://www.web3d.org/specifications/x3d-3.3.xsd'> |
4 | <head> |
5 | <meta name='title' content='PixelTextureSnowman.x3d'/> |
6 | <meta name='description' content='This snowman example shows a colorful PixelTexture applied to X3D primitive shapes - happy holidays!'/> |
7 | <meta name='creator' content='Craig Schwetje, Leonard Daly and Don Brutzman'/> |
8 | <meta name='created' content='2 February 2006'/> |
9 | <meta name='translated' content='25 August 2008'/> |
10 | <meta name='modified' content='22 August 2024'/> |
11 | <meta name='Sound' content='frosty2.mid'/> |
12 | <meta name='reference' content='https://en.wikipedia.org/wiki/Snowman'/> |
13 | <meta name='Sound' content='https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter05AppearanceMaterialTextures/frosty2.mid'/> |
14 | <meta name='reference' content='http://www.the-north-pole.com/carols/frosty.html'/> |
15 | <meta name='reference' content='https://X3dGraphics.com'/> |
16 | <meta name='reference' content='https://www.web3d.org/x3d/content/examples/X3dResources.html'/> |
17 | <meta name='subject' content='PixelTexture, MIDI, X3D book, X3D graphics, X3D-Edit, http://www.x3dGraphics.com'/> |
18 | <meta name='identifier' content='https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter05AppearanceMaterialTextures/PixelTextureSnowman.x3d'/> |
19 | <meta name='generator' content='X3D-Edit 4.0, https://savage.nps.edu/X3D-Edit'/> |
20 | <meta name='license' content='../license.html'/> |
21 | </head> |
22 | <Scene> |
23 | <WorldInfo title='PixelTextureSnowman.x3d'/> |
24 | <Background skyColor='1 1 1'/> |
25 | <Viewpoint description='PixelTexture Snowman' orientation='1 0 0 -0.17985' position='0 2 11'/> |
26 | <Sound location='0 1.6 0' maxBack='50' maxFront='50' minBack='5' minFront='5' priority='1'> |
27 | <AudioClip description='Frosty the Snowman' loop='true' url=' "frosty2.mid" "https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter05AppearanceMaterialTextures/frosty2.mid" '/> |
28 | </Sound> |
29 | <Transform translation='0 -2.5 2'> |
30 | <Billboard> |
31 | <Anchor DEF='WikipediaAnchorLink' description='Wikipedia Snowman entry' parameter='"target=_blank"' url=' "https://en.wikipedia.org/wiki/Snowman" '> |
32 | <Shape> |
33 | <Text string='"Click here to learn more" "about snowmen"'> |
34 | <FontStyle justify='"MIDDLE" "MIDDLE"' size='0.6'/> |
35 | </Text> |
36 | <Appearance> |
37 | <Material DEF='Autumn11' ambientIntensity='0.25641' diffuseColor='1 0.160784 0.764706' shininess='1' specularColor='0.48655 0.319155 0.444036'/> |
38 | </Appearance> |
39 | </Shape> |
40 | <!-- Add transparent geometry over the text to make clicking (i.e. Anchor selection) easier --> |
41 | <Shape> |
42 | <Box size='6 1.5 0.02'/> |
43 | <Appearance> |
44 | <Material transparency='1'/> |
45 | </Appearance> |
46 | </Shape> |
47 | </Anchor> |
48 | </Billboard> |
49 | </Transform> |
50 |
<!-- ROUTE information for SnowmanRoot node:
[from TwistInterpolator.value_changed to rotation
]
-->
<Transform DEF='SnowmanRoot'> |
51 |
<!-- ROUTE information for TwistInterpolator node:
[from Clock.fraction_changed to set_fraction
]
[from value_changed to SnowmanRoot.rotation
]
-->
<OrientationInterpolator DEF='TwistInterpolator' key='0 0.22 0.25 0.5 0.73 0.75 1' keyValue='0 1 0 0 0 1 0 5.75959 0 1 0 5.75959 0 1 0 0 0 1 0 0.5236 0 1 0 0.5236 0 1 0 0'/> |
52 |
<!-- ROUTE information for Clock node:
[from fraction_changed to TwistInterpolator.set_fraction
]
-->
<TimeSensor DEF='Clock' cycleInterval='6' loop='true'/> |
53 | < ROUTE fromNode='TwistInterpolator' fromField='value_changed' toNode='SnowmanRoot' toField='rotation'/> |
54 | < ROUTE fromNode='Clock' fromField='fraction_changed' toNode='TwistInterpolator' toField='set_fraction'/> |
55 | <!-- Hat --> |
56 | <Transform translation='0 3.6 0'> |
57 | <Shape> |
58 | <Appearance> |
59 | <Material diffuseColor='0.003922 0.003922 0.003922'/> |
60 | </Appearance> |
61 | <Cylinder height='1' radius='0.5'/> |
62 | </Shape> |
63 | </Transform> |
64 | <Transform translation='0 3.2 0'> |
65 | <Shape> |
66 | <Appearance> |
67 | <Material diffuseColor='0.003922 0.003922 0.003922'/> |
68 | </Appearance> |
69 | <Cylinder height='0.2'/> |
70 | </Shape> |
71 | </Transform> |
72 | <!-- Head --> |
73 | <Transform translation='0 2.6 0'> |
74 | <Shape> |
75 | <Appearance> |
76 |
<!-- PixelTexture
PixelColors is a DEF node that has 2 USE nodes: USE_1, USE_2 --> <PixelTexture DEF='PixelColors' image='2 4 3 0xff0000 0xffff00 0x007700 0xff0077 0x0000ff 0xff7700 0x00ff77 0x888888' repeatS='false' repeatT='false'/> |
77 | </Appearance> |
78 | <Sphere radius='.75'/> |
79 | </Shape> |
80 | </Transform> |
81 | <!-- Eyes --> |
82 | <Transform translation='0.3 2.7 .55'> |
83 | <Shape> |
84 | <Appearance> |
85 | <Material diffuseColor='0 0 0'/> |
86 | </Appearance> |
87 | <Sphere radius='.18'/> |
88 | </Shape> |
89 | </Transform> |
90 | <Transform translation='-0.3 2.7 .55'> |
91 | <Shape> |
92 | <Appearance> |
93 | <Material diffuseColor='0 0 0'/> |
94 | </Appearance> |
95 | <Sphere radius='.18'/> |
96 | </Shape> |
97 | </Transform> |
98 | <!-- Nose --> |
99 | <Transform rotation='1 0 0 1.57' translation='0 2.5 0.55'> |
100 | <Shape> |
101 | <Appearance> |
102 | <Material diffuseColor='0.901961 0.403922 0' emissiveColor='1 0.145098 0.058824' specularColor='1 0.454902 0.360784'/> |
103 | </Appearance> |
104 | <Cone bottomRadius='0.3' height='1.75'/> |
105 | </Shape> |
106 | </Transform> |
107 | <!-- Scarf --> |
108 | <Transform translation='0 1.975 0'> |
109 | <Shape> |
110 | <Appearance> |
111 | <Material diffuseColor='1 0.039216 0.243137'/> |
112 | </Appearance> |
113 | <Cylinder height='0.175' radius='0.8'/> |
114 | </Shape> |
115 | </Transform> |
116 | <Transform translation='.7 1.1 .8'> |
117 | <Shape> |
118 | <Appearance> |
119 | <Material diffuseColor='1 0.039216 0.243137'/> |
120 | </Appearance> |
121 | <Sphere radius='.1'/> |
122 | </Shape> |
123 | </Transform> |
124 | <Transform translation='.725 1.2 .85'> |
125 | <Shape> |
126 | <Appearance> |
127 | <Material diffuseColor='1 0.039216 0.243137'/> |
128 | </Appearance> |
129 | <Sphere radius='.1'/> |
130 | </Shape> |
131 | </Transform> |
132 | <Transform translation='.7 1.3 .8'> |
133 | <Shape> |
134 | <Appearance> |
135 | <Material diffuseColor='1 0.039216 0.243137'/> |
136 | </Appearance> |
137 | <Sphere radius='.1'/> |
138 | </Shape> |
139 | </Transform> |
140 | <Transform translation='.7 1.4 .75'> |
141 | <Shape> |
142 | <Appearance> |
143 | <Material diffuseColor='1 0.039216 0.243137'/> |
144 | </Appearance> |
145 | <Sphere radius='.1'/> |
146 | </Shape> |
147 | </Transform> |
148 | <Transform translation='.7 1.5 .75'> |
149 | <Shape> |
150 | <Appearance> |
151 | <Material diffuseColor='1 0.039216 0.243137'/> |
152 | </Appearance> |
153 | <Sphere radius='.1'/> |
154 | </Shape> |
155 | </Transform> |
156 | <Transform translation='.7 1.6 .7'> |
157 | <Shape> |
158 | <Appearance> |
159 | <Material diffuseColor='1 0.039216 0.243137'/> |
160 | </Appearance> |
161 | <Sphere radius='.1'/> |
162 | </Shape> |
163 | </Transform> |
164 | <Transform translation='.7 1.7 .65'> |
165 | <Shape> |
166 | <Appearance> |
167 | <Material diffuseColor='1 0.039216 0.243137'/> |
168 | </Appearance> |
169 | <Sphere radius='.1'/> |
170 | </Shape> |
171 | </Transform> |
172 | <Transform translation='.6 1.8 .65'> |
173 | <Shape> |
174 | <Appearance> |
175 | <Material diffuseColor='1 0.039216 0.243137'/> |
176 | </Appearance> |
177 | <Sphere radius='.1'/> |
178 | </Shape> |
179 | </Transform> |
180 | <Transform translation='.55 1.9 .65'> |
181 | <Shape> |
182 | <Appearance> |
183 | <Material diffuseColor='1 0.039216 0.243137'/> |
184 | </Appearance> |
185 | <Sphere radius='.1'/> |
186 | </Shape> |
187 | </Transform> |
188 | <Transform translation='.55 2 .65'> |
189 | <Shape> |
190 | <Appearance> |
191 | <Material diffuseColor='1 0.039216 0.243137'/> |
192 | </Appearance> |
193 | <Sphere radius='.1'/> |
194 | </Shape> |
195 | </Transform> |
196 | <!-- Backside of scarf --> |
197 | <Transform translation='-.7 1.1 -.8'> |
198 | <Shape> |
199 | <Appearance> |
200 | <Material diffuseColor='1 0.039216 0.243137'/> |
201 | </Appearance> |
202 | <Sphere radius='.1'/> |
203 | </Shape> |
204 | </Transform> |
205 | <Transform translation='-.725 1.2 -.85'> |
206 | <Shape> |
207 | <Appearance> |
208 | <Material diffuseColor='1 0.039216 0.243137'/> |
209 | </Appearance> |
210 | <Sphere radius='.1'/> |
211 | </Shape> |
212 | </Transform> |
213 | <Transform translation='-.7 1.3 -.8'> |
214 | <Shape> |
215 | <Appearance> |
216 | <Material diffuseColor='1 0.039216 0.243137'/> |
217 | </Appearance> |
218 | <Sphere radius='.1'/> |
219 | </Shape> |
220 | </Transform> |
221 | <Transform translation='-.7 1.4 -.75'> |
222 | <Shape> |
223 | <Appearance> |
224 | <Material diffuseColor='1 0.039216 0.243137'/> |
225 | </Appearance> |
226 | <Sphere radius='.1'/> |
227 | </Shape> |
228 | </Transform> |
229 | <Transform translation='-.7 1.5 -.75'> |
230 | <Shape> |
231 | <Appearance> |
232 | <Material diffuseColor='1 0.039216 0.243137'/> |
233 | </Appearance> |
234 | <Sphere radius='.1'/> |
235 | </Shape> |
236 | </Transform> |
237 | <Transform translation='-.7 1.6 -.7'> |
238 | <Shape> |
239 | <Appearance> |
240 | <Material diffuseColor='1 0.039216 0.243137'/> |
241 | </Appearance> |
242 | <Sphere radius='.1'/> |
243 | </Shape> |
244 | </Transform> |
245 | <Transform translation='-.7 1.7 -.65'> |
246 | <Shape> |
247 | <Appearance> |
248 | <Material diffuseColor='1 0.039216 0.243137'/> |
249 | </Appearance> |
250 | <Sphere radius='.1'/> |
251 | </Shape> |
252 | </Transform> |
253 | <Transform translation='-.6 1.8 -.65'> |
254 | <Shape> |
255 | <Appearance> |
256 | <Material diffuseColor='1 0.039216 0.243137'/> |
257 | </Appearance> |
258 | <Sphere radius='.1'/> |
259 | </Shape> |
260 | </Transform> |
261 | <Transform translation='-.55 1.9 -.65'> |
262 | <Shape> |
263 | <Appearance> |
264 | <Material diffuseColor='1 0.039216 0.243137'/> |
265 | </Appearance> |
266 | <Sphere radius='.1'/> |
267 | </Shape> |
268 | </Transform> |
269 | <Transform translation='-.55 2 -.65'> |
270 | <Shape> |
271 | <Appearance> |
272 | <Material diffuseColor='1 0.039216 0.243137'/> |
273 | </Appearance> |
274 | <Sphere radius='.1'/> |
275 | </Shape> |
276 | </Transform> |
277 | <!-- Mouth --> |
278 | <!-- Middle Mouthpiece --> |
279 | <Transform translation='0 2.2 .55'> |
280 | <Shape> |
281 | <Appearance> |
282 | <Material diffuseColor='0 0 0'/> |
283 | </Appearance> |
284 | <Sphere radius='.1'/> |
285 | </Shape> |
286 | </Transform> |
287 | <Transform translation='0.1 2.2 .55'> |
288 | <Shape> |
289 | <Appearance> |
290 | <Material diffuseColor='0 0 0'/> |
291 | </Appearance> |
292 | <Sphere radius='.1'/> |
293 | </Shape> |
294 | </Transform> |
295 | <Transform translation='0.2 2.2 .55'> |
296 | <Shape> |
297 | <Appearance> |
298 | <Material diffuseColor='0 0 0'/> |
299 | </Appearance> |
300 | <Sphere radius='.1'/> |
301 | </Shape> |
302 | </Transform> |
303 | <Transform translation='-0.1 2.2 .55'> |
304 | <Shape> |
305 | <Appearance> |
306 | <Material diffuseColor='0 0 0'/> |
307 | </Appearance> |
308 | <Sphere radius='.1'/> |
309 | </Shape> |
310 | </Transform> |
311 | <Transform translation='-0.2 2.2 .55'> |
312 | <Shape> |
313 | <Appearance> |
314 | <Material diffuseColor='0 0 0'/> |
315 | </Appearance> |
316 | <Sphere radius='.1'/> |
317 | </Shape> |
318 | </Transform> |
319 | <!-- Pipe --> |
320 | <Transform rotation='0.96225 0.19245 -0.19245 1.57' translation='0.1 2.2 0.55'> |
321 | <Shape> |
322 | <Appearance> |
323 | <Material diffuseColor='0.219608 0.137255 0'/> |
324 | </Appearance> |
325 | <Cylinder radius='0.03'/> |
326 | </Shape> |
327 | </Transform> |
328 | <Transform translation='.45 2.3 1.5'> |
329 | <Shape> |
330 | <Appearance> |
331 | <Material diffuseColor='0.219608 0.137255 0'/> |
332 | </Appearance> |
333 | <Cylinder height='.2' radius='.1'/> |
334 | </Shape> |
335 | </Transform> |
336 | <!-- Body --> |
337 | <Transform translation='0 1.15 0'> |
338 | <Shape> |
339 | <Appearance> |
340 | <PixelTexture USE='PixelColors'/> |
341 | </Appearance> |
342 | <Sphere radius='1.1'/> |
343 | </Shape> |
344 | </Transform> |
345 | <!-- Arms --> |
346 | <Transform rotation='0 0 1 1.57' translation='0 1.5 0'> |
347 | <Shape> |
348 | <Appearance> |
349 | <Material diffuseColor='.5 .25 .05'/> |
350 | </Appearance> |
351 | <Cylinder height='4.9' radius='0.1'/> |
352 | </Shape> |
353 | </Transform> |
354 | <Transform rotation='0 0.92848 0.37139 1.57' translation='2 1.5 0'> |
355 | <Shape> |
356 | <Appearance> |
357 | <Material diffuseColor='.5 .25 .05'/> |
358 | </Appearance> |
359 | <Cylinder height='.9' radius='0.05'/> |
360 | </Shape> |
361 | </Transform> |
362 | <Transform rotation='0.84515 -0.50709 0.16903 1.57' translation='1.5 1.5 0'> |
363 | <Shape> |
364 | <Appearance> |
365 | <Material diffuseColor='.5 .25 .05'/> |
366 | </Appearance> |
367 | <Cylinder height='.7' radius='0.03'/> |
368 | </Shape> |
369 | </Transform> |
370 | <Transform rotation='0 0.64018 0.76822 1.57' translation='-1 1.5 0'> |
371 | <Shape> |
372 | <Appearance> |
373 | <Material diffuseColor='.5 .25 .05'/> |
374 | </Appearance> |
375 | <Cylinder height='1' radius='0.05'/> |
376 | </Shape> |
377 | </Transform> |
378 | <Transform rotation='0 0.70711 -0.70711 1' translation='-1.9 1.5 0'> |
379 | <Shape> |
380 | <Appearance> |
381 | <Material diffuseColor='.5 .25 .05'/> |
382 | </Appearance> |
383 | <Cylinder height='.5' radius='0.04'/> |
384 | </Shape> |
385 | </Transform> |
386 | <!-- Left Glove --> |
387 | <Transform rotation='0 0 1 1.57' translation='2.45 1.5 0'> |
388 | <Shape> |
389 | <Appearance> |
390 | <Material diffuseColor='1 0.039216 0.243137'/> |
391 | </Appearance> |
392 | <Box size='0.5 0.5 0.25'/> |
393 | </Shape> |
394 | </Transform> |
395 | <Transform rotation='0.95285 0 0.30345 1.57' translation='2.75 1.5 0.05'> |
396 | <Shape> |
397 | <Appearance> |
398 | <Material diffuseColor='1 0.039216 0.243137'/> |
399 | </Appearance> |
400 | <Cylinder height='.25' radius='0.25'/> |
401 | </Shape> |
402 | </Transform> |
403 | <Transform rotation='0.96352 0 0.26764 1.57' translation='2.55 1.85 0'> |
404 | <Shape> |
405 | <Appearance> |
406 | <Material diffuseColor='1 0.039216 0.243137'/> |
407 | </Appearance> |
408 | <Cylinder height='.15' radius='0.15'/> |
409 | </Shape> |
410 | </Transform> |
411 | <!-- Right Glove --> |
412 | <Transform rotation='0 0 1 1.57' translation='-2.45 1.5 0'> |
413 | <Shape> |
414 | <Appearance> |
415 | <Material diffuseColor='1 0.039216 0.243137'/> |
416 | </Appearance> |
417 | <Box size='0.5 0.5 0.25'/> |
418 | </Shape> |
419 | </Transform> |
420 | <Transform rotation='-0.95285 0 0.30345 1.57' translation='-2.75 1.5 0.05'> |
421 | <Shape> |
422 | <Appearance> |
423 | <Material diffuseColor='1 0.039216 0.243137'/> |
424 | </Appearance> |
425 | <Cylinder height='.25' radius='0.25'/> |
426 | </Shape> |
427 | </Transform> |
428 | <Transform rotation='-0.96352 0 0.26764 1.57' translation='-2.55 1.85 0'> |
429 | <Shape> |
430 | <Appearance> |
431 | <Material diffuseColor='1 0.039216 0.243137'/> |
432 | </Appearance> |
433 | <Cylinder height='.15' radius='0.15'/> |
434 | </Shape> |
435 | </Transform> |
436 | <!-- Buttons --> |
437 | <Transform translation='0 1.7 .95'> |
438 | <Shape> |
439 | <Appearance> |
440 | <Material diffuseColor='0 0 0'/> |
441 | </Appearance> |
442 | <Sphere radius='.1'/> |
443 | </Shape> |
444 | </Transform> |
445 | <Transform translation='0 1.25 1.05'> |
446 | <Shape> |
447 | <Appearance> |
448 | <Material diffuseColor='0 0 0'/> |
449 | </Appearance> |
450 | <Sphere radius='.1'/> |
451 | </Shape> |
452 | </Transform> |
453 | <Transform translation='0 .8 1.05'> |
454 | <Shape> |
455 | <Appearance> |
456 | <Material diffuseColor='0 0 0'/> |
457 | </Appearance> |
458 | <Sphere radius='.1'/> |
459 | </Shape> |
460 | </Transform> |
461 | <!-- Lower Body --> |
462 | <Transform translation='0 -1 0'> |
463 | <Shape> |
464 | <Appearance> |
465 | <PixelTexture USE='PixelColors'/> |
466 | </Appearance> |
467 | <Sphere radius='1.75'/> |
468 | </Shape> |
469 | </Transform> |
470 | </Transform> |
471 | </Scene> |
472 | </X3D> |
Event Graph ROUTE Table entries with 2 ROUTE connections total, showing X3D event-model relationships for this scene.
Each row shows an event cascade that may occur during a single timestamp interval between frame renderings, as part of the X3D execution model.
Clock
TimeSensor fraction_changed SFFloat |
TwistInterpolator
OrientationInterpolator set_fraction SFFloat |
then
|
TwistInterpolator
OrientationInterpolator value_changed SFRotation |
SnowmanRoot
Transform rotation SFRotation |
WikipediaAnchorLink
Anchor |
description='Wikipedia Snowman entry' User-interaction hint for this node. |
<!--
Color-coding legend: X3D terminology
<X3dNode
DEF='idName' field='value'/>
matches XML terminology
<XmlElement
DEF='idName' attribute='value'/>
(Light-blue background: event-based behavior node or statement)
(Grey background inside box: inserted documentation)
(Magenta background: X3D Extensibility)
-->
<!-- For additional help information about X3D scenes, please see X3D Tooltips, X3D Resources, and X3D Scene Authoring Hints. -->