### Author Topic: MAPTRIANGLE in 3D  (Read 1755 times)

#### Petr

• The best code is the DNA of the hops.
##### Re: MAPTRIANGLE in 3D: textured roller or cone
« Reply #15 on: November 27, 2018, 03:06:50 PM »
Hi.

In sample examples, textured blocks are already available. I was thinking about how to make a textured cylinder. Finally, the program can handle both a textured disk, a cylinder and a cone. The number of cone sides is determined by the Segments variable in the program. The higher Segments is, the body is finer and the texture is more faithful (and the program more demanding). The variables in the Celo0 and Celo1 fields contain the values ​​of the vertices of the individual triangles in the sense of rotation (because the object is a rotating body), celo0 is one untextured side of the cylinder, the cello1 is the second untextured side of the cylinder (bottom). Use the 1,2 keys to change the speed or direction of rotation, 3,4 to move the face to the X axis, 5,6 to move the Y axis, 7,8 to move the X axis to the second bottom, 9, Q to shift the Y axis of the second end, W, E for changing the diameter of the cylinder face, R, T for changing the diameter of the second face of the cylinder, A, S for the zoom, D, F for displacement in the Z axis of the first face, and G, H for the Z axis cell. A beautiful effect can be achieved by using the Stars image by Johnno56. I have one question for developers - why is this happening:

Use the T / R or W / E key to open the cone so that it is a hollow cylinder. Press C. This will enable the _CLOCKWISE parameter. The picture then has a lot of noise. Now close the cylinder (do the cone) (one radius is set to zero), the noise disappears. Why?

Code: QB64 [Select]
1. SCREEN _NEWIMAGE(800, 600, 32)
2.
3. TYPE crc
4.
5. DIM SHARED Segments, R1, R2, Z1, Z2, Efect, OldX, OldY
6.
7. 'Warning! Segments variable muss be dividible by 2!
8. Segments = 314: R1 = .1: R2 = 2: Z1 = -1: Z2 = -2
9. im = _LOADIMAGE("abcde 066.jpg", 32)
10.
11. restart:
12. REDIM s(Segments + 1) AS LONG, celo0(Segments + 1) AS crc, celo1(Segments + 1) AS crc
13.
14. divideimage s(), im
15. SETCelo R1, celo0()
16. SETCelo R2, celo1()
17. S = Segments
18. rd = .01
19. PrintIT = 1
20.     Quad celo0(1).x, celo0(1).y, Z1, celo0(S).x, celo0(S).y, Z1, celo1(1).x, celo1(1).y, Z2, celo1(S).x, celo1(S).y, Z2, s(1)
21.     FOR d = 2 TO Segments
22.         Quad celo0(d - 1).x, celo0(d - 1).y, Z1, celo0(d).x, celo0(d).y, Z1, celo1(d - 1).x, celo1(d - 1).y, Z2, celo1(d).x, celo1(d).y, Z2, s(d)
23.     NEXT d
24.
25.
26.     i\$ = INKEY\$
27.
28.     SELECT CASE UCASE\$(i\$)
29.         CASE "1": rd = rd + .001
30.         CASE "2": rd = rd - .001
31.         CASE "3": c0x = c0x + .01
32.         CASE "4": c0x = c0x - .01
33.         CASE "5": c0y = c0y + .01
34.         CASE "6": c0y = c0y - .01
35.
36.         CASE "7": c1x = c1x + .01
37.         CASE "8": c1x = c1x - .01
38.         CASE "9": c1y = c1y + .01
39.         CASE "Q": c1y = c1y - .01
40.
41.         CASE "W": R1 = R1 - .01: SETCelo R1, celo0()
42.         CASE "E": R1 = R1 + .01: SETCelo R1, celo0()
43.         CASE "R": R2 = R2 - .01: SETCelo R2, celo1()
44.         CASE "T": R2 = R2 + .01: SETCelo R2, celo1()
45.
46.
47.         CASE "A": Z1 = Z1 + .01: Z2 = Z2 + .01
48.         CASE "S": Z1 = Z1 - .01: Z2 = Z2 - .01
49.
50.         CASE "D": Z1 = Z1 + .01
51.         CASE "F": Z1 = Z1 - .01
52.
53.         CASE "G": Z2 = Z2 + .01
54.         CASE "H": Z2 = Z2 - .01
55.
56.         CASE "C": IF Efect = 0 THEN Efect = 1 ELSE Efect = 0: _DELAY .2
57.         CASE CHR\$(27):
59.                 _FREEIMAGE s(freemem)
60.
61.
62.
63.     i = 0: rot = rot + rd
64.
65.
66.     FOR f = 360 / Segments TO 360 STEP (360 / Segments)
67.         i = i + 1
69.         celo0(i).x = SIN(rad + rot) * R1 + c0x
70.         celo0(i).y = COS(rad + rot) * R1 + c0y
71.
72.         celo1(i).x = SIN(rad + rot) * R2 + c1x
73.         celo1(i).y = COS(rad + rot) * R2 + c1y
74.
75.
76.
77.     IF PrintIT THEN
78.         PRINT "Press 1,2 for rotation, 3,4 for radius 1 X pos, 5,6 for radius 1 Y pos, 7,8 for radius 2 X pos, 9,Q for radius 2 Y pos, W,E for radius 1, R,T for radius 2, A,S for zoom, D,F for depth 1, G,H for depth 2"
79.         PRINT "Segments in use: "; Segments
80.         PrintIT = 0
81.
82.     _LIMIT 55
83.
84.
85. SUB SETCelo (radius AS INTEGER, arr() AS crc)
86.     FOR f = 0 TO 360 STEP (360 / Segments)
87.         i = i + 1
91.
92.
93. SUB divideimage (s() AS LONG, source AS LONG) 'divide image to more images in X
94.     sir = _WIDTH(source) / UBOUND(S)
95.     FOR r = 0 TO Segments
96.         i = i + 1
97.         s(i) = _NEWIMAGE(sir, _HEIGHT(source), 32)
98.         _PUTIMAGE (0, 0)-(sir, _HEIGHT(source)), source, s(i), (sirka, 0)-(sirka + sir, _HEIGHT(source))
99.         s(i) = _COPYIMAGE(s(i), 33)
100.         sirka = sirka + sir
101.     NEXT r
102.
103. SUB Quad (dx1, dy1, dz1, dx2, dy2, dz2, dx3, dy3, dz3, dx4, dy4, dz4, imag&)
104.     W = _WIDTH(imag&)
105.     H = _HEIGHT(imag&)
106.
107.     IF Efect THEN
108.         _MAPTRIANGLE _CLOCKWISE (0, 0)-(W, 0)-(0, H), imag& TO(dx1, dy1, dz1)-(dx2, dy2, dz2)-(dx3, dy3, dz3), 0
109.         _MAPTRIANGLE _CLOCKWISE (W, 0)-(0, H)-(W, H), imag& TO(dx2, dy2, dz2)-(dx3, dy3, dz3)-(dx4, dy4, dz4), 0
110.         _MAPTRIANGLE (0, 0)-(W, 0)-(0, H), imag& TO(dx1, dy1, dz1)-(dx2, dy2, dz2)-(dx3, dy3, dz3), 0
111.         _MAPTRIANGLE (W, 0)-(0, H)-(W, H), imag& TO(dx2, dy2, dz2)-(dx3, dy3, dz3)-(dx4, dy4, dz4), 0
112.
« Last Edit: November 27, 2018, 03:08:37 PM by Petr »

#### Petr

• The best code is the DNA of the hops.
##### Re: MAPTRIANGLE in 3D - ROTATION
« Reply #16 on: January 06, 2019, 11:08:18 AM »
Hi. Next demo show rotation in 3D using MAPTRIANGLE 3D, none direct OpenGL statements.

