1 /* atlantis --- Shows moving 3D sea animals */
4 static const char sccsid[] = "@(#)whale.c 1.3 98/06/18 xlockmore";
7 /* Copyright (c) E. Lassauge, 1998. */
10 * Permission to use, copy, modify, and distribute this software and its
11 * documentation for any purpose and without fee is hereby granted,
12 * provided that the above copyright notice appear in all copies and that
13 * both that copyright notice and this permission notice appear in
14 * supporting documentation.
16 * This file is provided AS IS with no warranties of any kind. The author
17 * shall have no liability with respect to the infringement of copyrights,
18 * trade secrets or any patents by this file or any part thereof. In no
19 * event will the author be liable for any lost revenue or profits or
20 * other special, indirect and consequential damages.
22 * The original code for this mode was written by Mark J. Kilgard
23 * as a demo for openGL programming.
25 * Porting it to xlock was possible by comparing the original Mesa's morph3d
26 * demo with it's ported version to xlock, so thanks for Marcelo F. Vianna
27 * (look at morph3d.c) for his indirect help.
29 * Thanks goes also to Brian Paul for making it possible and inexpensive
30 * to use OpenGL at home.
32 * My e-mail address is lassauge@users.sourceforge.net
34 * Eric Lassauge (May-13-1998)
39 * (c) Copyright 1993, 1994, Silicon Graphics, Inc.
41 * Permission to use, copy, modify, and distribute this software for
42 * any purpose and without fee is hereby granted, provided that the above
43 * copyright notice appear in all copies and that both the copyright notice
44 * and this permission notice appear in supporting documentation, and that
45 * the name of Silicon Graphics, Inc. not be used in advertising
46 * or publicity pertaining to distribution of the software without specific,
47 * written prior permission.
49 * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
50 * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
51 * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
52 * FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON
53 * GRAPHICS, INC. BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
54 * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
55 * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
56 * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
57 * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC. HAS BEEN
58 * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
59 * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
60 * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
62 * US Government Users Restricted Rights
63 * Use, duplication, or disclosure by the Government is subject to
64 * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
65 * (c)(1)(ii) of the Rights in Technical Data and Computer Software
66 * clause at DFARS 252.227-7013 and/or in similar or successor
67 * clauses in the FAR or the DOD or NASA FAR Supplement.
68 * Unpublished-- rights reserved under the copyright laws of the
69 * United States. Contractor/manufacturer is Silicon Graphics,
70 * Inc., 2011 N. Shoreline Blvd., Mountain View, CA 94039-7311.
72 * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
80 static const float N001[3] = {0.019249, 0.01134, -0.99975};
81 static const float N002[3] = {-0.132579, 0.954547, 0.266952};
82 static const float N003[3] = {-0.196061, 0.980392, -0.019778};
83 static const float N004[3] = {0.695461, 0.604704, 0.388158};
84 static const float N005[3] = {0.8706, 0.425754, 0.246557};
85 static const float N006[3] = {-0.881191, 0.392012, 0.264251};
87 static const float N007[3] = {0, 1, 0};
89 static const float N008[3] = {-0.341437, 0.887477, 0.309523};
90 static const float N009[3] = {0.124035, -0.992278, 0};
91 static const float N010[3] = {0.242536, 0, -0.970143};
92 static const float N011[3] = {0.588172, 0, 0.808736};
93 static const float N012[3] = {0.929824, -0.340623, -0.139298};
94 static const float N013[3] = {0.954183, 0.267108, -0.134865};
95 static const float N014[3] = {0.495127, 0.855436, -0.151914};
96 static const float N015[3] = {-0.390199, 0.906569, -0.160867};
97 static const float N016[3] = {-0.923605, 0.354581, -0.145692};
98 static const float N017[3] = {-0.955796, -0.260667, -0.136036};
99 static const float N018[3] = {-0.501283, -0.853462, -0.14254};
100 static const float N019[3] = {0.4053, -0.901974, -0.148913};
101 static const float N020[3] = {0.909913, -0.392746, -0.133451};
102 static const float N021[3] = {0.936494, 0.331147, -0.115414};
103 static const float N022[3] = {0.600131, 0.793724, -0.099222};
104 static const float N023[3] = {-0.231556, 0.968361, -0.093053};
105 static const float N024[3] = {-0.844369, 0.52533, -0.105211};
106 static const float N025[3] = {-0.982725, -0.136329, -0.125164};
107 static const float N026[3] = {-0.560844, -0.822654, -0.093241};
108 static const float N027[3] = {0.263884, -0.959981, -0.093817};
109 static const float N028[3] = {0.842057, -0.525192, -0.122938};
110 static const float N029[3] = {0.92162, 0.367565, -0.124546};
111 static const float N030[3] = {0.613927, 0.784109, -0.090918};
112 static const float N031[3] = {-0.448754, 0.888261, -0.098037};
113 static const float N032[3] = {-0.891865, 0.434376, -0.126077};
114 static const float N033[3] = {-0.881447, -0.448017, -0.149437};
115 static const float N034[3] = {-0.345647, -0.922057, -0.174183};
116 static const float N035[3] = {0.307998, -0.941371, -0.137688};
117 static const float N036[3] = {0.806316, -0.574647, -0.140124};
118 static const float N037[3] = {0.961346, 0.233646, -0.145681};
119 static const float N038[3] = {0.488451, 0.865586, -0.110351};
120 static const float N039[3] = {-0.37429, 0.921953, -0.099553};
121 static const float N040[3] = {-0.928504, 0.344533, -0.138485};
122 static const float N041[3] = {-0.918419, -0.371792, -0.135189};
123 static const float N042[3] = {-0.520666, -0.833704, -0.183968};
124 static const float N043[3] = {0.339204, -0.920273, -0.195036};
125 static const float N044[3] = {0.921475, -0.387382, -0.028636};
126 static const float N045[3] = {0.842465, 0.533335, -0.076204};
127 static const float N046[3] = {0.38011, 0.924939, 0.002073};
128 static const float N047[3] = {-0.276128, 0.961073, -0.009579};
129 static const float N048[3] = {-0.879684, 0.473001, -0.04925};
130 static const float N049[3] = {-0.947184, -0.317614, -0.044321};
131 static const float N050[3] = {-0.642059, -0.764933, -0.051363};
132 static const float N051[3] = {0.466794, -0.880921, -0.07799};
133 static const float N052[3] = {0.898509, -0.432277, 0.076279};
134 static const float N053[3] = {0.938985, 0.328141, 0.103109};
135 static const float N054[3] = {0.44242, 0.895745, 0.043647};
136 static const float N055[3] = {-0.255163, 0.966723, 0.018407};
137 static const float N056[3] = {-0.833769, 0.54065, 0.111924};
138 static const float N057[3] = {-0.953653, -0.289939, 0.080507};
139 static const float N058[3] = {-0.672357, -0.730524, 0.119461};
140 static const float N059[3] = {0.522249, -0.846652, 0.102157};
141 static const float N060[3] = {0.885868, -0.427631, 0.179914};
143 static const float N061[3] = {0, 1, 0};
145 static const float N062[3] = {0.648942, 0.743116, 0.163255};
146 static const float N063[3] = {-0.578967, 0.80773, 0.111219};
148 static const float N064[3] = {0, 1, 0};
150 static const float N065[3] = {-0.909864, -0.352202, 0.219321};
151 static const float N066[3] = {-0.502541, -0.81809, 0.27961};
152 static const float N067[3] = {0.322919, -0.915358, 0.240504};
153 static const float N068[3] = {0.242536, 0, -0.970143};
154 static const float N069[3] = {0, 1, 0};
155 static const float N070[3] = {0, 1, 0};
156 static const float N071[3] = {0, 1, 0};
157 static const float N072[3] = {0, 1, 0};
158 static const float N073[3] = {0, 1, 0};
159 static const float N074[3] = {0, 1, 0};
160 static const float N075[3] = {0.03122, 0.999025, -0.03122};
161 static const float N076[3] = {0, 1, 0};
162 static const float N077[3] = {0.446821, 0.893642, 0.041889};
163 static const float N078[3] = {0.863035, -0.10098, 0.494949};
164 static const float N079[3] = {0.585597, -0.808215, 0.062174};
165 static const float N080[3] = {0, 1, 0};
166 static const float N081[3] = {1, 0, 0};
167 static const float N082[3] = {0, 1, 0};
168 static const float N083[3] = {-1, 0, 0};
169 static const float N084[3] = {-0.478893, 0.837129, -0.264343};
170 static const float N085[3] = {0, 1, 0};
171 static const float N086[3] = {0.763909, 0.539455, -0.354163};
172 static const float N087[3] = {0.446821, 0.893642, 0.041889};
173 static const float N088[3] = {0.385134, -0.908288, 0.163352};
174 static const float N089[3] = {-0.605952, 0.779253, -0.159961};
175 static const float N090[3] = {0, 1, 0};
176 static const float N091[3] = {0, 1, 0};
177 static const float N092[3] = {0, 1, 0};
178 static const float N093[3] = {0, 1, 0};
179 static const float N094[3] = {1, 0, 0};
180 static const float N095[3] = {-1, 0, 0};
181 static const float N096[3] = {0.644444, -0.621516, 0.445433};
182 static const float N097[3] = {-0.760896, -0.474416, 0.442681};
183 static const float N098[3] = {0.636888, -0.464314, 0.615456};
184 static const float N099[3] = {-0.710295, 0.647038, 0.277168};
185 static const float N100[3] = {0.009604, 0.993655, 0.112063};
187 static const float N101[3] = {0, 1, 0};
188 static const float N102[3] = {0, 1, 0};
189 static const float N103[3] = {0, 1, 0};
190 static const float N104[3] = {0.031837, 0.999285, 0.020415};
191 static const float N105[3] = {0.031837, 0.999285, 0.020415};
192 static const float N106[3] = {0.031837, 0.999285, 0.020415};
193 static const float N107[3] = {0.014647, 0.999648, 0.022115};
194 static const float N108[3] = {0.014647, 0.999648, 0.022115};
195 static const float N109[3] = {0.014647, 0.999648, 0.022115};
196 static const float N110[3] = {-0.985141, 0.039475, 0.167149};
197 static const float N111[3] = {-0.985141, 0.039475, 0.167149};
198 static const float N112[3] = {-0.985141, 0.039475, 0.167149};
199 static const float N113[3] = {0, 1, 0};
200 static const float N114[3] = {0, 1, 0};
201 static const float N115[3] = {0, 1, 0};
202 static const float N116[3] = {0, 1, 0};
203 static const float N117[3] = {0, 1, 0};
204 static const float N118[3] = {0, 1, 0};
205 static const float N119[3] = {0, 1, 0};
206 static const float N120[3] = {0, 1, 0};
207 static const float N121[3] = {0, 1, 0};
209 static const float iP001[3] = {18.74, 13.19, 3.76};
210 static float P001[3] = {18.74, 13.19, 3.76};
211 static const float P002[3] = {0, 390.42, 10292.57};
212 static const float P003[3] = {55.8, 622.31, 8254.35};
213 static const float P004[3] = {20.8, 247.66, 10652.13};
214 static const float P005[3] = {487.51, 198.05, 9350.78};
215 static const float P006[3] = {-457.61, 199.04, 9353.01};
217 static const float P007[3] = {0, 259, 10276.27};
219 static const float P008[3] = {-34.67, 247.64, 10663.71};
220 static const float iP009[3] = {97.46, 67.63, 593.82};
221 static const float iP010[3] = {-84.33, 67.63, 588.18};
222 static const float iP011[3] = {118.69, 8.98, -66.91};
223 static float P009[3] = {97.46, 67.63, 593.82};
224 static float P010[3] = {-84.33, 67.63, 588.18};
225 static float P011[3] = {118.69, 8.98, -66.91};
226 static const float iP012[3] = {156.48, -31.95, 924.54};
227 static const float iP013[3] = {162, 110.22, 924.54};
228 static const float iP014[3] = {88.16, 221.65, 924.54};
229 static const float iP015[3] = {-65.21, 231.16, 924.54};
230 static const float iP016[3] = {-156.48, 121.97, 924.54};
231 static const float iP017[3] = {-162, -23.93, 924.54};
232 static const float iP018[3] = {-88.16, -139.1, 924.54};
233 static const float iP019[3] = {65.21, -148.61, 924.54};
234 static const float iP020[3] = {246.87, -98.73, 1783.04};
235 static const float iP021[3] = {253.17, 127.76, 1783.04};
236 static const float iP022[3] = {132.34, 270.77, 1783.04};
237 static const float iP023[3] = {-97.88, 285.04, 1783.04};
238 static const float iP024[3] = {-222.97, 139.8, 1783.04};
239 static const float iP025[3] = {-225.29, -86.68, 1783.04};
240 static const float iP026[3] = {-108.44, -224.15, 1783.04};
241 static const float iP027[3] = {97.88, -221.56, 1783.04};
242 static const float iP028[3] = {410.55, -200.66, 3213.87};
243 static const float iP029[3] = {432.19, 148.42, 3213.87};
244 static const float iP030[3] = {200.66, 410.55, 3213.87};
245 static const float iP031[3] = {-148.42, 432.19, 3213.87};
246 static const float iP032[3] = {-407.48, 171.88, 3213.87};
247 static const float iP033[3] = {-432.19, -148.42, 3213.87};
248 static const float iP034[3] = {-148.88, -309.74, 3213.87};
249 static const float iP035[3] = {156.38, -320.17, 3213.87};
250 static const float iP036[3] = {523.39, -303.81, 4424.57};
251 static const float iP037[3] = {574.66, 276.84, 4424.57};
252 static const float iP038[3] = {243.05, 492.5, 4424.57};
253 static const float iP039[3] = {-191.23, 520.13, 4424.57};
254 static const float iP040[3] = {-523.39, 304.01, 4424.57};
255 static const float iP041[3] = {-574.66, -231.83, 4424.57};
256 static const float iP042[3] = {-266.95, -578.17, 4424.57};
257 static const float iP043[3] = {211.14, -579.67, 4424.57};
258 static const float iP044[3] = {680.57, -370.27, 5943.46};
259 static const float iP045[3] = {834.01, 363.09, 5943.46};
260 static const float iP046[3] = {371.29, 614.13, 5943.46};
261 static const float iP047[3] = {-291.43, 621.86, 5943.46};
262 static const float iP048[3] = {-784.13, 362.6, 5943.46};
263 static const float iP049[3] = {-743.29, -325.82, 5943.46};
264 static const float iP050[3] = {-383.24, -804.77, 5943.46};
265 static const float iP051[3] = {283.47, -846.09, 5943.46};
266 static float P012[3] = {156.48, -31.95, 924.54};
267 static float P013[3] = {162, 110.22, 924.54};
268 static float P014[3] = {88.16, 221.65, 924.54};
269 static float P015[3] = {-65.21, 231.16, 924.54};
270 static float P016[3] = {-156.48, 121.97, 924.54};
271 static float P017[3] = {-162, -23.93, 924.54};
272 static float P018[3] = {-88.16, -139.1, 924.54};
273 static float P019[3] = {65.21, -148.61, 924.54};
274 static float P020[3] = {246.87, -98.73, 1783.04};
275 static float P021[3] = {253.17, 127.76, 1783.04};
276 static float P022[3] = {132.34, 270.77, 1783.04};
277 static float P023[3] = {-97.88, 285.04, 1783.04};
278 static float P024[3] = {-222.97, 139.8, 1783.04};
279 static float P025[3] = {-225.29, -86.68, 1783.04};
280 static float P026[3] = {-108.44, -224.15, 1783.04};
281 static float P027[3] = {97.88, -221.56, 1783.04};
282 static float P028[3] = {410.55, -200.66, 3213.87};
283 static float P029[3] = {432.19, 148.42, 3213.87};
284 static float P030[3] = {200.66, 410.55, 3213.87};
285 static float P031[3] = {-148.42, 432.19, 3213.87};
286 static float P032[3] = {-407.48, 171.88, 3213.87};
287 static float P033[3] = {-432.19, -148.42, 3213.87};
288 static float P034[3] = {-148.88, -309.74, 3213.87};
289 static float P035[3] = {156.38, -320.17, 3213.87};
290 static float P036[3] = {523.39, -303.81, 4424.57};
291 static float P037[3] = {574.66, 276.84, 4424.57};
292 static float P038[3] = {243.05, 492.5, 4424.57};
293 static float P039[3] = {-191.23, 520.13, 4424.57};
294 static float P040[3] = {-523.39, 304.01, 4424.57};
295 static float P041[3] = {-574.66, -231.83, 4424.57};
296 static float P042[3] = {-266.95, -578.17, 4424.57};
297 static float P043[3] = {211.14, -579.67, 4424.57};
298 static float P044[3] = {680.57, -370.27, 5943.46};
299 static float P045[3] = {834.01, 363.09, 5943.46};
300 static float P046[3] = {371.29, 614.13, 5943.46};
301 static float P047[3] = {-291.43, 621.86, 5943.46};
302 static float P048[3] = {-784.13, 362.6, 5943.46};
303 static float P049[3] = {-743.29, -325.82, 5943.46};
304 static float P050[3] = {-383.24, -804.77, 5943.46};
305 static float P051[3] = {283.47, -846.09, 5943.46};
306 static const float P052[3] = {599.09, -332.24, 7902.59};
307 static const float P053[3] = {735.48, 306.26, 7911.92};
308 static const float P054[3] = {321.55, 558.53, 7902.59};
309 static const float P055[3] = {-260.54, 559.84, 7902.59};
310 static const float P056[3] = {-698.66, 320.83, 7902.59};
311 static const float P057[3] = {-643.29, -299.16, 7902.59};
312 static const float P058[3] = {-341.47, -719.3, 7902.59};
313 static const float P059[3] = {252.57, -756.12, 7902.59};
314 static const float P060[3] = {458.39, -265.31, 9355.44};
315 static const float iP061[3] = {353.63, 138.7, 10214.2};
316 static float P061[3] = {353.63, 138.7, 10214.2};
317 static const float P062[3] = {224.04, 438.98, 9364.77};
318 static const float P063[3] = {-165.71, 441.27, 9355.44};
319 static const float iP064[3] = {-326.4, 162.04, 10209.54};
320 static float P064[3] = {-326.4, 162.04, 10209.54};
321 static const float P065[3] = {-473.99, -219.71, 9355.44};
322 static const float P066[3] = {-211.97, -479.87, 9355.44};
323 static const float P067[3] = {192.86, -504.03, 9355.44};
324 static const float iP068[3] = {-112.44, 9.25, -64.42};
325 static const float iP069[3] = {1155.63, 0, -182.46};
326 static const float iP070[3] = {-1143.13, 0, -181.54};
327 static const float iP071[3] = {1424.23, 0, -322.09};
328 static const float iP072[3] = {-1368.01, 0, -310.38};
329 static const float iP073[3] = {1255.57, 2.31, 114.05};
330 static const float iP074[3] = {-1149.38, 0, 117.12};
331 static const float iP075[3] = {718.36, 0, 433.36};
332 static const float iP076[3] = {-655.9, 0, 433.36};
333 static float P068[3] = {-112.44, 9.25, -64.42};
334 static float P069[3] = {1155.63, 0, -182.46};
335 static float P070[3] = {-1143.13, 0, -181.54};
336 static float P071[3] = {1424.23, 0, -322.09};
337 static float P072[3] = {-1368.01, 0, -310.38};
338 static float P073[3] = {1255.57, 2.31, 114.05};
339 static float P074[3] = {-1149.38, 0, 117.12};
340 static float P075[3] = {718.36, 0, 433.36};
341 static float P076[3] = {-655.9, 0, 433.36};
342 static const float P077[3] = {1058, -2.66, 7923.51};
343 static const float P078[3] = {-1016.51, -15.47, 7902.87};
344 static const float P079[3] = {-1363.99, -484.5, 7593.38};
345 static const float P080[3] = {1478.09, -861.47, 7098.12};
346 static const float P081[3] = {1338.06, -284.68, 7024.15};
347 static const float P082[3] = {-1545.51, -860.64, 7106.6};
348 static const float P083[3] = {1063.19, -70.46, 7466.6};
349 static const float P084[3] = {-1369.18, -288.11, 7015.34};
350 static const float P085[3] = {1348.44, -482.5, 7591.41};
351 static const float P086[3] = {-1015.45, -96.8, 7474.86};
352 static const float P087[3] = {731.04, 148.38, 7682.58};
353 static const float P088[3] = {-697.03, 151.82, 7668.81};
354 static const float P089[3] = {-686.82, 157.09, 7922.29};
355 static const float P090[3] = {724.73, 147.75, 7931.39};
356 static const float iP091[3] = {0, 327.1, 2346.55};
357 static const float iP092[3] = {0, 552.28, 2311.31};
358 static const float iP093[3] = {0, 721.16, 2166.41};
359 static const float iP094[3] = {0, 693.42, 2388.8};
360 static const float iP095[3] = {0, 389.44, 2859.97};
361 static float P091[3] = {0, 327.1, 2346.55};
362 static float P092[3] = {0, 552.28, 2311.31};
363 static float P093[3] = {0, 721.16, 2166.41};
364 static float P094[3] = {0, 693.42, 2388.8};
365 static float P095[3] = {0, 389.44, 2859.97};
366 static const float iP096[3] = {222.02, -183.67, 10266.89};
367 static const float iP097[3] = {-128.9, -182.7, 10266.89};
368 static const float iP098[3] = {41.04, 88.31, 10659.36};
369 static const float iP099[3] = {-48.73, 88.3, 10659.36};
370 static float P096[3] = {222.02, -183.67, 10266.89};
371 static float P097[3] = {-128.9, -182.7, 10266.89};
372 static float P098[3] = {41.04, 88.31, 10659.36};
373 static float P099[3] = {-48.73, 88.3, 10659.36};
374 static const float P100[3] = {0, 603.42, 9340.68};
376 static const float P101[3] = {5.7, 567, 7862.98};
377 static const float P102[3] = {521.61, 156.61, 9162.34};
378 static const float P103[3] = {83.68, 566.67, 7861.26};
380 static const float P104[3] = {-9.86, 567.62, 7858.65};
381 static const float P105[3] = {31.96, 565.27, 7908.46};
382 static const float P106[3] = {22.75, 568.13, 7782.83};
383 static const float P107[3] = {58.93, 568.42, 7775.94};
384 static const float P108[3] = {55.91, 565.59, 7905.86};
385 static const float P109[3] = {99.21, 566, 7858.65};
386 static const float P110[3] = {-498.83, 148.14, 9135.1};
387 static const float P111[3] = {-495.46, 133.24, 9158.48};
388 static const float P112[3] = {-490.82, 146.23, 9182.76};
389 static const float P113[3] = {-489.55, 174.11, 9183.66};
390 static const float P114[3] = {-492.92, 189, 9160.28};
391 static const float P115[3] = {-497.56, 176.02, 9136};
392 static const float P116[3] = {526.54, 169.68, 9137.7};
393 static const float P117[3] = {523.49, 184.85, 9161.42};
394 static const float P118[3] = {518.56, 171.78, 9186.06};
395 static const float P119[3] = {516.68, 143.53, 9186.98};
396 static const float P120[3] = {519.73, 128.36, 9163.26};
397 static const float P121[3] = {524.66, 141.43, 9138.62};
1010 Whale008(GLenum cap)
1131 Whale009(GLenum cap)
1252 Whale010(GLenum cap)
1337 Whale011(GLenum cap)
1422 Whale012(GLenum cap)
1533 Whale013(GLenum cap)
1612 Whale014(GLenum cap)
1663 Whale015(GLenum cap)
1724 Whale016(GLenum cap)
1755 DrawWhale(fishRec * fish, int wire)
1757 float seg0, seg1, seg2, seg3, seg4, seg5, seg6, seg7;
1758 float pitch, thrash, chomp;
1761 fish->htail = (int) (fish->htail - (int) (5 * fish->v)) % 360;
1763 thrash = 70 * fish->v;
1765 seg0 = 1.5 * thrash * sin((fish->htail) * RRAD);
1766 seg1 = 2.5 * thrash * sin((fish->htail + 10) * RRAD);
1767 seg2 = 3.7 * thrash * sin((fish->htail + 15) * RRAD);
1768 seg3 = 4.8 * thrash * sin((fish->htail + 23) * RRAD);
1769 seg4 = 6 * thrash * sin((fish->htail + 28) * RRAD);
1770 seg5 = 6.5 * thrash * sin((fish->htail + 35) * RRAD);
1771 seg6 = 6.5 * thrash * sin((fish->htail + 40) * RRAD);
1772 seg7 = 6.5 * thrash * sin((fish->htail + 55) * RRAD);
1774 pitch = fish->v * sin((fish->htail - 160) * RRAD);
1778 chomp = -(fish->v - 2) * 200;
1780 P012[1] = iP012[1] + seg5;
1781 P013[1] = iP013[1] + seg5;
1782 P014[1] = iP014[1] + seg5;
1783 P015[1] = iP015[1] + seg5;
1784 P016[1] = iP016[1] + seg5;
1785 P017[1] = iP017[1] + seg5;
1786 P018[1] = iP018[1] + seg5;
1787 P019[1] = iP019[1] + seg5;
1789 P020[1] = iP020[1] + seg4;
1790 P021[1] = iP021[1] + seg4;
1791 P022[1] = iP022[1] + seg4;
1792 P023[1] = iP023[1] + seg4;
1793 P024[1] = iP024[1] + seg4;
1794 P025[1] = iP025[1] + seg4;
1795 P026[1] = iP026[1] + seg4;
1796 P027[1] = iP027[1] + seg4;
1798 P028[1] = iP028[1] + seg2;
1799 P029[1] = iP029[1] + seg2;
1800 P030[1] = iP030[1] + seg2;
1801 P031[1] = iP031[1] + seg2;
1802 P032[1] = iP032[1] + seg2;
1803 P033[1] = iP033[1] + seg2;
1804 P034[1] = iP034[1] + seg2;
1805 P035[1] = iP035[1] + seg2;
1807 P036[1] = iP036[1] + seg1;
1808 P037[1] = iP037[1] + seg1;
1809 P038[1] = iP038[1] + seg1;
1810 P039[1] = iP039[1] + seg1;
1811 P040[1] = iP040[1] + seg1;
1812 P041[1] = iP041[1] + seg1;
1813 P042[1] = iP042[1] + seg1;
1814 P043[1] = iP043[1] + seg1;
1816 P044[1] = iP044[1] + seg0;
1817 P045[1] = iP045[1] + seg0;
1818 P046[1] = iP046[1] + seg0;
1819 P047[1] = iP047[1] + seg0;
1820 P048[1] = iP048[1] + seg0;
1821 P049[1] = iP049[1] + seg0;
1822 P050[1] = iP050[1] + seg0;
1823 P051[1] = iP051[1] + seg0;
1825 P009[1] = iP009[1] + seg6;
1826 P010[1] = iP010[1] + seg6;
1827 P075[1] = iP075[1] + seg6;
1828 P076[1] = iP076[1] + seg6;
1830 P001[1] = iP001[1] + seg7;
1831 P011[1] = iP011[1] + seg7;
1832 P068[1] = iP068[1] + seg7;
1833 P069[1] = iP069[1] + seg7;
1834 P070[1] = iP070[1] + seg7;
1835 P071[1] = iP071[1] + seg7;
1836 P072[1] = iP072[1] + seg7;
1837 P073[1] = iP073[1] + seg7;
1838 P074[1] = iP074[1] + seg7;
1840 P091[1] = iP091[1] + seg3 * 1.1;
1841 P092[1] = iP092[1] + seg3;
1842 P093[1] = iP093[1] + seg3;
1843 P094[1] = iP094[1] + seg3;
1844 P095[1] = iP095[1] + seg3 * 0.9;
1846 P099[1] = iP099[1] + chomp;
1847 P098[1] = iP098[1] + chomp;
1848 P064[1] = iP064[1] + chomp;
1849 P061[1] = iP061[1] + chomp;
1850 P097[1] = iP097[1] + chomp;
1851 P096[1] = iP096[1] + chomp;
1855 glRotatef(pitch, 1, 0, 0);
1857 glTranslatef(0, 0, 8000);
1859 glRotatef(180, 0, 1, 0);
1863 glEnable(GL_CULL_FACE);
1865 cap = wire ? GL_LINE_LOOP : GL_POLYGON;
1883 glDisable(GL_CULL_FACE);