Code: QB64 [Select]
1. _TITLE "Next MAPTRIANGLE 3D demo"
2.
3. k = _PI(2) / 4
4.
5.
6. '------------
7. DIM SHARED texture AS LONG, rot
8. DIM i AS LONG, i2 AS LONG
9.
10.
11. DIM SHARED T(18 * 110) AS T
12.
13. init
14. '---------------------
15.
16.
17.
18. SCREEN _NEWIMAGE(800, 600, 32)
19. CLS , _RGB32(127, 127, 188)
20.
21.
22. DIM B(3) AS b
23.
24.
25. B(0).x = -1: B(0).y = -1
26. B(1).x = 1: B(1).y = -1
27. B(2).x = -1: B(2).y = -1
28. B(3).x = 1: B(3).y = -1
29.
30. w = _WIDTH(i)
31. h = _HEIGHT(i)
32.
33.     j = _NEWIMAGE(150, 100, 32)
34.     CLS , _RGBA32(0, 50, 127, 100)
35.     clock 0, 0
36.
37.     i = _COPYIMAGE(j, 33)
38.
39.     clock 0, 0
40.
41.     texture& = i
42.     '--------------------
43.
44.     FOR Ys = 0 TO 17
45.         zz2 = zz2 + .01
46.         FOR Xs = 0 TO 50
47.             IF T(i4).x > 0 THEN
48.                 X = T(i4).x + 70
49.                 Y = T(i4).y
50.                 z = T(i4).z - 70
51.                 kostka X - zz2, Y, z - 15 + zz2
52.             i4 = i4 + 1
53.     NEXT Xs, Ys
54.     i4 = 0
55.     IF zz2 > 140 THEN zz2 = -50
56.     '-----------------------------
57.
58.
59.     Sx = (200 + 600) / 2: Rx = (600 - 200) / 2
60.     Sy = (400 + 200) / 2: Ry = (400 - 200) / 2
61.     rot = rot + .01
62.
63.     Sx = 0
64.     Sz = -2.5
65.     Sy = -1
66.
67.
68.     Rx = 1
69.     Ry = -1
70.     Rz = 1
71.     ' info for rotation. To rotate the bodies, you must have all the points that are rotating in the same center. For this demo, it is easy to specify the radius of rotation,
72.     ' because all the points are just as far from the center as the cube is a symmetrical body. But if you want to write a 3D game, then if you want to write with MAPTRIANGLE,
73.     ' you need to map the floor using 4 triangles and calculate the radius for the points on the edges using the Pythagoras theorem:
74.     '
75.     '       A--------------------------B     x is your position, as you see, all points use different radius
76.     '       I\\\                   Y / I     Y is your triangle side 1, next is floor height - Y
77.     '       I   \\\\\\             Y/  I     X is your triangle side 2, next is floor width - X
78.     '       I          \\\\\\\\/// xXXXI     third sides calculate using Pythagoras.
79.     '       I       ////////////    \  I
80.     '       I //////                 \ I
81.     '       C--------------------------D
82.     '
83.     x1 = Sx + SIN(rot) * Rx: z1 = Sz + COS(rot) * Rz: y1R = Sy + SIN(rot) * Ry
84.     x2 = Sx + SIN(rot + k) * Rx: z2 = Sz + COS(rot + k) * Rz: y2R = Sy + SIN(rot + k) * Ry
85.
86.     x4 = Sx + SIN((2 * k) + rot) * Rx: z4 = Sz + COS((2 * k) + rot) * Rz: y3R = Sy + SIN((3 * k) + rot) * Ry
87.     x3 = Sx + SIN((3 * k) + rot) * Rx: z3 = Sz + COS((3 * k) + rot) * Rz: y4R = Sy + SIN((4 * k) + rot) * Ry
88.
89.     y1 = B(0).y
90.     y2 = B(1).y
91.     y4 = B(2).y
92.     y3 = B(3).y
93.
94.
95.
96.
97.     y5 = y1 + 1.5
98.     y6 = y2 + 1.5
99.     y7 = y3 + 1.5
100.     y8 = y4 + 1.5
101.
102.
103.     _MAPTRIANGLE (0, h)-(w, h)-(0, 0), i TO(x1, y1, z1)-(x2, y2, z2)-(x3, y3, z3) 'podlaha                 floor
104.     _MAPTRIANGLE (w, h)-(0, 0)-(w, 0), i TO(x2, y2, z2)-(x3, y3, z3)-(x4, y4, z4) 'podlaha
105.
106.
107.     _MAPTRIANGLE (0, h)-(w, h)-(0, 0), i TO(x1, y5, z1)-(x2, y6, z2)-(x3, y7, z3) 'strop                   roof
108.     _MAPTRIANGLE (w, h)-(0, 0)-(w, 0), i TO(x2, y6, z2)-(x3, y7, z3)-(x4, y8, z4) 'strop
109.
110.     _MAPTRIANGLE (0, h)-(w, h)-(0, 0), i TO(x1, y1, z1)-(x2, y2, z2)-(x1, y5, z1) 'prava stena             right wall
111.     _MAPTRIANGLE (w, h)-(0, 0)-(w, 0), i TO(x2, y2, z2)-(x1, y5, z1)-(x2, y6, z2) 'prava stena
112.
113.
114.     _MAPTRIANGLE (w, h)-(0, h)-(w, 0), i TO(x3, y3, z3)-(x4, y4, z4)-(x3, y7, z3) 'leva stena              left wall
115.     _MAPTRIANGLE (0, h)-(w, 0)-(0, 0), i TO(x4, y4, z4)-(x3, y7, z3)-(x4, y8, z4) 'leva stena
116.
117.
118.     _MAPTRIANGLE (w, h)-(0, h)-(w, 0), i TO(x1, y1, z1)-(x3, y3, z3)-(x1, y5, z1) 'zadni stena             back wall
119.     _MAPTRIANGLE (0, h)-(w, 0)-(0, 0), i TO(x3, y3, z3)-(x1, y5, z1)-(x3, y7, z3) 'zadni stena
120.
121.
122.     _MAPTRIANGLE (0, h)-(w, h)-(0, 0), i TO(x2, y2, z2)-(x4, y4, z4)-(x2, y6, z2) 'predni stena            front wall
123.     _MAPTRIANGLE (w, h)-(0, 0)-(w, 0), i TO(x4, y4, z4)-(x2, y6, z2)-(x4, y8, z4) 'zadni stena
124.
125.
126.     _LIMIT 50
127.
128. SUB kostka (x, y, z) 'zadavas levy horni predni roh ,udela kostku v zadane x,y,z                         x y z are coordinates for left upper corner, do cube on this place
129.
130.
131.     W = _WIDTH(texture&)
132.     H = _HEIGHT(texture&)
133.
134.     '                g                       h                                e                  f
135.     MAPQUAD x + -1.5, y + 1.5, z + -1.5, x + .5, y + 1.5, z + -1.5, x + -1.5, y + -.5, z + -1.5, x + .5, y + -.5, z - 1.5, texture&
136.     MAPQUAD x + -1, y + 1, z + -1, x + 1, y + 1, z + -1, x + -1.5, y + 1.5, z + -1.5, x + .5, y + 1.5, z + -1.5, texture&
137.     MAPQUAD x + -1.5, y + -.5, z + -1.5, x + .5, y + -.5, z - 1.5, x + -1, y + -1, z + -1, x + 1, y - 1, z - 1, texture& '
138.     MAPQUAD x + -1, y + 1, z + -1, x + -1.5, y + 1.5, z + -1.5, x + -1, y + -1, z + -1, x + -1.5, y + -.5, z + -1.5, texture&
139.     MAPQUAD x + .5, y + 1.5, z + -1.5, x + .5, y + -.5, z - 1.5, x + 1, y - 1, z - 1, x + 1, y + 1, z + -1, texture&
140.     '                a                     b                    c                       d
141.     MAPQUAD x + -1, y + 1, z + -1, x + 1, y + 1, z + -1, x + -1, y + -1, z + -1, x + 1, y - 1, z - 1, texture&
142.
143.
144.
145.
146.
147. SUB MAPQUAD (x1, y1, z1, x2, y2, z2, x3, y3, z3, x4, y4, z4, texture AS LONG)
148.     W = _WIDTH(texture&)
149.     H = _HEIGHT(texture&)
150.     GOTO nerot 'comment it for show, how it hat not to see...
151.
152.     po = _PI(2) / 4
153.
154.     s1 = SIN(rot + (1 * po)) * x1
155.     c1 = COS(rot + (1 * po)) * y1
156.
157.     s2 = SIN(rot + (2 * po)) * x2
158.     c2 = COS(rot + (2 * po)) * y2
159.
160.     s3 = SIN(rot + (3 * po)) * x3
161.     c3 = COS(rot + (3 * po)) * y3
162.
163.     s4 = SIN(rot + (4 * po)) * x4
164.     c4 = COS(rot + (4 * po)) * y4
165.
166.     x1 = x1 + s1: y1 = y1 + c1
167.     x3 = x3 + s3: y3 = y3 + c3
168.
169.     x2 = x2 + s2: y2 = y2 + c2
170.     x4 = x4 + s4: y4 = y4 + c4
171.
172.     nerot:
173.     _MAPTRIANGLE (0, 0)-(W, 0)-(0, H), texture& TO(x1, y1, z1)-(x2, y2, z2)-(x3, y3, z3)
174.     _MAPTRIANGLE (W, 0)-(0, H)-(W, H), texture& TO(x2, y2, z2)-(x3, y3, z3)-(x4, y4, z4)
175.
176. SUB init
177.     text\$ = " Petr" 'width = 32 pixels (records)
178.
179.     virtual& = _NEWIMAGE(100, 100, 256)
180.     _DEST virtual&
181.     PRINT text\$
182.     _SOURCE virtual&
183.     i = 0
184.     FOR Y = 17 TO 0 STEP -1
185.         FOR X = 0 TO 50
186.             IF POINT(X, Y) <> 0 THEN
187.                 T(i).x = (-8.5 + X)
188.                 T(i).y = -18 + (16 - Y) * 2
189.                 T(i).z = -5 - X
190.             i = i + 1
191.     NEXT X, Y
192.     _DEST 0: _SOURCE 0: _FREEIMAGE virtual&
193.     i = 0
194.
195.
196. SUB clock (x, y)
197.     de = _DEST
198.     clocka& = _NEWIMAGE(100, 100, 32)
199.     _DEST clocka&
200.     vterina = VAL(RIGHT\$(TIME\$, 2))
201.     hodina = VAL(LEFT\$(TIME\$, 2))
202.     minuta = VAL(MID\$(TIME\$, 4, 2))
203.
204.     IF hodina > 12 THEN hodina = hodina - 12
205.     hodina = hodina + (1 / 59) * minuta
206.
207.
208.     vt = vterina + 45
209.     ho = hodina + 45
210.     mi = minuta + 45
211.
212.     pozicevterina = _PI(2) / 60 * vt
213.     poziceminuta = _PI(2) / 60 * ho * 5
214.     pozicehodina = _PI(2) / 60 * mi
215.
216.     xs = 50 + COS(pozicevterina) * 30
217.     ys = 50 + SIN(pozicevterina) * 30
218.
219.     xm = 50 + COS(poziceminuta) * 35
220.     ym = 50 + SIN(poziceminuta) * 35
221.
222.     xh = 50 + COS(pozicehodina) * 40
223.     yh = 50 + SIN(pozicehodina) * 40
224.
225.     FOR n = 1 TO 100
226.         LINE (n, 0)-(n, 99), _RGB32(127 - n, n, 27 + n), BF
227.     NEXT n
228.     LINE (0, 0)-(99, 99), _RGB32(255, 255, 255), B
229.
230.     COLOR _RGBA32(127, 127, 127, 150)
231.     _PRINTSTRING (35, 45), "QB64"
232.     COLOR _RGB32(255, 255, 255)
233.
234.
235.     LINE (50, 50)-(xh, yh), _RGB32(255, 255, 0)
236.     LINE (50, 50)-(xm, ym), _RGB32(255, 255, 0)
237.     LINE (50, 50)-(xs, ys), _RGB32(0, 255, 255)
238.     m = 0
239.     FOR kruh = 0 TO _PI(2) STEP _PI(2) / 60
240.         PSET (50 + COS(kruh) * 47, 50 + SIN(kruh) * 47)
241.         IF m MOD 5 = 0 THEN LINE (50 + COS(kruh) * 47, 50 + SIN(kruh) * 47)-(50 + COS(kruh) * 44, 50 + SIN(kruh) * 44), , BF
242.         m = m + 1
243.     NEXT kruh
244.     _DEST de
245.     _SETALPHA 100, , clocka&
246.     _PUTIMAGE (x, y), clocka&, de
247.     _FREEIMAGE clocka&
248.

#### Ashish

• The joy of coding is endless.
##### Re: MAPTRIANGLE in 3D
« Reply #17 on: January 09, 2019, 05:37:38 AM »
Hi Petr! It is nicely done... 3D Text Effect is awesome! I like how the texture changes in real-time.
if (Me.success) {Me.improve()} else {Me.tryAgain()}

My Projects - https://github.com/AshishKingdom?tab=repositories

#### Petr

• The best code is the DNA of the hops.
##### Re: MAPTRIANGLE in 3D
« Reply #18 on: January 09, 2019, 10:51:04 AM »
Thank you, Ashish. I'm glad you like it.

#### FellippeHeitor

• QB64 Developer
• LET IT = BE
##### Re: MAPTRIANGLE in 3D
« Reply #19 on: January 09, 2019, 11:11:00 AM »
Oh! No SUB _GL! That's impressive.

#### johnno56

• Live long and prosper.
##### Re: MAPTRIANGLE in 3D
« Reply #20 on: January 09, 2019, 03:23:49 PM »
Petr,

Most of 'how that works' is WAY over my head... I, for one, didn't think these types of effects could be done using only Basic. Well done! I'm impressed! Brilliant!

J
Logic is the beginning of wisdom.

#### bplus

##### Re: MAPTRIANGLE in 3D
« Reply #21 on: January 09, 2019, 08:54:35 PM »
Another awesome effort Petr, I like how you made block letters from a 2D print and used live clocks for a texture.
B = B + ...

#### Petr

• The best code is the DNA of the hops.
##### Re: MAPTRIANGLE in 3D
« Reply #22 on: January 10, 2019, 03:52:11 PM »
Thank you all very much for your feedback. :-D

#### TempodiBasic

##### Re: MAPTRIANGLE in 3D
« Reply #23 on: January 13, 2019, 12:22:46 PM »
very cool this 3d demo (more the last without gl)

#### Petr

• The best code is the DNA of the hops.
##### Re: MAPTRIANGLE in 3D: ROOM
« Reply #24 on: February 01, 2019, 04:32:56 PM »
So if you liked the previous program, I wonder what you will say about this. Exactly in this style like this program I will continue. The program will allow you a virtual tour of my kitchen where I write programs. Excuse the exaggerated size of the room, in fact it's half, I guessed it. Textures are only approximate. If anyone would like to explain some details of this program, ask, I will to answer later.
This whole program is written again without OpenGL commands, only with MAPTRIANGLE 3D. Use arrows to control, end with Esc.

Code: QB64 [Select]
1. DIM SHARED lX, lY, rXx, rY, mX, mY, ballX AS INTEGER, ballY AS INTEGER, m&, leftplr, rightplr
2. m& = _NEWIMAGE(320, 240, 32)
3. lX = 10: lY = 10: rxX = 310: rY = 10
4. ballX = 160: ballY = 10: mY = -1: IF RND * 10 > 5 THEN mX = 1 ELSE mX = -1
5. DIM SHARED dub AS LONG, aluminium AS LONG
6.
7.
8.
10. extractpmf ("textures.pmf")
11.
14. str& = strop&
15. tokno& = okno&
16. dvere& = spajz_dvere&
19. orechsv& = Zesvetli("dekor orech.jpg")
22. tdub& = Ztmav("dub.jpg")
23.
34.
35.
36. SCREEN _NEWIMAGE(800, 600, 32)
37.
38. CX = 0: CY = 0: CZ = -1 '
39. N = 1116 'used quads (also this room contains 2232 triangles)
40.
41.
42.     X AS SINGLE '                                                                  source X points in standard view
43.     Y AS SINGLE '                                                                  source Y points in standard view
44.     Z AS SINGLE '                                                                  not use yet
45.     pi AS SINGLE '                                                                 start draw position on radius
46.     piH AS SINGLE '
47.     Radius AS SINGLE '                                                             radius (every point use own, but if is CX and CY in middle, are all the same)
49.     wX AS SINGLE '                                                                 working coordinates
50.     wY AS SINGLE
51.     wZ AS SINGLE
52.
53.     T AS LONG '                                                                    texture number for current triangle
54.     Tm AS SINGLE '                                                                 texture multiplicier. 1 for one.
55.
56.
57. DIM SHARED v(1 TO N) AS V
58.
59. '         A          B        C         D
60. DATA -10,-2,-5,-10,-2,10,10,-2,-5,10,-2,10: ' floor coordinates
61. DATA -10,2,-5,-10,2,10,10,2,-5,10,2,10: '     roof coordinates
62. DATA -10,-2,-5,-10,-2,10,-10,2,-5,-10,2,10: ' wall + window
63. DATA -5,-2,8,-10,-2,8,-5,2,8,-10,2,8
64. 'refrigerator
65. DATA -5,-2,8,-5,-2.1,10,-5,2.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1.7,-1.1,7.5
110. DATA -2.2,-1,3.5,-2.2,-1,7.5,-2.2,-1.1,3.5,-2.2,-1.1,7.5
111. 'desk
112. DATA 1.8,-1,3.4,-2.3,-1,3.4,1.8,-1,7.6,-2.3,-1,7.6
113. DATA 1.8,-.9,3.4,-2.3,-.9,3.4,1.8,-.9,7.6,-2.3,-.9,7.6
114. DATA 1.8,-.9,3.4,-2.3,-.9,3.4,1.8,-1,3.4,-2.3,-1,3.4
115. DATA 1.8,-.9,7.6,-2.3,-.9,7.6,1.8,-1,7.6,-2.3,-1,7.6
116. DATA 1.8,-.9,3.4,1.8,-1,3.4,1.8,-.9,7.6,1.8,-1,7.6
117. DATA -2.3,-.9,3.4,-2.3,-1,3.4,-2.3,-.9,7.6,-2.3,-1,7.6
118. 'chair
119. DATA .3,-2,3.9,.4,-2,3.9,.3,-1.5,3.9,.4,-1.5,3.9
120. DATA .3,-2,3.8,.4,-2,3.8,.3,-1.5,3.8,.4,-1.5,3.8
121. DATA .3,-2,3.8,.3,-2,3.9,.3,-1.5,3.8,.3,-1.5,3.9
122. DATA .4,-2,3.8,.4,-2,3.9,.4,-1.5,3.8,.4,-1.5,3.9
123. DATA -.7,-2,3.9,-.8,-2,3.9,-.7,-1.5,3.9,-.8,-1.5,3.9
124. DATA -.7,-2,3.8,-.8,-2,3.8,-.7,-1.5,3.8,-.8,-1.5,3.8
125. DATA -.7,-2,3.8,-.7,-2,3.9,-.7,-1.5,3.8,-.7,-1.5,3.9
126. DATA -.8,-2,3.8,-.8,-2,3.9,-.8,-1.5,3.8,-.8,-1.5,3.9
127. DATA .3,-2,3,.4,-2,3,.3,-1.5,3,.4,-1.5,3
128. DATA .3,-2,3.1,.4,-2,3.1,.3,-1.5,3.1,.4,-1.5,3.1
129. DATA .3,-2,3.1,.3,-2,3,.3,-1.5,3.1,.3,-1.5,3
130. DATA .4,-2,3.1,.4,-2,3,.4,-1.5,3.1,.4,-1.5,3
131. DATA -.7,-2,3,-.8,-2,3,-.7,-1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ATA -2.4,-1.5,4.7,-2.4,-1.5,6,-2.6,0,4.7,-2.6,0,6
172. DATA -2.3,-1.5,4.7,-2.5,-1.5,4.7,-2.5,0,4.7,-2.7,0,4.7
173. DATA -2.3,-1.5,6,-2.5,-1.5,6,-2.5,0,6,-2.7,0,6
174. 'here is wall at the computer
175. DATA 10,-2,-5,10,-2,0,10,2.1,-5,10,2.1,0
176. DATA 10,-2,5,10,-2,0,10,2,5,10,2,0
177. DATA 10,-2,10,10,-2,5,10,2.1,10,10,2.1,5
178. 'here is the PC table
179. DATA 10,-2,8,9.8,-2,8,10,-.7,8,9.8,-.7,8
180. DATA 9.8,-2,8,9.8,-.7,8,9.8,-2,10,9.8,-.7,10
181. DATA 4.4,-2,8,4.6,-2,8,4.4,-.7,8,4.6,-.7,8
182. DATA 4.6,-2,8,4.6,-.7,8,4.6,-2,10,4.6,-.7,10
183. DATA 9.8,-.7,9.8,4.6,-.7,9.8,9.8,-1.5,9.8,4.6,-1.5,9.8
184. DATA 9.8,-1.5,9.8,4.6,-1.5,9.8,9.8,-1.5,10,4.6,-1.5,10
185. DATA 7.5,-2,8,7.7,-2,8,7.5,-.7,8,7.7,-.7,8
186. DATA 7.5,-2,8,7.5,-.7,8,7.5,-2,9.8,7.5,-.7,9.8
187. DATA 7.7,-2,8,7.7,-.7,8,7.7,-2,9.8,7.7,-.7,9.8
188. DATA 9.8,-2,8.3,7.5,-2,8.3,9.8,-1.8,8.3,7.5,-1.8,8.3
189. DATA 9.8,-1.75,8.1,7.5,-1.75,8.1,9.8,-1.25,8.1,7.5,-1.25,8.1
190. DATA 9.8,-1.2,8.1,7.5,-1.2,8.1,9.8,-.9,8.1,7.5,-.9,8.1
191. DATA 9.8,-1.75,8.1,7.5,-1.75,8.1,9.8,-1.75,9,7.5,-1.75,9
192. DATA 9.8,-1.2,8.1,7.5,-1.2,8.1,9.8,-1.2,9,7.5,-1.2,9
193. DATA 9.8,-.9,8.1,7.5,-.9,8.1,9.8,-.9,9,7.5,-.9,9
194. DATA 9.8,-2,9.8,7.5,-2,9.8,9.8,-.7,9.8,7.5,-.7,9.8
195. DATA 10,-.7,7.9,4.4,-.7,7.9,10,-.5,7.9,4.4,-.5,7.9
196. DATA 10,-.7,7.9,4.4,-.7,7.9,10,-.7,10,4.4,-.7,10
197. DATA 10,-.5,7.9,4.4,-.5,7.9,10,-.5,10,4.4,-.5,10
198. 'compputer
199. DATA 5,-2,8,5,-2,8.5,5,-1.5,8,5,-1.5,8.5
200. DATA 5,-1.5,8,5,-1.5,8.5,4.7,-1.5,8,4.7,-1.5,8.5
201. DATA 4.7,-2,8,4.7,-2,8.5,4.7,-1.5,8,4.7,-1.5,8.5
202. DATA 4.7,-2,8,5,-2,8,4.7,-1.5,8,5,-1.5,8
203. 'monitor
204. DATA 9.7,-.3,8.5,     7.7,-.3,9.6,   9.7,1,8.5,     7.7,1,9.6
205. DATA 9.7,-.3,8.6,9.7,1,8.6,7.7,-.3,9.7,7.7,1,9.7
206. DATA 7.7,-.3,9.6,7.7,1,9.6,7.7,-.3,9.7,7.7,1,9.7
207. DATA 9.7,-.3,8.6,9.7,-.5,8.6,7.7,-.3,9.7,7.7,-.5,9.7
208. DATA 9.2,-.49,8.6,8.2,-.49,8.6,9.2,-.49,10,8.2,-.49,10
209. 'keyboard
210. DATA 6.5,-.45,7.9,5.7,-.45,7.9,6.5,-.39,8.2,5.7,-.39,8.2: 'just shifted in space a 2D texture, not really 3D
211. DATA 5.3,-.45,7.9,5,-.45,7.9,5.3,-.39,8,5,-.39,8: 'mouse - as keyboard
212. 'subwoofer
213. DATA 7.4,-2,9.8,7.4,-2,9,7.4,-1.5,9.8,7.4,-1.5,9
214. DATA 7,-2,9.8,7,-2,9,7,-1.5,9.8,7,-1.5,9
215. DATA 7.4,-2,9.8,7,-2,9.8,7.4,-1.5,9.8,7,-1.5,9.8
216. DATA 7.4,-1.5,9.8,7,-1.5,9.8,7.4,-1.5,9,7,-1.5,9
217. DATA 7.4,-2,9,7,-2,9,7.4,-1.5,9,7,-1.5,9
218. 'speaker right
219. DATA 4.7,-.5,10,4.7,0,10,4.7,-.5,9.7,4.7,0,9.7
220. DATA 4.41,-.5,10,4.41,0,10,4.41,-.5,9.7,4.41,0,9.7
221. DATA 4.41,0,10,4.41,0,9.7,4.7,0,10,4.7,0,9.7
222. DATA 4.7,-.5,9.7,4.41,-.5,9.7,4.7,0,9.7,4.41,0,9.7
223. 'speaker left
224. DATA 6.7,-.5,10,6.7,0,10,6.7,-.5,9.7,6.7,0,9.7
225. DATA 6.41,-.5,10,6.41,0,10,6.41,-.5,9.7,6.41,0,9.7
226. DATA 6.41,0,10,6.41,0,9.7,6.7,0,10,6.7,0,9.7
227. DATA 6.7,-.5,9.7,6.41,-.5,9.7,6.7,0,9.7,6.41,0,9.7
228.
229. 'wall with kitchen unit, again walls with doors first
230. DATA 10,-2,-5,5,-2,-5,10,2,-5,5,2,-5
231. DATA -10,-2,-4.99,7,-2,-4.99,-10,1,-4.99,7,1,-4.99
232. DATA -10,2,-4.99,7,2,-4.99,-10,1,-4.99,7,1,-4.99
233. DATA 5,-2,-3.5,7,-2,-3.5,5,-0.5,-3.5,7,-0.5,-3.5
234. DATA 5,-.5,-3.5,7,-.5,-3.5,5,-.5,-4.9,7,-.5,-4.9
235. DATA 5,-2,-3.5,5,-.5,-3.5,5,-2,-4.9,5,-.5,-4.9
236. DATA 7,-2,-3.5,7,-.5,-3.5,7,-2,-4.9,7,-.5,-4.9
237. DATA 5,-2,-4.9,7,-2,-4.9,5,-0.5,-4.9,7,-0.5,-4.9
238.
239. 'gas cooker
240. DATA 4.9,-2,-4.9,4.9,-.5,-4.9,4.9,-2,-3.5,4.9,-.5,-3.5
241. DATA 4.9,-.5,-3.4,-2.99,-.5,-3.4,4.9,-.5,-4.9,-2.99,-.5,-4.9
242. DATA 4.9,-.6,-3.4,-2.99,-.6,-3.4,4.9,-.6,-4.9,-2.99,-.6,-4.9
243. DATA 4.9,-.6,-3.4,-2.99,-.6,-3.4,4.9,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.6,-4.9
279. DATA -9.99,-.6,-3.4,-3.7,-.6,-3.4,-9.99,-.5,-3.4,-3.7,-.5,-3.4
280. DATA -3.7,-.6,-3.4,-2.99,-.6,-3.4,-3.7,-.5,-3.4,-2.99,-.5,-3.4
281. DATA -3.7,-.5,-3.4,-2.99,-.5,-3.4,-3.7,-.5,-3.75,-2.99,-.5,-3.75
282. DATA -3.7,-.5,-4.7,-2.99,-.5,-4.7,-3.7,-.5,-4.9,-2.99,-.5,-4.9
283. 'SINK:
284. DATA -3.7,-.5,-3.75,-2.99,-.5,-3.75,-3.7,-.9,-3.75,-2.99,-.9,-3.75
285. DATA -3.7,-.5,-4.7,-2.99,-.5,-4.7,-3.7,-.9,-4.7,-2.99,-.9,-4.7
286. DATA -3.7,-.5,-3.75,-3.7,-.5,-4.7,-3.7,-.9,-3.75,-3.7,-.9,-4.7
287. DATA -2.99,-.5,-3.75,-2.99,-.5,-4.7,-2.99,-.9,-3.75,-2.99,-.9,-4.7
288. DATA -3.7,-.9,-3.75,-3.7,-.9,-4.7,-2.99,-.9,-3.75,-2.99,-.9,-4.7
289.
290.
291. DATA -3.2,-.1,-4.89,-3.5,-.1,-4.89,-3.2,-.1,-4.69,-3.5,-.1,-4.69
292. DATA -3.2,-.2,-4.89,-3.5,-.2,-4.89,-3.2,-.2,-4.69,-3.5,-.2,-4.69
293. DATA -3.2,-.1,-4.69,-3.5,-.1,-4.69,-3.2,-.2,-4.69,-3.5,-.2,-4.69
294. DATA -3.2,-.1,-4.69,-3.2,-.2,-4.69,-3.2,-.1,-4.89,-3.2,-.2,-4.89
295. DATA -3.5,-.1,-4.69,-3.5,-.2,-4.69,-3.5,-.1,-4.89,-3.5,-.2,-4.89
296.
297. DATA -10.1,-2,-4.9,4.9,-2,-4.9,-10.1,-.49,-4.9,4.9,-.49,-4.9
298. DATA -10.1,-1.99,-5,4.9,-1.99,-5,-10.1,-1.99,-3.7,4.9,-1.99,-3.7
299. DATA -10.1,.8,-4.9,4.9,.8,-4.9,-10.1,1.6,-4.9,4.9,1.6,-4.9
300. 'cabinet doors
301. DATA 1.85,1.55,-3.71,1.85,0.6,-3.71,2.8,1.55,-3.71,2.8,0.6,-3.71
302. DATA 1.85,-1.9,-3.71,1.85,-0.6,-3.71,2.8,-1.9,-3.71,2.8,-.6,-3.71
303. DATA 2.85,1.55,-3.71,2.85,0.6,-3.71,3.8,1.55,-3.71,3.8,0.6,-3.71
304. DATA 2.85,-1.9,-3.71,2.85,-0.6,-3.71,3.8,-1.9,-3.7,3.8,-.6,-3.71
305. DATA 3.85,1.55,-3.71,3.85,0.6,-3.71,4.8,1.55,-3.71,4.8,0.6,-3.71
306. DATA 3.85,-1.9,-3.71,3.85,-0.6,-3.71,4.8,-1.9,-3.71,4.8,-.6,-3.71
307. DATA .85,1.55,-3.71,.85,0.6,-3.71,1.8,1.55,-3.71,1.8,0.6,-3.71
308. DATA .85,-1.9,-3.71,.85,-0.6,-3.71,1.8,-1.9,-3.71,1.8,-.6,-3.71
309. DATA -1.85,1.55,-3.71,-1.85,0.6,-3.71,-2.8,1.55,-3.71,-2.8,0.6,-3.71
310. DATA -1.85,-1.9,-3.71,-1.85,-0.6,-3.71,-2.8,-1.9,-3.71,-2.8,-.6,-3.71
311. DATA -2.85,1.55,-3.71,-2.85,0.6,-3.71,-3.8,1.55,-3.71,-3.8,0.6,-3.71
312. DATA -2.85,-1.9,-3.71,-2.85,-0.6,-3.71,-3.8,-1.9,-3.7,-3.8,-.6,-3.71
313. DATA -3.85,1.55,-3.71,-3.85,0.6,-3.71,-4.8,1.55,-3.71,-4.8,0.6,-3.71
314. DATA -3.85,-1.9,-3.71,-3.85,-0.6,-3.71,-4.8,-1.9,-3.71,-4.8,-.6,-3.71
315. DATA -.85,1.55,-3.71,-.85,0.6,-3.71,-1.8,1.55,-3.71,-1.8,0.6,-3.71
316. DATA -.85,-1.9,-3.71,-.85,-0.6,-3.71,-1.8,-1.9,-3.71,-1.8,-.6,-3.71
317. DATA -4.85,1.55,-3.71,-4.85,0.6,-3.71,-5.8,1.55,-3.71,-5.8,0.6,-3.71
318. DATA -4.85,-1.9,-3.71,-4.85,-0.6,-3.71,-5.8,-1.9,-3.7,-5.8,-.6,-3.71
319. DATA -5.85,1.55,-3.71,-5.85,0.6,-3.71,-6.8,1.55,-3.71,-6.8,0.6,-3.71
320. DATA -5.85,-1.9,-3.71,-5.85,-0.6,-3.71,-6.8,-1.9,-3.71,-6.8,-.6,-3.71
321. DATA -6.85,1.55,-3.71,-6.85,0.6,-3.71,-7.8,1.55,-3.71,-7.8,0.6,-3.71
322. DATA -6.85,-1.9,-3.71,-6.85,-0.6,-3.71,-7.8,-1.9,-3.71,-7.8,-.6,-3.71
323. DATA -9.98,-2,-5,-9.98,1,-5,-9.98,-2,0,-9.98,1,0
324. DATA -9.97,-0.5,-3.4,-8.47,-.5,-3.4,-9.97,-0.5,0,-8.47,-.5,0
325. DATA -9.97,-0.6,-3.4,-8.47,-.6,-3.4,-9.97,-0.6,0,-8.47,-.6,0
326. DATA -9.97,.6,-3.7,-8.77,.6,-3.7,-9.97,.6,0,-8.77,.6,0
327. DATA -9.97,.7,-3.7,-8.77,.7,-3.7,-9.97,.7,0,-8.77,.7,0
328. DATA -9.97,1.6,-3.7,-8.77,1.6,-3.7,-9.97,1.6,0,-8.77,1.6,0
329. DATA -9.97,1.7,-3.7,-8.77,1.7,-3.7,-9.97,1.7,0,-8.77,1.7,0
330. DATA -9.97,-2,0,-8.77,-2,0,-9.97,-0.6,0,-8.77,-0.6,0
331. DATA -9.97,1.6,0,-8.77,1.6,0,-9.97,0.7,0,-8.77,0.7,0
332. DATA -9.97,-2,-.2,-8.77,-2,-.2,-9.97,-0.6,-.2,-8.77,-0.6,-.2
333. DATA -9.97,1.6,-.2,-8.77,1.6,-.2,-9.97,0.7,-.2,-8.77,0.7,-.2
334. DATA -9.97,1.7,0,-8.77,1.7,0,-9.97,1.6,0,-8.77,1.6,0
335. DATA -9.97,-.5,0,-8.47,-.5,0,-9.97,-.6,0,-8.47,-.6,0
336. DATA -9.97,.6,0,-8.77,.6,0,-9.97,.7,0,-8.77,.7,0
337. DATA -8.77,1.7,0,-8.77,1.6,0,-8.77,1.7,-3.7,-8.77,1.6,-3.7
338. DATA -8.47,-.5,0,-8.47,-.6,0,-8.47,-0.5,-3.7,-8.47,-0.6,-3.7
339. DATA -8.77,.7,0,-8.77,.6,0,-8.77,.7,-3.7,-8.77,.6,-3.7
340. DATA -8.77,-2,0,-8.77,-.6,0,-8.77,-2,-0.2,-8.77,-.6,-0.2
341. DATA -8.77,1.6,0,-8.77,.7,0,-8.77,1.6,-0.2,-8.77,.7,-0.2
342. DATA -8.77,-2,-1.9,-8.77,-.6,-1.9,-8.77,-2,-2,-8.77,-.6,-2
343. DATA -8.77,1.6,-1.9,-8.77,.7,-1.9,-8.77,1.6,-2,-8.77,.7,-2
344. DATA -8.77,-1.99,0,-9.97,-1.99,0,-8.77,-1.99,-3.7,-9.97,-1.99,-3.7
345. DATA -9.97,-2,0,-9.97,-2,-4.9,-9.97,-.5,0,-9.97,-.5,-4.9
346. DATA -9.97,1.6,0,-9.97,1.6,-4.9,-9.97,.6,0,-9.97,.6,-4.9
347. DATA -8.77,-2,-3.7,-8.77,-.6,-3.7,-8.77,-2,-3.6,-8.77,-.6,-3.6
348. DATA -8.77,1.6,-3.7,-8.77,.7,-3.7,-8.77,1.6,-3.6,-8.77,.7,-3.6
349.
350. DATA -8.77,-1.9,-2,-8.77,-.6,-2,-8.77,-1.9,-3.6,-8.77,-.6,-3.6
351. DATA -8.77,1.6,-2,-8.77,.7,-2,-8.77,1.6,-3.6,-8.77,.7,-3.6
352.
353. DATA -8.77,-1.9,-.2,-8.77,-.6,-.2,-8.77,-1.9,-1.9,-8.77,-.6,-1.9
354. DATA -8.77,1.6,-.2,-8.77,.7,-.2,-8.77,1.6,-1.9,-8.77,.7,-1.9: 'glased doors
355. DATA -7.85,1.55,-3.71,-7.85,0.6,-3.71,-8.8,1.55,-3.71,-8.8,0.6,-3.71
356. DATA -7.85,-1.9,-3.71,-7.85,-0.6,-3.71,-8.8,-1.9,-3.71,-8.8,-.6,-3.71
357. DATA .85,1.55,-3.71,.85,0.6,-3.71,-.85,1.55,-3.71,-.85,0.6,-3.71
358. DATA .85,-1.9,-3.71,.85,-0.6,-3.71,-.85,-1.9,-3.71,-.85,-.6,-3.71
359.
360. 'microwave
361.
362. DATA -9,-.5,-4.1,-8,-.5,-4.1,-9,0,-4.1,-8,0,-4.1
363. DATA -9,-.5,-4.9,-8,-.5,-4.9,-9,0,-4.9,-8,0,-4.9
364. DATA -9,0,-4.1,-8,0,-4.1,-9,0,-4.9,-8,0,-4.9
365. DATA -9,0,-4.1,-9,-.5,-4.1,-9,0,-4.9,-9,-.5,-4.9
366. DATA -8,0,-4.1,-8,-.5,-4.1,-8,0,-4.9,-8,-.5,-4.9
367.
368.
369.
370. FOR r = 1 TO N
371.    READ v(r).X, v(r).Y, v(r).Z 'all is placed on the same Y = the same floor
372.
373. Set_texture podl&, 1, 4, 15 'set image img as texture for bottom  (triangles 1 to 4)
374. Set_texture str&, 5, 8, 3
375. Set_texture tokno&, 9, 12, 1
376. Set_texture dvere&, 13, 16, 1
377. Set_texture white&, 17, 20, 1
378. Set_texture white&, 21, 24, 1 'wall at pc
379. Set_texture lednice&, 25, 28, 1
380. Set_texture white&, 29, 32, 1
381. Set_texture Swhite&, 33, 36, 1
382. Set_texture Swhite&, 37, 40, 1
383. Set_texture orech&, 41, 44, 10
384. Set_texture orech&, 45, 48, 10
385.
386. Set_texture orech&, 49, 52, 10
387. Set_texture orech&, 53, 56, 10
388. Set_texture orech&, 57, 60, 10
389. Set_texture orech&, 61, 64, 10
390. Set_texture polstr&, 65, 68, 3
391.
392. Set_texture polstr&, 69, 72, 3
393. Set_texture polstr&, 73, 76, 3
394. Set_texture polstr&, 77, 80, 3
395. Set_texture orech&, 81, 84, 10
396. Set_texture orech&, 85, 88, 10
397. Set_texture orech&, 89, 92, 10
398. Set_texture orech&, 93, 96, 3
399. Set_texture orech&, 97, 100, 3
400. Set_texture orech&, 101, 104, 1
401. Set_texture orech&, 105, 108, 1
402. Set_texture orech&, 109, 112, 1
403. Set_texture orech&, 113, 116, 7
404.
405. Set_texture orech&, 117, 120, 1
406. Set_texture orech&, 121, 204, 2
407. Set_texture orechsv&, 205, 220, 1
408. Set_texture orech&, 221, 292, 1
409.
410. Set_texture orechsv&, 293, 308, 1
411. Set_texture orech&, 309, 316, 1
412. Set_texture orechsv&, 317, 328, 1
413. Set_texture orech&, 329, 400, 1
414. Set_texture orechsv&, 401, 416, 1
415. Set_texture orech&, 417, 424, 1
416. Set_texture orechsv&, 425, 432, 1
418. Set_texture white&, 433, 437, 1 'wall
419. Set_texture dvere&, 437, 440, 1
420. Set_texture white&, 441, 444, 1
421. Set_texture dub&, 445, 453, 1 'pc desk
422. Set_texture tdub&, 454, 462, 1 'pc desk back
423. Set_texture dub&, 463, 480, 1
424. Set_texture tdub&, 481, 484, 1
425. Set_texture dub&, 485, 492, 1
426. Set_texture tdub&, 493, 512, 1
427. Set_texture dub&, 513, 520, 1
428. Set_texture Black&, 521, 524, 1
429. Set_texture SBlack&, 525, 528, 1
430. Set_texture Black&, 529, 532, 1
431. Set_texture pc&, 533, 536, 1
432. Set_texture SBlack&, 537, 540, 1 'MONITOR
433. Set_texture Black&, 541, 548, 1 'MONITOR
434. Set_texture Noha&, 549, 552, 1 'MONITOR
435. Set_texture Black&, 553, 556, 1
436. Set_texture kbd&, 557, 560, 1 'keyboard
437. Set_texture mys&, 561, 564, 1 'keyboard
438. Set_texture Black, 565, 576, 1 'woof
439. Set_texture SBlack, 577, 580, 1 'subwoofer
440. Set_texture woof&, 581, 584, 1 'subwoofer
441. Set_texture Black, 585, 596, 1 'speakers
442. Set_texture speak&, 597, 600, 1
443. Set_texture Black, 601, 612, 1
444. Set_texture speak&, 613, 616, 1
446. Set_texture dvere&, 617, 620, 1 'doors
447. Set_texture dlazba&, 621, 624, 10
448. Set_texture white&, 625, 628, 1
449. Set_texture sporakcelo, 629, 632, 1
450. Set_texture sporakvrch, 633, 636, 1
451. Set_texture white&, 637, 648, 1
452. Set_texture dub&, 649, 652, 1
453. Set_texture tdub&, 653, 656, 5
454. Set_texture dub&, 657, 676, 5
455. Set_texture tdub&, 677, 680, 5
456. Set_texture dub&, 681, 796, 5
457. Set_texture tdub&, 797, 800, 5
458. Set_texture dub&, 801, 809, 5
459. Set_texture dub&, 809, 812, 5
460. Set_texture tdub&, 813, 816, 5
461. Set_texture tdub&, 817, 820, 5
462. Set_texture Silver&, 821, 836, 1
463. Set_texture SilverC&, 837, 840, 1
464. Set_texture SilverB&, 841, 860, 1
465. Set_texture dub&, 861, 872, 1
466. Set_texture tdub&, 873, 960, 1
467. Set_texture dlazba2&, 961, 964, 10
468. Set_texture tdub&, 965, 1004, 1
469. Set_texture dub&, 1005, 1064, 1
470. Set_texture tdub&, 1065, 1076, 1
471. Set_texture Sklo&, 1077, 1080, 1
472. Set_texture tdub&, 1081, 1096, 1
473. Set_texture mikro&, 1097, 1100, 1
474. Set_texture SilverB&, 1101, 1116, 1
475.
476.
477. valec -1, -.8, 4.7, -.6, 10, SilverB& ' vase
478. valec 6, -.5, 9, -.35, 10, Silver&
479.
480. valec -3.35, -.2, -4.8, -.3, 40, SilverB& 'water pipe
481. Zvalec -3.35, -.3, -4.8, -4.1, 40, SilverB& 'water pipe
482. valec -3.35, -.29, -4.1, -.4, 40, SilverB& 'water pipe
483.
484.
485. 'this three vase are in cabinet with glased door
486. talir -9.1, .8, -1.45
487. talir -9.1, .8, -1.05
488. talir -9.1, .8, -.65
489.
490. 'cabinet handles
495.
500.
505.
510.
527.
529.         i\$ = INKEY\$
530.         start = 0
531.         FOR r = 1 TO N
532.             LenX = v(r).X - CX
533.             LenY = v(r).Y - CY
534.             LenZ = v(r).Z - CZ
535.
536.             radius = SQR(LenX ^ 2 + LenZ ^ 2)
539.             radiusH =  SQR(lenY^2 + lenz^2)
542.             v(r).pi = JK!(CX, CZ, v(r).X, v(r).Z, radius)
543.             v(r).pih = jk! (cy,cz,v(r).y, v(r).z, radiusH)
544.            NEXT r
545.       IF ABS(rot) > _PI(2) THEN rot = 0
546.     oldposZ = posZ
547.     oldposX = posX
548.         CASE CHR\$(0) + CHR\$(72): posz = posz + COS(rot) / 2: posx = posx + -SIN(rot) / 2: posy = posy  + -SIN(roth)/2 'up
549.         CASE CHR\$(0) + CHR\$(80): posz = posz - COS(rot) / 2: posx = posx - -SIN(rot) / 2 : posy = posy - -SIN(roth)/2 'dn
550.         CASE CHR\$(0) + CHR\$(75): rot = rot - .05
551.         CASE CHR\$(0) + CHR\$(77): rot = rot + .05
552.         CASE CHR\$(27) : destructor ("textures.pmf") : SYSTEM
553.
554. '------------------------------
555. IF posz > 3 THEN posz = 3
556. IF posz < -7 THEN posz = -7
557. IF posx < -7 THEN posx = -7
558. IF posx > 7 THEN posx = 7
559.
560.
561. CASE -7 TO -5: IF posZ < -7 THEN posX = oldposx: posz = oldposz
562. CASE -5 TO 3: IF posZ < -2 THEN posX = oldposx: posz = oldposz
563. CASE 3 TO 6: IF posZ< -7 THEN posX = oldposx: posz = oldposz
564. '-----------------------------
565.     CZ = -posz
566.     CX = -posx
567.     CY = -posY
568.
569.     FOR r = 1 TO N
570.         x = CX + SIN(rot + v(r).pi) * v(r).Radius
571.         y = CY + SIN (rotH + v(r).piH) * v(r).radiusH
572.         z =  CZ + COS(rot +v(r).pi) * v(r).Radius
573.         v(r).wX = x + posx
574.         v(r).wY = y + posY
575.         v(r).wZ = z + posz
576.     NEXT r
577.     minigame
578.     m33& = _COPYIMAGE(m&, 33)
579.     Set_texture m33&, 537, 540, 1
580.
581.     FOR zz = 1 TO N STEP 4
582.          IF v(zz).T THEN
583.             img& = v(zz).T
584.             w = _WIDTH(img&)
585.             h = _HEIGHT(img&)
586.             num = v(zz).Tm
587.             IF num = 0 THEN num = 1
588.             _MAPTRIANGLE (0, h * num)-(w * num, h * num)-(0, 0), img& TO(v(zz).wX, v(zz).wY, v(zz).wZ)-(v(zz + 1).wX, v(zz + 1).wY, v(zz + 1).wZ)-(v(zz + 2).wX, v(zz + 2).wY, v(zz + 2).wZ), 0, _SMOOTH
589.             _MAPTRIANGLE (w * num, h * num)-(0, 0)-(w * num, 0), img& TO(v(zz + 1).wX, v(zz + 1).wY, v(zz + 1).wZ)-(v(zz + 2).wX, v(zz + 2).wY, v(zz + 2).wZ)-(v(zz + 3).wX, v(zz + 3).wY, v(zz + 3).wZ), 0, _SMOOTH
590.     NEXT zz
591.
592. REM    infobox posx, posy, posz, rot, minradius
593.
594.     _FREEIMAGE m33&
595.     _LIMIT 30
596.
597.
598. SUB INFOBOX (posx, posy, posz, rot, u)
599. nfo& = _NEWIMAGE (640, 480, 32)
600. W = 639 : H = 479: X = -.5: Y = 0 : Z = -1
601. de = _DEST
602. _DEST nfo&
603. COLOR _RGB32(22, 61, 78)
604. PRINT "INFOBOX:"
605. PRINT "Position X: "; posx
606. PRINT "Position Y: "; posy
607. PRINT "Position Z: "; posz
608. PRINT "Angle: "; ABS(_R2D(rot))
609.
610. hnfo& = _COPYIMAGE (nfo&, 33)
611. _MAPTRIANGLE (0,0) - (w, 0) - (0, h), hnfo& TO (-2+x, 2+Y, -2+z) - (2+x, 2+y, -2+z) - (-2+x, -2+y, -2+z)
612. _MAPTRIANGLE (w, 0) - (0, h) - (w,h), hnfo& TO (2+x, 2+y, -2+z) - (-2+x, -2+y, -2+z) - (2+x, -2+y, -2+z)
613.
614.
615.
616.
617.
619. tt = UBOUND(v) + 1
620. REDIM _PRESERVE v(1 TO tt - 1 + 12) AS V
621. N = N + 12
622. IF SGN(x)>= 0 THEN x2 = x + .2 ELSE x2 = x -.2
623. IF SGN(y) =>0 THEN y2 = y + .05 ELSE y2 = y -.05
624. IF SGN(z) < 0 THEN z2 = z -.1 ELSE z2 = z + .1
625.
626.  v(tt).x = x
627.  v(tt).y = y
628.  v(tt).z = z
629.
630.  v(tt+1).x = x
631.  v(tt+1).y = y2
632.  v(tt+1).z = z
633.
634.  v(tt+2).x = x2
635.  v(tt+2).y = y
636.  v(tt+2).z = z
637.
638.  v(tt+3).x = x2
639.  v(tt+3).y = y2
640.  v(tt+3).z = z
641.
642. '------------
643.
644.  v(tt+4).x = x
645.  v(tt+4).y = y
646.  v(tt+4).z = z
647.
648.  v(tt+5).x = x
649.  v(tt+5).y = y2
650.  v(tt+5).z = z
651.
652.  v(tt+6).x = x
653.  v(tt+6).y = y
654.  v(tt+6).z = z2
655.
656.  v(tt+7).x = x
657.  v(tt+7).y = y2
658.  v(tt+7).z = z2
659.
660. '------------
661.
662.  v(tt+8).x = x2
663.  v(tt+8).y = y
664.  v(tt+8).z = z
665.
666.  v(tt+9).x = x2
667.  v(tt+9).y = y2
668.  v(tt+9).z = z
669.
670.  v(tt+10).x = x2
671.  v(tt+10).y = y
672.  v(tt+10).z = z2
673.
674.  v(tt+11).x = x2
675.  v(tt+11).y = y2
676.  v(tt+11).z = z2
677.
678.  set_texture aluminium&, tt-1, tt+11,1
679.
680.
681.
683.     tt = UBOUND(v) + 1
684.     REDIM _PRESERVE v(1 TO tt - 1 + 12) AS V
685.     N = N + 12
686.
687. IF SGN(z)<= 0 THEN z2 = z - .2 ELSE z2 = z +.2
688. IF SGN(y) =>0 THEN y2 = y + .05 ELSE y2 = y -.05
689. IF SGN(x) <= 0 THEN x2 = x+.1 ELSE x2 = x - .1
690.
691. 'predni obdelnik
692.  v(tt).x = x2
693.  v(tt).y = y
694.  v(tt).z = z
695.
696.  v(tt+1).x = x2
697.  v(tt+1).y = y2
698.  v(tt+1).z = z
699.
700.  v(tt+2).x = x2
701.  v(tt+2).y = y
702.  v(tt+2).z = z2
703.
704.  v(tt+3).x = x2
705.  v(tt+3).y = y2
706.  v(tt+3).z = z2
707.
708. '------------
709.
710.  v(tt+4).x = x
711.  v(tt+4).y = y2
712.  v(tt+4).z = z
713.
714.  v(tt+5).x = x2
715.  v(tt+5).y = y2
716.  v(tt+5).z = z
717.
718.  v(tt+6).x = x
719.  v(tt+6).y = y
720.  v(tt+6).z = z
721.
722.  v(tt+7).x = x2
723.  v(tt+7).y = y
724.  v(tt+7).z = z
725.
726. '------------
727.
728.  v(tt+8).x = x
729.  v(tt+8).y = y2
730.  v(tt+8).z = z2
731.
732.  v(tt+9).x = x2
733.  v(tt+9).y = y2
734.  v(tt+9).z = z2
735.
736.  v(tt+10).x = x
737.  v(tt+10).y = y
738.  v(tt+10).z = z2
739.
740.  v(tt+11).x = x2
741.  v(tt+11).y = y
742.  v(tt+11).z = z2
743.
744.   set_texture aluminium&, tt-1, tt+11,1
745.
746. SUB Set_texture (num, start, eend, much)
747.     FOR s = start TO eend
748.         v(s).T = num
749.         v(s).Tm = much
750.     NEXT s
751.
752.
753. FUNCTION Hload& (fileName AS STRING)
756.
757.
758. FUNCTION SHload& (fileName AS STRING)
760.     _SETALPHA 0, _RGB32(255, 255, 255) TO _RGB32(200, 200, 200), h&
762.
763. FUNCTION strop&
764.     lamp& = _LOADIMAGE("bodovka mala.jpg", 32)
765.     strop& = _NEWIMAGE(1024, 768, 32)
766.     de = _DEST
767.     _DEST strop&
768.     CLS , _RGB32(255, 255, 255)
769.     rX = 1024 / 4
770.     rY = 768 / 3
771.     FOR x = rX TO 1024 - rX STEP rX
772.         FOR y = rY TO 768 - rY STEP rY
773.             _PUTIMAGE (rX, rY), lamp&, strop&
774.     NEXT y, x
775.     _DEST de
776.     _FREEIMAGE lamp&
777.     strop& = _COPYIMAGE(strop&, 33)
778.
779. FUNCTION okno&
782.     okno& = _NEWIMAGE(1024, 512, 32)
783.     de = _DEST
784.     _DEST okno&
785.     CLS , _RGB32(250, 245, 255)
786.     _PUTIMAGE (512 - 150, 206 - 132), ok&, okno&
787.
788.     _PUTIMAGE (380, 370), topco&, okno&
789.     _DEST de
790.     _FREEIMAGE ok&
791.     _FREEIMAGE topco&
792.     okno& = _COPYIMAGE(okno&, 33)
793.
794. FUNCTION white&
795.     IF white& = 0 THEN
796.         whit& = _NEWIMAGE(100, 100, 32)
797.         de = _DEST
798.         _DEST whit&
799.         CLS , _RGB32(250, 240, 250)
800.         _DEST de
801.         white& = _COPYIMAGE(whit&, 33)
802.         _FREEIMAGE whit&
803.
804. FUNCTION Swhite&
805.     IF Swhite& = 0 THEN
806.         whit& = _NEWIMAGE(100, 100, 32)
807.         de = _DEST
808.         _DEST whit&
809.         CLS , _RGB32(255, 255, 255)
810.         _DEST de
811.         Swhite& = _COPYIMAGE(whit&, 33)
812.         _FREEIMAGE whit&
813.
814.
815. FUNCTION Braun&
816.     IF Braun& = 0 THEN
817.         brau& = _NEWIMAGE(100, 100, 32)
818.         de = _DEST
819.         _DEST brau&
820.         CLS , _RGB32(111, 17, 39)
821.         _DEST de
822.         Braun& = _COPYIMAGE(brau&, 33)
823.         _FREEIMAGE brau&
824.
825.
826. FUNCTION Black&
827.     IF Black& = 0 THEN
828.         blk& = _NEWIMAGE(100, 100, 32)
829.         de = _DEST
830.         _DEST blk&
831.         CLS , _RGB32(6, 17, 28)
832.         _DEST de
833.         Black& = _COPYIMAGE(blk&, 33)
834.         _FREEIMAGE blk&
835.
836. FUNCTION SBlack&
837.     IF SBlack& = 0 THEN
838.         blk& = _NEWIMAGE(100, 100, 32)
839.         de = _DEST
840.         _DEST blk&
841.         CLS , _RGB32(33, 28, 28)
842.         _DEST de
843.         SBlack& = _COPYIMAGE(blk&, 33)
844.         _FREEIMAGE blk&
845.
846. FUNCTION Silver&
847.     IF Silver& = 0 THEN
848.         blk& = _NEWIMAGE(100, 100, 32)
849.         de = _DEST
850.         _DEST blk&
851.         e = 127 / 100
852.         FOR l = 0 TO 99
853.             LINE (0, l)-(99, l), _RGB32(255 - f, 255 - f, 255 - f)
854.             f = f + e
855.         NEXT l
856.         _DEST de
857.         Silver& = _COPYIMAGE(blk&, 33)
858.         _FREEIMAGE blk&
859.
860. FUNCTION SilverB&
861.     IF SilverB& = 0 THEN
862.         blk& = _NEWIMAGE(100, 100, 32)
863.         de = _DEST
864.         _DEST blk&
865.         e = 127 / 50
866.         FOR l = 0 TO 50
867.             LINE (l, l)-(100 - l, 100 - l), _RGB32(127 + f, 127 + f, 127 + f), B
868.             f = f + e
869.         NEXT l
870.         _DEST de
871.         SilverB& = _COPYIMAGE(blk&, 33)
872.         _FREEIMAGE blk&
873.
874.
875. FUNCTION SilverC&
876.     IF SilverC& = 0 THEN
877.         blk& = _NEWIMAGE(100, 100, 32)
878.         de = _DEST
879.         _DEST blk&
880.         e = 127 / 50
881.         FOR l = 0 TO 50
882.             LINE (l, l)-(100 - l, 100 - l), _RGB32(255 - f, 255 - f, 255 - f), B
883.             f = f + e
884.         NEXT l
885.         _DEST de
886.         SilverC& = _COPYIMAGE(blk&, 33)
887.         _FREEIMAGE blk&
888.
889.
890. FUNCTION spajz_dvere&
891.     dv& = _LOADIMAGE("dvere.jpg", 32) '192 x 426
892.     de = _DEST
893.     spajz_dvere32& = _NEWIMAGE(640, 480, 32)
894.     _DEST spajz_dvere32&
895.     CLS , _RGB32(241, 244, 251)
896.     _PUTIMAGE (140, 54), dv&
897.     _DEST de
898.     spajz_dvere& = _COPYIMAGE(spajz_dvere32&, 33)
899.     _FREEIMAGE spajz_dvere32&
900.
901. FUNCTION Zesvetli& (file AS STRING)
903.     IF Zesvetli& < -1 THEN _FREEIMAGE Zesvetli&
904.     w = _WIDTH(t&)
905.     h = _HEIGHT(t&)
906.     zesvetli32& = _NEWIMAGE(w, h, 32)
907.     de = _DEST
908.     _DEST zesvetli32&
909.     _PUTIMAGE , t&, zesvetli32&
910.     LINE (0, 0)-(w - 1, h - 1), _RGBA32(255, 255, 255, 30), BF
911.     _DEST de
912.
913.     Zesvetli& = _COPYIMAGE(zesvetli32&, 33)
914.     _FREEIMAGE zesvetli32&
915.
916. FUNCTION Ztmav& (file AS STRING)
918.     IF Ztmav& < -1 THEN _FREEIMAGE Ztmav&
919.     w = _WIDTH(t&)
920.     h = _HEIGHT(t&)
921.     ztmav32& = _NEWIMAGE(w, h, 32)
922.     de = _DEST
923.     _DEST ztmav32&
924.     _PUTIMAGE , t&, ztmav32&
925.     LINE (0, 0)-(w - 1, h - 1), _RGBA32(0, 0, 0, 30), BF
926.     _DEST de
927.
928.     Ztmav& = _COPYIMAGE(ztmav32&, 33)
929.     _FREEIMAGE ztmav32&
930.
931. FUNCTION Noha&
932.     IF Noha& = 0 THEN
933.         de = _DEST
934.         noh& = _NEWIMAGE(100, 100, 32)
935.         _DEST noh&
936.         LINE (0, 40)-(100, 60), _RGB32(0, 22, 32), BF
937.         _CLEARCOLOR _RGB32(0, 0, 0), noh&
938.         _DEST de
939.         Noha& = _COPYIMAGE(noh&, 33)
940.         _FREEIMAGE noh&
941.
942. FUNCTION Noha2&
943.     IF Noha2& = 0 THEN
944.         de = _DEST
945.         noh& = _NEWIMAGE(100, 100, 32)
946.         _DEST noh&
947.         LINE (30, 30)-(70, 70), _RGB32(0, 2, 12), BF
948.         _CLEARCOLOR _RGB32(0, 0, 0), noh&
949.         _DEST de
950.         Noha2& = _COPYIMAGE(noh&, 33)
951.         _FREEIMAGE noh&
952.
953.
954. FUNCTION JK! (cx, cy, px, py, R)' based on binary circle definition
955.     LenX = cx - px
956.     LenY = cy - py
957.     jR = 1 / R
958.
959.     jX = LenX * jR
960.     jY = LenY * jR
961.
962.     sinusAlfa = jX
963.     Alfa = ABS(_ASIN(sinusAlfa))
964.
965.     Q = 1
966.     IF px >= cx AND py =< cy THEN Q = 1 ' select angle to quadrant
967.     IF px >= cx AND py =< cy THEN Q = 2
968.     IF px =< cx AND py <= cy THEN Q = 3
969.     IF px =< cx AND py >= cy THEN Q = 4
970.         CASE 1: alfaB = Alfa
971.         CASE 2: alfaB = _PI / 2 + (_PI / 2 - Alfa)
972.         CASE 3: alfaB = _PI + Alfa
973.         CASE 4: alfaB = _PI(1.5) + (_PI / 2 - Alfa)
974.     JK! = alfaB
975.
976. SUB valec (xs, ys, zs, ye, R, t&)
977.     tt = UBOUND(v) + 1
978.     polomer = R
979.     REDIM _PRESERVE v(1 TO tt - 1 + 64) AS V
980.     polo = _PI(2) / 16
981.     N = N + 64
982.
983.     FOR s = 0 TO _PI(2) STEP polo
984.         ott = tt
985.         v(tt).X = xs + SIN(s) / polomer
986.         v(tt).Y = ys
987.         v(tt).Z = zs + COS(s) / polomer
988.         tt = tt + 1
989.         v(tt).X = xs + SIN(s) / polomer
990.         v(tt).Y = ye
991.         v(tt).Z = zs + COS(s) / polomer
992.         tt = tt + 1
993.         v(tt).X = xs + SIN(s + polo) / polomer
994.         v(tt).Y = ys
995.         v(tt).Z = zs + COS(s + polo) / polomer
996.         tt = tt + 1
997.         v(tt).X = xs + SIN(s + polo) / polomer
998.         v(tt).Y = ye
999.         v(tt).Z = zs + COS(s + polo) / polomer
1000.         Set_texture t&, ott, tt, 1
1001.         tt = tt + 1
1002.
1003. SUB Zvalec (xs, ys, zs, ze, R, t&)
1004.     tt = UBOUND(v) + 1
1005.     polomer = R
1006.
1007.     REDIM _PRESERVE v(1 TO tt - 1 + 64) AS V
1008.
1009.     polo = _PI(2) / 16
1010.     N = N + 64
1011.
1012.     FOR s = 0 TO _PI(2) STEP polo
1013.         ott = tt
1014.         v(tt).X = xs + SIN(s) / polomer
1015.         v(tt).Y = ys + COS(s) / polomer
1016.         v(tt).Z = zs
1017.         tt = tt + 1
1018.         v(tt).X = xs + SIN(s) / polomer
1019.         v(tt).Y = ys + COS(s) / polomer
1020.         v(tt).Z = ze
1021.         tt = tt + 1
1022.         v(tt).X = xs + SIN(s + polo) / polomer
1023.         v(tt).Y = ys + COS(s + polo) / polomer
1024.         v(tt).Z = zs
1025.         tt = tt + 1
1026.         v(tt).X = xs + SIN(s + polo) / polomer
1027.         v(tt).Y = ys + COS(s + polo) / polomer
1028.         v(tt).Z = ze
1029.         Set_texture t&, ott, tt, 1
1030.         tt = tt + 1
1031.
1032. SUB talir (x, y, z)