Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1571 lines
39 KiB

  1. /*
  2. ** Copyright 1992, Silicon Graphics, Inc.
  3. ** All Rights Reserved.
  4. **
  5. ** This is UNPUBLISHED PROPRIETARY SOURCE CODE of Silicon Graphics, Inc.;
  6. ** the contents of this file may not be disclosed to third parties, copied or
  7. ** duplicated in any form, in whole or in part, without the prior written
  8. ** permission of Silicon Graphics, Inc.
  9. **
  10. ** RESTRICTED RIGHTS LEGEND:
  11. ** Use, duplication or disclosure by the Government is subject to restrictions
  12. ** as set forth in subdivision (c)(1)(ii) of the Rights in Technical Data
  13. ** and Computer Software clause at DFARS 252.227-7013, and/or in similar or
  14. ** successor clauses in the FAR, DOD or NASA FAR Supplement. Unpublished -
  15. ** rights reserved under the Copyright Laws of the United States.
  16. **
  17. */
  18. #include <setjmp.h>
  19. #include <windef.h>
  20. struct JumpBuffer {
  21. jmp_buf buf;
  22. };
  23. #define mysetjmp(x) setjmp((x)->buf)
  24. #define mylongjmp(x,y) longjmp((x)->buf, y)
  25. /* <<AT&T USL C++ Language System <3.0.1> 02/03/92>> */
  26. /* < ../core/nurbstess.c++ > */
  27. void *__vec_new (void *, int , int , void *);
  28. void __vec_ct (void *, int , int , void *);
  29. void __vec_dt (void *, int , int , void *);
  30. void __vec_delete (void *, int , int , void *, int , int );
  31. typedef int (*__vptp)(void);
  32. struct __mptr {short d; short i; __vptp f; };
  33. typedef unsigned int size_t ;
  34. // extern void *malloc (size_t );
  35. // extern void free (void *);
  36. struct JumpBuffer;
  37. struct Buffer;
  38. struct Buffer {
  39. struct Buffer *next__6Buffer ;
  40. };
  41. struct Pool;
  42. enum __Q2_4Pool5Magic { is_allocated__Q2_4Pool5Magic = 62369, is_free__Q2_4Pool5Magic = 61858} ;
  43. struct Pool {
  44. struct Buffer *freelist__4Pool ;
  45. char *blocklist__4Pool [32];
  46. int nextblock__4Pool ;
  47. char *curblock__4Pool ;
  48. int buffersize__4Pool ;
  49. int nextsize__4Pool ;
  50. int nextfree__4Pool ;
  51. int initsize__4Pool ;
  52. char *name__4Pool ;
  53. int magic__4Pool ;
  54. };
  55. void __glgrow__4PoolFv (struct Pool *);
  56. struct PooledObj;
  57. struct PooledObj {
  58. char __W3__9PooledObj ;
  59. };
  60. typedef float REAL ;
  61. typedef void (*Pfvv )(void );
  62. typedef void (*Pfvf )(float *);
  63. typedef int (*cmpfunc )(void *, void *);
  64. typedef REAL Knot ;
  65. typedef REAL *Knot_ptr ;
  66. struct TrimVertex;
  67. struct PwlArc;
  68. struct PwlArc {
  69. char __W3__9PooledObj ;
  70. struct TrimVertex *pts__6PwlArc ;
  71. int npts__6PwlArc ;
  72. long type__6PwlArc ;
  73. };
  74. struct TrimVertex;
  75. struct TrimVertex {
  76. REAL param__10TrimVertex [2];
  77. long nuid__10TrimVertex ;
  78. };
  79. typedef struct TrimVertex *TrimVertex_p ;
  80. struct Bin;
  81. struct Arc;
  82. struct BezierArc;
  83. typedef struct Arc *Arc_ptr ;
  84. enum arc_side { arc_none = 0, arc_right = 1, arc_top = 2, arc_left = 3, arc_bottom = 4} ;
  85. struct Arc;
  86. struct Arc {
  87. char __W3__9PooledObj ;
  88. Arc_ptr prev__3Arc ;
  89. Arc_ptr next__3Arc ;
  90. Arc_ptr link__3Arc ;
  91. struct BezierArc *bezierArc__3Arc ;
  92. struct PwlArc *pwlArc__3Arc ;
  93. long type__3Arc ;
  94. long nuid__3Arc ;
  95. };
  96. extern int __glbezier_tag__3Arc ;
  97. extern int __glarc_tag__3Arc ;
  98. extern int __gltail_tag__3Arc ;
  99. struct Bin;
  100. struct Bin {
  101. struct Arc *head__3Bin ;
  102. struct Arc *current__3Bin ;
  103. };
  104. struct Sorter;
  105. struct Sorter {
  106. int es__6Sorter ;
  107. struct __mptr *__vptr__6Sorter ;
  108. };
  109. struct FlistSorter;
  110. struct FlistSorter {
  111. int es__6Sorter ;
  112. struct __mptr *__vptr__6Sorter ;
  113. };
  114. struct Flist;
  115. struct Flist {
  116. REAL *pts__5Flist ;
  117. int npts__5Flist ;
  118. int start__5Flist ;
  119. int end__5Flist ;
  120. struct FlistSorter sorter__5Flist ;
  121. };
  122. struct Backend;
  123. struct Jarcloc;
  124. struct Jarcloc {
  125. struct Arc *arc__7Jarcloc ;
  126. struct TrimVertex *p__7Jarcloc ;
  127. struct TrimVertex *plast__7Jarcloc ;
  128. };
  129. struct Trimline;
  130. struct Trimline {
  131. struct TrimVertex **pts__8Trimline ;
  132. long numverts__8Trimline ;
  133. long i__8Trimline ;
  134. long size__8Trimline ;
  135. struct Jarcloc jarcl__8Trimline ;
  136. struct TrimVertex t__8Trimline ;
  137. struct TrimVertex b__8Trimline ;
  138. struct TrimVertex *tinterp__8Trimline ;
  139. struct TrimVertex *binterp__8Trimline ;
  140. };
  141. struct Gridline;
  142. struct Gridline {
  143. long v__8Gridline ;
  144. REAL vval__8Gridline ;
  145. long vindex__8Gridline ;
  146. long ustart__8Gridline ;
  147. long uend__8Gridline ;
  148. };
  149. struct Uarray;
  150. struct Uarray {
  151. long size__6Uarray ;
  152. long ulines__6Uarray ;
  153. REAL *uarray__6Uarray ;
  154. };
  155. struct Backend;
  156. struct TrimRegion;
  157. void __gl__dt__8TrimlineFv (struct Trimline *, int );
  158. void __gl__dt__6UarrayFv (struct Uarray *, int );
  159. struct TrimRegion {
  160. struct Trimline left__10TrimRegion ;
  161. struct Trimline right__10TrimRegion ;
  162. struct Gridline top__10TrimRegion ;
  163. struct Gridline bot__10TrimRegion ;
  164. struct Uarray uarray__10TrimRegion ;
  165. REAL oneOverDu__10TrimRegion ;
  166. };
  167. struct GridTrimVertex;
  168. struct __Q2_4Hull4Side;
  169. struct __Q2_4Hull4Side {
  170. struct Trimline *left__Q2_4Hull4Side ;
  171. struct Gridline *line__Q2_4Hull4Side ;
  172. struct Trimline *right__Q2_4Hull4Side ;
  173. long index__Q2_4Hull4Side ;
  174. };
  175. struct Hull;
  176. struct Hull {
  177. struct __Q2_4Hull4Side lower__4Hull ;
  178. struct __Q2_4Hull4Side upper__4Hull ;
  179. struct Trimline fakeleft__4Hull ;
  180. struct Trimline fakeright__4Hull ;
  181. struct TrimRegion *PTrimRegion;
  182. struct TrimRegion OTrimRegion;
  183. };
  184. struct Backend;
  185. struct GridTrimVertex;
  186. struct Mesher;
  187. struct Mesher {
  188. struct __Q2_4Hull4Side lower__4Hull ;
  189. struct __Q2_4Hull4Side upper__4Hull ;
  190. struct Trimline fakeleft__4Hull ;
  191. struct Trimline fakeright__4Hull ;
  192. struct TrimRegion *PTrimRegion;
  193. struct Backend *backend__6Mesher ;
  194. struct Pool p__6Mesher ;
  195. unsigned int stacksize__6Mesher ;
  196. struct GridTrimVertex **vdata__6Mesher ;
  197. struct GridTrimVertex *last__6Mesher [2];
  198. int itop__6Mesher ;
  199. int lastedge__6Mesher ;
  200. struct TrimRegion OTrimRegion;
  201. };
  202. extern float __glZERO__6Mesher ;
  203. struct Backend;
  204. struct GridVertex;
  205. struct GridTrimVertex;
  206. struct CoveAndTiler;
  207. struct CoveAndTiler {
  208. struct Backend *backend__12CoveAndTiler ;
  209. struct TrimRegion *PTrimRegion;
  210. struct TrimRegion OTrimRegion;
  211. };
  212. extern int __glMAXSTRIPSIZE__12CoveAndTil0 ;
  213. struct Backend;
  214. struct Slicer;
  215. struct Slicer {
  216. struct Backend *backend__12CoveAndTiler ;
  217. struct TrimRegion *PTrimRegion;
  218. struct Mesher OMesher;
  219. struct Backend *backend__6Slicer ;
  220. REAL oneOverDu__6Slicer ;
  221. REAL du__6Slicer ;
  222. REAL dv__6Slicer ;
  223. int isolines__6Slicer ;
  224. };
  225. struct BezierArc;
  226. struct TrimVertexPool;
  227. struct ArcTessellator;
  228. struct ArcTessellator {
  229. struct Pool *pwlarcpool__14ArcTessellator ;
  230. struct TrimVertexPool *trimvertexpool__14ArcTessellator ;
  231. };
  232. extern REAL __glgl_Bernstein__14ArcTessell0 [][24][24];
  233. struct TrimVertexPool;
  234. struct TrimVertexPool {
  235. struct Pool pool__14TrimVertexPool ;
  236. struct TrimVertex **vlist__14TrimVertexPool ;
  237. int nextvlistslot__14TrimVertexPool ;
  238. int vlistsize__14TrimVertexPool ;
  239. };
  240. struct Renderhints;
  241. struct Backend;
  242. struct Quilt;
  243. struct Patchlist;
  244. struct Curvelist;
  245. struct JumpBuffer;
  246. struct Subdivider;
  247. enum __Q2_10Subdivider3dir { down__Q2_10Subdivider3dir = 0, same__Q2_10Subdivider3dir = 1, up__Q2_10Subdivider3dir = 2, none__Q2_10Subdivider3dir = 3} ;
  248. struct Subdivider {
  249. struct Slicer slicer__10Subdivider ;
  250. struct ArcTessellator arctessellator__10Subdivider ;
  251. struct Pool arcpool__10Subdivider ;
  252. struct Pool bezierarcpool__10Subdivider ;
  253. struct Pool pwlarcpool__10Subdivider ;
  254. struct TrimVertexPool trimvertexpool__10Subdivider ;
  255. struct JumpBuffer *jumpbuffer__10Subdivider ;
  256. struct Renderhints *renderhints__10Subdivider ;
  257. struct Backend *backend__10Subdivider ;
  258. struct Bin initialbin__10Subdivider ;
  259. struct Arc *pjarc__10Subdivider ;
  260. int s_index__10Subdivider ;
  261. int t_index__10Subdivider ;
  262. struct Quilt *qlist__10Subdivider ;
  263. struct Flist spbrkpts__10Subdivider ;
  264. struct Flist tpbrkpts__10Subdivider ;
  265. struct Flist smbrkpts__10Subdivider ;
  266. struct Flist tmbrkpts__10Subdivider ;
  267. REAL stepsizes__10Subdivider [4];
  268. int showDegenerate__10Subdivider ;
  269. int isArcTypeBezier__10Subdivider ;
  270. };
  271. struct Renderhints;
  272. struct Renderhints {
  273. REAL display_method__11Renderhints ;
  274. REAL errorchecking__11Renderhints ;
  275. REAL subdivisions__11Renderhints ;
  276. REAL tmp1__11Renderhints ;
  277. int displaydomain__11Renderhints ;
  278. int maxsubdivisions__11Renderhints ;
  279. int wiretris__11Renderhints ;
  280. int wirequads__11Renderhints ;
  281. };
  282. struct GridVertex;
  283. struct GridVertex {
  284. long gparam__10GridVertex [2];
  285. };
  286. struct GridTrimVertex;
  287. struct GridTrimVertex {
  288. char __W3__9PooledObj ;
  289. struct TrimVertex dummyt__14GridTrimVertex ;
  290. struct GridVertex dummyg__14GridTrimVertex ;
  291. struct TrimVertex *t__14GridTrimVertex ;
  292. struct GridVertex *g__14GridTrimVertex ;
  293. };
  294. typedef struct GridTrimVertex *GridTrimVertex_p ;
  295. struct BasicCurveEvaluator;
  296. struct BasicSurfaceEvaluator;
  297. struct Backend;
  298. struct Backend {
  299. struct BasicCurveEvaluator *curveEvaluator__7Backend ;
  300. struct BasicSurfaceEvaluator *surfaceEvaluator__7Backend ;
  301. int wireframetris__7Backend ;
  302. int wireframequads__7Backend ;
  303. int npts__7Backend ;
  304. REAL mesh__7Backend [3][4];
  305. int meshindex__7Backend ;
  306. };
  307. struct Mapdesc;
  308. struct Maplist;
  309. void __gl__dt__4PoolFv (struct Pool *, int );
  310. struct Maplist {
  311. struct Pool mapdescPool__7Maplist ;
  312. struct Mapdesc *maps__7Maplist ;
  313. struct Mapdesc **lastmap__7Maplist ;
  314. struct Backend *backend__7Maplist ;
  315. };
  316. struct Mapdesc *__gllocate__7MaplistFl (struct Maplist *, long );
  317. void __glremove__7MaplistFP7Mapdesc (struct Maplist *, struct Mapdesc *);
  318. enum Curvetype { ct_nurbscurve = 0, ct_pwlcurve = 1, ct_none = 2} ;
  319. struct Property;
  320. struct O_surface;
  321. struct O_nurbssurface;
  322. struct O_trim;
  323. struct O_pwlcurve;
  324. struct O_nurbscurve;
  325. struct O_curve;
  326. struct Quilt;
  327. union __Q2_7O_curve4__C1;
  328. union __Q2_7O_curve4__C1 {
  329. struct O_nurbscurve *o_nurbscurve ;
  330. struct O_pwlcurve *o_pwlcurve ;
  331. };
  332. struct O_curve;
  333. struct O_curve {
  334. char __W3__9PooledObj ;
  335. union __Q2_7O_curve4__C1 curve__7O_curve ;
  336. int curvetype__7O_curve ;
  337. struct O_curve *next__7O_curve ;
  338. struct O_surface *owner__7O_curve ;
  339. int used__7O_curve ;
  340. int save__7O_curve ;
  341. long nuid__7O_curve ;
  342. };
  343. struct O_nurbscurve;
  344. struct O_nurbscurve {
  345. char __W3__9PooledObj ;
  346. struct Quilt *bezier_curves__12O_nurbscurve ;
  347. long type__12O_nurbscurve ;
  348. REAL tesselation__12O_nurbscurve ;
  349. int method__12O_nurbscurve ;
  350. struct O_nurbscurve *next__12O_nurbscurve ;
  351. int used__12O_nurbscurve ;
  352. int save__12O_nurbscurve ;
  353. struct O_curve *owner__12O_nurbscurve ;
  354. };
  355. struct O_pwlcurve;
  356. struct O_pwlcurve {
  357. char __W3__9PooledObj ;
  358. struct TrimVertex *pts__10O_pwlcurve ;
  359. int npts__10O_pwlcurve ;
  360. struct O_pwlcurve *next__10O_pwlcurve ;
  361. int used__10O_pwlcurve ;
  362. int save__10O_pwlcurve ;
  363. struct O_curve *owner__10O_pwlcurve ;
  364. };
  365. struct O_trim;
  366. struct O_trim {
  367. char __W3__9PooledObj ;
  368. struct O_curve *o_curve__6O_trim ;
  369. struct O_trim *next__6O_trim ;
  370. int save__6O_trim ;
  371. };
  372. struct O_nurbssurface;
  373. struct O_nurbssurface {
  374. char __W3__9PooledObj ;
  375. struct Quilt *bezier_patches__14O_nurbssurface ;
  376. long type__14O_nurbssurface ;
  377. struct O_surface *owner__14O_nurbssurface ;
  378. struct O_nurbssurface *next__14O_nurbssurface ;
  379. int save__14O_nurbssurface ;
  380. int used__14O_nurbssurface ;
  381. };
  382. struct O_surface;
  383. struct O_surface {
  384. char __W3__9PooledObj ;
  385. struct O_nurbssurface *o_nurbssurface__9O_surface ;
  386. struct O_trim *o_trim__9O_surface ;
  387. int save__9O_surface ;
  388. long nuid__9O_surface ;
  389. };
  390. struct Property;
  391. struct Property {
  392. char __W3__9PooledObj ;
  393. long type__8Property ;
  394. long tag__8Property ;
  395. REAL value__8Property ;
  396. int save__8Property ;
  397. };
  398. struct NurbsTessellator;
  399. struct Knotvector;
  400. struct Quilt;
  401. struct DisplayList;
  402. struct BasicCurveEvaluator;
  403. struct BasicSurfaceEvaluator;
  404. struct NurbsTessellator;
  405. struct NurbsTessellator {
  406. struct Renderhints renderhints__16NurbsTessellator ;
  407. struct Maplist maplist__16NurbsTessellator ;
  408. struct Backend backend__16NurbsTessellator ;
  409. struct Subdivider subdivider__16NurbsTessellator ;
  410. struct JumpBuffer *jumpbuffer__16NurbsTessellator ;
  411. struct Pool o_pwlcurvePool__16NurbsTessellator ;
  412. struct Pool o_nurbscurvePool__16NurbsTessellator ;
  413. struct Pool o_curvePool__16NurbsTessellator ;
  414. struct Pool o_trimPool__16NurbsTessellator ;
  415. struct Pool o_surfacePool__16NurbsTessellator ;
  416. struct Pool o_nurbssurfacePool__16NurbsTessellator ;
  417. struct Pool propertyPool__16NurbsTessellator ;
  418. struct Pool quiltPool__16NurbsTessellator ;
  419. struct TrimVertexPool extTrimVertexPool__16NurbsTessellator ;
  420. int inSurface__16NurbsTessellator ;
  421. int inCurve__16NurbsTessellator ;
  422. int inTrim__16NurbsTessellator ;
  423. int isCurveModified__16NurbsTessellator ;
  424. int isTrimModified__16NurbsTessellator ;
  425. int isSurfaceModified__16NurbsTessellator ;
  426. int isDataValid__16NurbsTessellator ;
  427. int numTrims__16NurbsTessellator ;
  428. int playBack__16NurbsTessellator ;
  429. struct O_trim **nextTrim__16NurbsTessellator ;
  430. struct O_curve **nextCurve__16NurbsTessellator ;
  431. struct O_nurbscurve **nextNurbscurve__16NurbsTessellator ;
  432. struct O_pwlcurve **nextPwlcurve__16NurbsTessellator ;
  433. struct O_nurbssurface **nextNurbssurface__16NurbsTessellator ;
  434. struct O_surface *currentSurface__16NurbsTessellator ;
  435. struct O_trim *currentTrim__16NurbsTessellator ;
  436. struct O_curve *currentCurve__16NurbsTessellator ;
  437. struct DisplayList *dl__16NurbsTessellator ;
  438. struct __mptr *__vptr__16NurbsTessellator ;
  439. };
  440. struct Mapdesc;
  441. struct Knotvector;
  442. struct Quiltspec;
  443. struct Quiltspec {
  444. int stride__9Quiltspec ;
  445. int width__9Quiltspec ;
  446. int offset__9Quiltspec ;
  447. int order__9Quiltspec ;
  448. int index__9Quiltspec ;
  449. int bdry__9Quiltspec [2];
  450. REAL step_size__9Quiltspec ;
  451. Knot *breakpoints__9Quiltspec ;
  452. };
  453. typedef struct Quiltspec *Quiltspec_ptr ;
  454. struct Quilt;
  455. struct Quilt {
  456. char __W3__9PooledObj ;
  457. struct Mapdesc *mapdesc__5Quilt ;
  458. REAL *cpts__5Quilt ;
  459. struct Quiltspec qspec__5Quilt [2];
  460. Quiltspec_ptr eqspec__5Quilt ;
  461. struct Quilt *next__5Quilt ;
  462. };
  463. typedef struct Quilt *Quilt_ptr ;
  464. struct Knotvector;
  465. struct Knotvector {
  466. long order__10Knotvector ;
  467. long knotcount__10Knotvector ;
  468. long stride__10Knotvector ;
  469. Knot *knotlist__10Knotvector ;
  470. };
  471. typedef REAL Maxmatrix [5][5];
  472. struct Mapdesc;
  473. struct Mapdesc {
  474. char __W3__9PooledObj ;
  475. REAL pixel_tolerance__7Mapdesc ;
  476. REAL clampfactor__7Mapdesc ;
  477. REAL minsavings__7Mapdesc ;
  478. REAL maxrate__7Mapdesc ;
  479. REAL maxsrate__7Mapdesc ;
  480. REAL maxtrate__7Mapdesc ;
  481. REAL bboxsize__7Mapdesc [5];
  482. long type__7Mapdesc ;
  483. int isrational__7Mapdesc ;
  484. int ncoords__7Mapdesc ;
  485. int hcoords__7Mapdesc ;
  486. int inhcoords__7Mapdesc ;
  487. int mask__7Mapdesc ;
  488. Maxmatrix bmat__7Mapdesc ;
  489. Maxmatrix cmat__7Mapdesc ;
  490. Maxmatrix smat__7Mapdesc ;
  491. REAL s_steps__7Mapdesc ;
  492. REAL t_steps__7Mapdesc ;
  493. REAL sampling_method__7Mapdesc ;
  494. REAL culling_method__7Mapdesc ;
  495. REAL bbox_subdividing__7Mapdesc ;
  496. struct Mapdesc *next__7Mapdesc ;
  497. struct Backend *backend__7Mapdesc ;
  498. };
  499. void __glcopy__7MapdescSFPA5_flPfN20 (REAL (*)[5], long , float *, long , long );
  500. void __glxformRational__7MapdescFPA0 (struct Mapdesc *, REAL (*)[5], REAL *, REAL *);
  501. void __glxformNonrational__7Mapdesc0 (struct Mapdesc *, REAL (*)[5], REAL *, REAL *);
  502. void __glclear__10SubdividerFv (struct Subdivider *);
  503. extern struct __mptr* __ptbl_vec_____core_nurbstess_c___resetObjects_[];
  504. void __glresetObjects__16NurbsTesse0 (struct NurbsTessellator *__0this )
  505. {
  506. __glclear__10SubdividerFv ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator )) ;
  507. }
  508. void __glmakeobj__16NurbsTessellato0 (struct NurbsTessellator *__0this , int __1__A14 )
  509. {
  510. }
  511. void __glcloseobj__16NurbsTessellat0 (struct NurbsTessellator *__0this )
  512. {
  513. }
  514. void __glbgnrender__16NurbsTessella0 (struct NurbsTessellator *__0this )
  515. {
  516. }
  517. void __glendrender__16NurbsTessella0 (struct NurbsTessellator *__0this )
  518. {
  519. }
  520. void __gldo_freebgnsurface__16Nurbs0 (struct NurbsTessellator *__0this , struct O_surface *__1o_surface )
  521. {
  522. ( ( (((void )0 )), ( ((((struct Buffer *)(((struct Buffer *)(((void *)((struct
  523. PooledObj *)__1o_surface )))))))-> next__6Buffer = ((struct Pool *)((struct Pool *)(& __0this -> o_surfacePool__16NurbsTessellator )))-> freelist__4Pool ), (((struct Pool *)((struct Pool *)(& __0this -> o_surfacePool__16NurbsTessellator )))-> freelist__4Pool =
  524. (((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_surface ))))))))) ) ) ;
  525. }
  526. void __gldo_nurbserror__16NurbsTess0 (struct NurbsTessellator *, int );
  527. void __glendsurface__16NurbsTessell0 (struct NurbsTessellator *);
  528. void __gldo_bgnsurface__16NurbsTess0 (struct NurbsTessellator *__0this , struct O_surface *__1o_surface )
  529. {
  530. if (__0this -> inSurface__16NurbsTessellator ){
  531. __gldo_nurbserror__16NurbsTess0 ( __0this , 27 ) ;
  532. __glendsurface__16NurbsTessell0 ( __0this ) ;
  533. }
  534. __0this -> inSurface__16NurbsTessellator = 1 ;
  535. if (! __0this -> playBack__16NurbsTessellator )((*(((void (*)(struct NurbsTessellator *))(__0this -> __vptr__16NurbsTessellator [1]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [1]).d))) ;
  536. __0this -> isTrimModified__16NurbsTessellator = 0 ;
  537. __0this -> isSurfaceModified__16NurbsTessellator = 0 ;
  538. __0this -> isDataValid__16NurbsTessellator = 1 ;
  539. __0this -> numTrims__16NurbsTessellator = 0 ;
  540. __0this -> currentSurface__16NurbsTessellator = __1o_surface ;
  541. __0this -> nextTrim__16NurbsTessellator = (& __0this -> currentSurface__16NurbsTessellator -> o_trim__9O_surface );
  542. __0this -> nextNurbssurface__16NurbsTessellator = (& __0this -> currentSurface__16NurbsTessellator -> o_nurbssurface__9O_surface );
  543. }
  544. void __glendcurve__16NurbsTessellat0 (struct NurbsTessellator *);
  545. void __gldo_bgncurve__16NurbsTessel0 (struct NurbsTessellator *__0this , struct O_curve *__1o_curve )
  546. {
  547. if (__0this -> inCurve__16NurbsTessellator ){
  548. __gldo_nurbserror__16NurbsTess0 ( __0this , 6 ) ;
  549. __glendcurve__16NurbsTessellat0 ( __0this ) ;
  550. }
  551. __0this -> inCurve__16NurbsTessellator = 1 ;
  552. __0this -> currentCurve__16NurbsTessellator = __1o_curve ;
  553. __0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve = 2;
  554. if (__0this -> inTrim__16NurbsTessellator ){
  555. if (((*__0this -> nextCurve__16NurbsTessellator ))!= __1o_curve ){
  556. __0this -> isCurveModified__16NurbsTessellator = 1 ;
  557. ((*__0this -> nextCurve__16NurbsTessellator ))= __1o_curve ;
  558. }
  559. }
  560. else
  561. {
  562. if (! __0this -> playBack__16NurbsTessellator )((*(((void (*)(struct NurbsTessellator *))(__0this -> __vptr__16NurbsTessellator [1]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [1]).d)))
  563. ;
  564. __0this -> isDataValid__16NurbsTessellator = 1 ;
  565. }
  566. __0this -> nextCurve__16NurbsTessellator = (& __1o_curve -> next__7O_curve );
  567. __0this -> nextPwlcurve__16NurbsTessellator = (& __1o_curve -> curve__7O_curve . o_pwlcurve );
  568. __0this -> nextNurbscurve__16NurbsTessellator = (& __1o_curve -> curve__7O_curve . o_nurbscurve );
  569. }
  570. void __gldo_freecurveall__16NurbsTe0 (struct NurbsTessellator *, struct O_curve *);
  571. void __glbeginQuilts__10SubdividerF0 (struct Subdivider *);
  572. void __gladdQuilt__10SubdividerFP5Q0 (struct Subdivider *, struct Quilt *);
  573. void __gldrawCurves__10SubdividerFv (struct Subdivider *);
  574. void __gldo_endcurve__16NurbsTessel0 (struct NurbsTessellator *__0this )
  575. {
  576. if (! __0this -> inCurve__16NurbsTessellator ){
  577. __gldo_nurbserror__16NurbsTess0 ( __0this , 7 ) ;
  578. return ;
  579. }
  580. __0this -> inCurve__16NurbsTessellator = 0 ;
  581. ((*__0this -> nextCurve__16NurbsTessellator ))= 0 ;
  582. if (__0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve == 0)
  583. ((*__0this -> nextNurbscurve__16NurbsTessellator ))= 0 ;
  584. else
  585. ((*__0this -> nextPwlcurve__16NurbsTessellator ))= 0 ;
  586. if (! __0this -> inTrim__16NurbsTessellator ){
  587. int __2errval ;
  588. if (! __0this -> isDataValid__16NurbsTessellator ){
  589. __gldo_freecurveall__16NurbsTe0 ( __0this , __0this -> currentCurve__16NurbsTessellator ) ;
  590. return ;
  591. }
  592. ;
  593. if ((__2errval = mysetjmp ( __0this -> jumpbuffer__16NurbsTessellator ) )== 0 ){
  594. if (__0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve == 0){
  595. __glbeginQuilts__10SubdividerF0 ( (struct
  596. Subdivider *)(& __0this -> subdivider__16NurbsTessellator )) ;
  597. { { struct O_nurbscurve *__4n ;
  598. __4n = __0this -> currentCurve__16NurbsTessellator -> curve__7O_curve . o_nurbscurve ;
  599. for(;__4n != 0 ;__4n = __4n -> next__12O_nurbscurve )
  600. __gladdQuilt__10SubdividerFP5Q0 ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator ), __4n -> bezier_curves__12O_nurbscurve ) ;
  601. ( 0 ) ;
  602. __gldrawCurves__10SubdividerFv ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator )) ;
  603. if (! __0this -> playBack__16NurbsTessellator )((*(((void (*)(struct NurbsTessellator *))(__0this -> __vptr__16NurbsTessellator [2]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [2]).d))) ;
  604. }
  605. }
  606. }
  607. else
  608. {
  609. if (! __0this -> playBack__16NurbsTessellator )((*(((void (*)(struct NurbsTessellator *))(__0this -> __vptr__16NurbsTessellator [2]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [2]).d)))
  610. ;
  611. ;
  612. __gldo_nurbserror__16NurbsTess0 ( __0this , 9 ) ;
  613. }
  614. }
  615. else
  616. {
  617. if (! __0this -> playBack__16NurbsTessellator )((*(((void (*)(struct NurbsTessellator *))(__0this -> __vptr__16NurbsTessellator [2]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [2]).d)))
  618. ;
  619. __gldo_nurbserror__16NurbsTess0 ( __0this , __2errval ) ;
  620. }
  621. __gldo_freecurveall__16NurbsTe0 ( __0this , __0this -> currentCurve__16NurbsTessellator ) ;
  622. __glresetObjects__16NurbsTesse0 ( __0this ) ;
  623. }
  624. }
  625. void __glendtrim__16NurbsTessellato0 (struct NurbsTessellator *);
  626. void __gldo_freeall__16NurbsTessell0 (struct NurbsTessellator *);
  627. void __gladdArc__10SubdividerFiP10T0 (struct Subdivider *, int , struct TrimVertex *, long );
  628. void __gladdArc__10SubdividerFPfP5Q0 (struct Subdivider *, REAL *, struct Quilt *, long );
  629. void __gldrawSurfaces__10Subdivider0 (struct Subdivider *, long );
  630. void __gldo_endsurface__16NurbsTess0 (struct NurbsTessellator *__0this )
  631. {
  632. int __1errval ;
  633. if (__0this -> inTrim__16NurbsTessellator ){
  634. __gldo_nurbserror__16NurbsTess0 ( __0this , 12 ) ;
  635. __glendtrim__16NurbsTessellato0 ( __0this ) ;
  636. }
  637. if (! __0this -> inSurface__16NurbsTessellator ){
  638. __gldo_nurbserror__16NurbsTess0 ( __0this , 13 ) ;
  639. return ;
  640. }
  641. __0this -> inSurface__16NurbsTessellator = 0 ;
  642. ((*__0this -> nextNurbssurface__16NurbsTessellator ))= 0 ;
  643. if (! __0this -> isDataValid__16NurbsTessellator ){
  644. __gldo_freeall__16NurbsTessell0 ( __0this ) ;
  645. return ;
  646. }
  647. if (((*__0this -> nextTrim__16NurbsTessellator ))!= 0 ){
  648. __0this -> isTrimModified__16NurbsTessellator = 1 ;
  649. ((*__0this -> nextTrim__16NurbsTessellator ))= 0 ;
  650. }
  651. ;
  652. if ((__1errval = mysetjmp ( __0this -> jumpbuffer__16NurbsTessellator ) )== 0 ){
  653. if (__0this -> numTrims__16NurbsTessellator > 0 ){
  654. ( 0 ) ;
  655. { { struct O_trim *__3trim ;
  656. __3trim = __0this -> currentSurface__16NurbsTessellator -> o_trim__9O_surface ;
  657. for(;__3trim ;__3trim = __3trim -> next__6O_trim ) {
  658. ( (((struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator ))-> pjarc__10Subdivider = 0 )) ;
  659. { { struct O_curve *__4curve ;
  660. __4curve = __3trim -> o_curve__6O_trim ;
  661. for(;__4curve ;__4curve = __4curve -> next__7O_curve ) {
  662. __4curve -> used__7O_curve = 0 ;
  663. ((void )0 );
  664. if (__4curve -> curvetype__7O_curve == 1){
  665. struct O_pwlcurve *__6c ;
  666. __6c = __4curve -> curve__7O_curve . o_pwlcurve ;
  667. __gladdArc__10SubdividerFiP10T0 ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator ), __6c -> npts__10O_pwlcurve , __6c -> pts__10O_pwlcurve , __4curve -> nuid__7O_curve ) ;
  668. }
  669. else
  670. {
  671. struct Quilt *__6quilt ;
  672. struct Quiltspec *__6qspec ;
  673. REAL *__6cpts ;
  674. REAL *__6cptsend ;
  675. __6quilt = __4curve -> curve__7O_curve . o_nurbscurve -> bezier_curves__12O_nurbscurve ;
  676. __6qspec = __6quilt -> qspec__5Quilt ;
  677. __6cpts = (__6quilt -> cpts__5Quilt + __6qspec -> offset__9Quiltspec );
  678. __6cptsend = (__6cpts + ((__6qspec -> width__9Quiltspec * __6qspec -> order__9Quiltspec )* __6qspec -> stride__9Quiltspec ));
  679. for(;__6cpts != __6cptsend ;__6cpts += (__6qspec -> order__9Quiltspec * __6qspec -> stride__9Quiltspec ))
  680. __gladdArc__10SubdividerFPfP5Q0 ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator ), __6cpts , __6quilt , __4curve ->
  681. nuid__7O_curve ) ;
  682. }
  683. }
  684. ( 0 ) ;
  685. }
  686. }
  687. }
  688. ( 0 ) ;
  689. }
  690. }
  691. }
  692. __glbeginQuilts__10SubdividerF0 ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator )) ;
  693. { { struct O_nurbssurface *__2n ;
  694. __2n = __0this -> currentSurface__16NurbsTessellator -> o_nurbssurface__9O_surface ;
  695. for(;__2n ;__2n = __2n -> next__14O_nurbssurface )
  696. __gladdQuilt__10SubdividerFP5Q0 ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator ), __2n -> bezier_patches__14O_nurbssurface ) ;
  697. ( 0 ) ;
  698. __gldrawSurfaces__10Subdivider0 ( (struct Subdivider *)(& __0this -> subdivider__16NurbsTessellator ), __0this -> currentSurface__16NurbsTessellator -> nuid__9O_surface ) ;
  699. if (! __0this -> playBack__16NurbsTessellator )((*(((void (*)(struct NurbsTessellator *))(__0this -> __vptr__16NurbsTessellator [2]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [2]).d))) ;
  700. }
  701. }
  702. }
  703. else
  704. {
  705. if (! __0this -> playBack__16NurbsTessellator )((*(((void (*)(struct NurbsTessellator *))(__0this -> __vptr__16NurbsTessellator [2]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [2]).d)))
  706. ;
  707. __gldo_nurbserror__16NurbsTess0 ( __0this , __1errval ) ;
  708. }
  709. __gldo_freeall__16NurbsTessell0 ( __0this ) ;
  710. __glresetObjects__16NurbsTesse0 ( __0this ) ;
  711. }
  712. void __gldo_freebgntrim__16NurbsTes0 (struct NurbsTessellator *, struct O_trim *);
  713. void __gldo_freenurbssurface__16Nur0 (struct NurbsTessellator *, struct O_nurbssurface *);
  714. void __gldo_freeall__16NurbsTessell0 (struct NurbsTessellator *__0this )
  715. {
  716. { { struct O_trim *__1o_trim ;
  717. struct O_nurbssurface *__1nurbss ;
  718. struct O_nurbssurface *__1next_nurbss ;
  719. __1o_trim = __0this -> currentSurface__16NurbsTessellator -> o_trim__9O_surface ;
  720. for(;__1o_trim ;) {
  721. struct O_trim *__2next_o_trim ;
  722. __2next_o_trim = __1o_trim -> next__6O_trim ;
  723. { { struct O_curve *__2curve ;
  724. __2curve = __1o_trim -> o_curve__6O_trim ;
  725. for(;__2curve ;) {
  726. struct O_curve *__3next_o_curve ;
  727. __3next_o_curve = __2curve -> next__7O_curve ;
  728. __gldo_freecurveall__16NurbsTe0 ( __0this , __2curve ) ;
  729. __2curve = __3next_o_curve ;
  730. }
  731. if (__1o_trim -> save__6O_trim == 0 )__gldo_freebgntrim__16NurbsTes0 ( __0this , __1o_trim ) ;
  732. __1o_trim = __2next_o_trim ;
  733. }
  734. }
  735. }
  736. ;
  737. ;
  738. for(__1nurbss = __0this -> currentSurface__16NurbsTessellator -> o_nurbssurface__9O_surface ;__1nurbss ;__1nurbss = __1next_nurbss ) {
  739. __1next_nurbss = __1nurbss -> next__14O_nurbssurface ;
  740. if (__1nurbss -> save__14O_nurbssurface == 0 )
  741. __gldo_freenurbssurface__16Nur0 ( __0this , __1nurbss ) ;
  742. else
  743. __1nurbss -> used__14O_nurbssurface = 0 ;
  744. }
  745. if (__0this -> currentSurface__16NurbsTessellator -> save__9O_surface == 0 )__gldo_freebgnsurface__16Nurbs0 ( __0this , __0this -> currentSurface__16NurbsTessellator ) ;
  746. }
  747. }
  748. }
  749. void __gldo_freenurbscurve__16Nurbs0 (struct NurbsTessellator *, struct O_nurbscurve *);
  750. void __gldo_freepwlcurve__16NurbsTe0 (struct NurbsTessellator *, struct O_pwlcurve *);
  751. void __gldo_freebgncurve__16NurbsTe0 (struct NurbsTessellator *, struct O_curve *);
  752. void __gldo_freecurveall__16NurbsTe0 (struct NurbsTessellator *__0this , struct O_curve *__1curve )
  753. {
  754. ((void )0 );
  755. if (__1curve -> curvetype__7O_curve == 0){
  756. struct O_nurbscurve *__2ncurve ;
  757. struct O_nurbscurve *__2next_ncurve ;
  758. for(__2ncurve = __1curve -> curve__7O_curve . o_nurbscurve ;__2ncurve ;__2ncurve = __2next_ncurve ) {
  759. __2next_ncurve = __2ncurve -> next__12O_nurbscurve ;
  760. if (__2ncurve -> save__12O_nurbscurve == 0 )
  761. __gldo_freenurbscurve__16Nurbs0 ( __0this , __2ncurve ) ;
  762. else
  763. __2ncurve -> used__12O_nurbscurve = 0 ;
  764. }
  765. }
  766. else
  767. {
  768. struct O_pwlcurve *__2pcurve ;
  769. struct O_pwlcurve *__2next_pcurve ;
  770. for(__2pcurve = __1curve -> curve__7O_curve . o_pwlcurve ;__2pcurve ;__2pcurve = __2next_pcurve ) {
  771. __2next_pcurve = __2pcurve -> next__10O_pwlcurve ;
  772. if (__2pcurve -> save__10O_pwlcurve == 0 )
  773. __gldo_freepwlcurve__16NurbsTe0 ( __0this , __2pcurve ) ;
  774. else
  775. __2pcurve -> used__10O_pwlcurve = 0 ;
  776. }
  777. }
  778. if (__1curve -> save__7O_curve == 0 )
  779. __gldo_freebgncurve__16NurbsTe0 ( __0this , __1curve ) ;
  780. }
  781. void __gldo_freebgntrim__16NurbsTes0 (struct NurbsTessellator *__0this , struct O_trim *__1o_trim )
  782. {
  783. ( ( (((void )0 )), ( ((((struct Buffer *)(((struct Buffer *)(((void *)((struct
  784. PooledObj *)__1o_trim )))))))-> next__6Buffer = ((struct Pool *)((struct Pool *)(& __0this -> o_trimPool__16NurbsTessellator )))-> freelist__4Pool ), (((struct Pool *)((struct Pool *)(& __0this -> o_trimPool__16NurbsTessellator )))-> freelist__4Pool =
  785. (((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_trim ))))))))) ) ) ;
  786. }
  787. void __glbgnsurface__16NurbsTessell0 (struct NurbsTessellator *, long );
  788. void __gldo_bgntrim__16NurbsTessell0 (struct NurbsTessellator *__0this , struct O_trim *__1o_trim )
  789. {
  790. if (! __0this -> inSurface__16NurbsTessellator ){
  791. __gldo_nurbserror__16NurbsTess0 ( __0this , 15 ) ;
  792. __glbgnsurface__16NurbsTessell0 ( __0this , (long )0 ) ;
  793. __0this -> inSurface__16NurbsTessellator = 2 ;
  794. }
  795. if (__0this -> inTrim__16NurbsTessellator ){
  796. __gldo_nurbserror__16NurbsTess0 ( __0this , 16 ) ;
  797. __glendtrim__16NurbsTessellato0 ( __0this ) ;
  798. }
  799. __0this -> inTrim__16NurbsTessellator = 1 ;
  800. if (((*__0this -> nextTrim__16NurbsTessellator ))!= __1o_trim ){
  801. __0this -> isTrimModified__16NurbsTessellator = 1 ;
  802. ((*__0this -> nextTrim__16NurbsTessellator ))= __1o_trim ;
  803. }
  804. __0this -> currentTrim__16NurbsTessellator = __1o_trim ;
  805. __0this -> nextTrim__16NurbsTessellator = (& __1o_trim -> next__6O_trim );
  806. __0this -> nextCurve__16NurbsTessellator = (& __1o_trim -> o_curve__6O_trim );
  807. }
  808. void __gldo_endtrim__16NurbsTessell0 (struct NurbsTessellator *__0this )
  809. {
  810. if (! __0this -> inTrim__16NurbsTessellator ){
  811. __gldo_nurbserror__16NurbsTess0 ( __0this , 17 ) ;
  812. return ;
  813. }
  814. __0this -> inTrim__16NurbsTessellator = 0 ;
  815. if (__0this -> currentTrim__16NurbsTessellator -> o_curve__6O_trim == 0 ){
  816. __gldo_nurbserror__16NurbsTess0 ( __0this , 18 ) ;
  817. __0this -> isDataValid__16NurbsTessellator = 0 ;
  818. }
  819. __0this -> numTrims__16NurbsTessellator ++ ;
  820. if (((*__0this -> nextCurve__16NurbsTessellator ))!= 0 ){
  821. __0this -> isTrimModified__16NurbsTessellator = 1 ;
  822. ((*__0this -> nextCurve__16NurbsTessellator ))= 0 ;
  823. }
  824. }
  825. void __gldo_freepwlcurve__16NurbsTe0 (struct NurbsTessellator *__0this , struct O_pwlcurve *__1o_pwlcurve )
  826. {
  827. ( ( (((void )0 )), ( ((((struct Buffer *)(((struct Buffer *)(((void *)((struct
  828. PooledObj *)__1o_pwlcurve )))))))-> next__6Buffer = ((struct Pool *)((struct Pool *)(& __0this -> o_pwlcurvePool__16NurbsTessellator )))-> freelist__4Pool ), (((struct Pool *)((struct Pool *)(& __0this -> o_pwlcurvePool__16NurbsTessellator )))-> freelist__4Pool =
  829. (((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_pwlcurve ))))))))) ) ) ;
  830. }
  831. void __gldo_freebgncurve__16NurbsTe0 (struct NurbsTessellator *__0this , struct O_curve *__1o_curve )
  832. {
  833. ( ( (((void )0 )), ( ((((struct Buffer *)(((struct Buffer *)(((void *)((struct
  834. PooledObj *)__1o_curve )))))))-> next__6Buffer = ((struct Pool *)((struct Pool *)(& __0this -> o_curvePool__16NurbsTessellator )))-> freelist__4Pool ), (((struct Pool *)((struct Pool *)(& __0this -> o_curvePool__16NurbsTessellator )))-> freelist__4Pool =
  835. (((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_curve ))))))))) ) ) ;
  836. }
  837. void __glbgncurve__16NurbsTessellat0 (struct NurbsTessellator *, long );
  838. void __gldo_pwlcurve__16NurbsTessel0 (struct NurbsTessellator *__0this , struct O_pwlcurve *__1o_pwlcurve )
  839. {
  840. if (! __0this -> inTrim__16NurbsTessellator ){
  841. __gldo_nurbserror__16NurbsTess0 ( __0this , 19 ) ;
  842. if (__1o_pwlcurve -> save__10O_pwlcurve == 0 )
  843. __gldo_freepwlcurve__16NurbsTe0 ( __0this , __1o_pwlcurve ) ;
  844. return ;
  845. }
  846. if (! __0this -> inCurve__16NurbsTessellator ){
  847. __glbgncurve__16NurbsTessellat0 ( __0this , (long )0 ) ;
  848. __0this -> inCurve__16NurbsTessellator = 2 ;
  849. }
  850. if (__1o_pwlcurve -> used__10O_pwlcurve ){
  851. __gldo_nurbserror__16NurbsTess0 ( __0this , 20 ) ;
  852. __0this -> isDataValid__16NurbsTessellator = 0 ;
  853. return ;
  854. }
  855. else __1o_pwlcurve -> used__10O_pwlcurve = 1 ;
  856. if (__0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve == 2){
  857. __0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve = 1;
  858. }
  859. else
  860. if (__0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve != 1){
  861. __gldo_nurbserror__16NurbsTess0 ( __0this , 21 ) ;
  862. __0this -> isDataValid__16NurbsTessellator = 0 ;
  863. return ;
  864. }
  865. if (((*__0this -> nextPwlcurve__16NurbsTessellator ))!= __1o_pwlcurve ){
  866. __0this -> isCurveModified__16NurbsTessellator = 1 ;
  867. ((*__0this -> nextPwlcurve__16NurbsTessellator ))= __1o_pwlcurve ;
  868. }
  869. __0this -> nextPwlcurve__16NurbsTessellator = (& __1o_pwlcurve -> next__10O_pwlcurve );
  870. if (__1o_pwlcurve -> owner__10O_pwlcurve != __0this -> currentCurve__16NurbsTessellator ){
  871. __0this -> isCurveModified__16NurbsTessellator = 1 ;
  872. __1o_pwlcurve -> owner__10O_pwlcurve = __0this -> currentCurve__16NurbsTessellator ;
  873. }
  874. if (__0this -> inCurve__16NurbsTessellator == 2 )
  875. __glendcurve__16NurbsTessellat0 ( __0this ) ;
  876. }
  877. void __gldeleteMe__5QuiltFR4Pool (struct Quilt *, struct Pool *);
  878. void __gldo_freenurbscurve__16Nurbs0 (struct NurbsTessellator *__0this , struct O_nurbscurve *__1o_nurbscurve )
  879. {
  880. __gldeleteMe__5QuiltFR4Pool ( (struct Quilt *)__1o_nurbscurve -> bezier_curves__12O_nurbscurve , (struct Pool *)(& __0this -> quiltPool__16NurbsTessellator )) ;
  881. ( ( (((void )0 )), ( ((((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_nurbscurve )))))))-> next__6Buffer = ((struct Pool *)((struct Pool *)(&
  882. __0this -> o_nurbscurvePool__16NurbsTessellator )))-> freelist__4Pool ), (((struct Pool *)((struct Pool *)(& __0this -> o_nurbscurvePool__16NurbsTessellator )))-> freelist__4Pool = (((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_nurbscurve )))))))))
  883. ) ) ;
  884. }
  885. void __gldo_nurbscurve__16NurbsTess0 (struct NurbsTessellator *__0this , struct O_nurbscurve *__1o_nurbscurve )
  886. {
  887. if (! __0this -> inCurve__16NurbsTessellator ){
  888. __glbgncurve__16NurbsTessellat0 ( __0this , (long )0 ) ;
  889. __0this -> inCurve__16NurbsTessellator = 2 ;
  890. }
  891. if (__1o_nurbscurve -> used__12O_nurbscurve ){
  892. __gldo_nurbserror__16NurbsTess0 ( __0this , 23 ) ;
  893. __0this -> isDataValid__16NurbsTessellator = 0 ;
  894. return ;
  895. }
  896. else __1o_nurbscurve -> used__12O_nurbscurve = 1 ;
  897. if (__0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve == 2){
  898. __0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve = 0;
  899. }
  900. else
  901. if (__0this -> currentCurve__16NurbsTessellator -> curvetype__7O_curve != 0){
  902. __gldo_nurbserror__16NurbsTess0 ( __0this , 24 ) ;
  903. __0this -> isDataValid__16NurbsTessellator = 0 ;
  904. return ;
  905. }
  906. if (((*__0this -> nextNurbscurve__16NurbsTessellator ))!= __1o_nurbscurve ){
  907. __0this -> isCurveModified__16NurbsTessellator = 1 ;
  908. ((*__0this -> nextNurbscurve__16NurbsTessellator ))= __1o_nurbscurve ;
  909. }
  910. __0this -> nextNurbscurve__16NurbsTessellator = (& __1o_nurbscurve -> next__12O_nurbscurve );
  911. if (__1o_nurbscurve -> owner__12O_nurbscurve != __0this -> currentCurve__16NurbsTessellator ){
  912. __0this -> isCurveModified__16NurbsTessellator = 1 ;
  913. __1o_nurbscurve -> owner__12O_nurbscurve = __0this -> currentCurve__16NurbsTessellator ;
  914. }
  915. if (__1o_nurbscurve -> owner__12O_nurbscurve == 0 )
  916. __0this -> isCurveModified__16NurbsTessellator = 1 ;
  917. if (__0this -> inCurve__16NurbsTessellator == 2 )
  918. __glendcurve__16NurbsTessellat0 ( __0this ) ;
  919. }
  920. void __gldo_freenurbssurface__16Nur0 (struct NurbsTessellator *__0this , struct O_nurbssurface *__1o_nurbssurface )
  921. {
  922. __gldeleteMe__5QuiltFR4Pool ( (struct Quilt *)__1o_nurbssurface -> bezier_patches__14O_nurbssurface , (struct Pool *)(& __0this -> quiltPool__16NurbsTessellator )) ;
  923. ( ( (((void )0 )), ( ((((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_nurbssurface )))))))-> next__6Buffer = ((struct Pool *)((struct Pool *)(&
  924. __0this -> o_nurbssurfacePool__16NurbsTessellator )))-> freelist__4Pool ), (((struct Pool *)((struct Pool *)(& __0this -> o_nurbssurfacePool__16NurbsTessellator )))-> freelist__4Pool = (((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1o_nurbssurface )))))))))
  925. ) ) ;
  926. }
  927. void __gldo_nurbssurface__16NurbsTe0 (struct NurbsTessellator *__0this , struct O_nurbssurface *__1o_nurbssurface )
  928. {
  929. if (! __0this -> inSurface__16NurbsTessellator ){
  930. __glbgnsurface__16NurbsTessell0 ( __0this , (long )0 ) ;
  931. __0this -> inSurface__16NurbsTessellator = 2 ;
  932. }
  933. if (__1o_nurbssurface -> used__14O_nurbssurface ){
  934. __gldo_nurbserror__16NurbsTess0 ( __0this , 25 ) ;
  935. __0this -> isDataValid__16NurbsTessellator = 0 ;
  936. return ;
  937. }
  938. else __1o_nurbssurface -> used__14O_nurbssurface = 1 ;
  939. if (((*__0this -> nextNurbssurface__16NurbsTessellator ))!= __1o_nurbssurface ){
  940. __0this -> isSurfaceModified__16NurbsTessellator = 1 ;
  941. ((*__0this -> nextNurbssurface__16NurbsTessellator ))= __1o_nurbssurface ;
  942. }
  943. if (__1o_nurbssurface -> owner__14O_nurbssurface != __0this -> currentSurface__16NurbsTessellator ){
  944. __0this -> isSurfaceModified__16NurbsTessellator = 1 ;
  945. __1o_nurbssurface -> owner__14O_nurbssurface = __0this -> currentSurface__16NurbsTessellator ;
  946. }
  947. __0this -> nextNurbssurface__16NurbsTessellator = (& __1o_nurbssurface -> next__14O_nurbssurface );
  948. if (__0this -> inSurface__16NurbsTessellator == 2 )
  949. __glendsurface__16NurbsTessell0 ( __0this ) ;
  950. }
  951. void __gldo_freenurbsproperty__16Nu0 (struct NurbsTessellator *__0this , struct Property *__1prop )
  952. {
  953. ( ( (((void )0 )), ( ((((struct Buffer *)(((struct Buffer *)(((void *)((struct
  954. PooledObj *)__1prop )))))))-> next__6Buffer = ((struct Pool *)((struct Pool *)(& __0this -> propertyPool__16NurbsTessellator )))-> freelist__4Pool ), (((struct Pool *)((struct Pool *)(& __0this -> propertyPool__16NurbsTessellator )))-> freelist__4Pool =
  955. (((struct Buffer *)(((struct Buffer *)(((void *)((struct PooledObj *)__1prop ))))))))) ) ) ;
  956. }
  957. void __glsetProperty__11Renderhints0 (struct Renderhints *, long , REAL );
  958. void __gldo_setnurbsproperty__16Nur0 (struct NurbsTessellator *__0this , struct Property *__1prop )
  959. {
  960. __glsetProperty__11Renderhints0 ( (struct Renderhints *)(& __0this -> renderhints__16NurbsTessellator ), __1prop -> tag__8Property , __1prop -> value__8Property )
  961. ;
  962. if (__1prop -> save__8Property == 0 )
  963. __gldo_freenurbsproperty__16Nu0 ( __0this , __1prop ) ;
  964. }
  965. struct Mapdesc *__glfind__7MaplistFl (struct Maplist *, long );
  966. void __glsetProperty__7MapdescFlf (struct Mapdesc *, long , REAL );
  967. void __gldo_setnurbsproperty2__16Nu0 (struct NurbsTessellator *__0this , struct Property *__1prop )
  968. {
  969. struct Mapdesc *__1mapdesc ;
  970. __1mapdesc = __glfind__7MaplistFl ( (struct Maplist *)(& __0this -> maplist__16NurbsTessellator ), __1prop -> type__8Property ) ;
  971. __glsetProperty__7MapdescFlf ( (struct Mapdesc *)__1mapdesc , __1prop -> tag__8Property , __1prop -> value__8Property ) ;
  972. if (__1prop -> save__8Property == 0 )
  973. __gldo_freenurbsproperty__16Nu0 ( __0this , __1prop ) ;
  974. }
  975. void __glerrorHandler__16NurbsTesse0 (struct NurbsTessellator *__0this , int __1__A15 )
  976. {
  977. }
  978. void __gldo_nurbserror__16NurbsTess0 (struct NurbsTessellator *__0this , int __1msg )
  979. {
  980. ((*(((void (*)(struct NurbsTessellator *, int
  981. ))(__0this -> __vptr__16NurbsTessellator [5]).f))))( ((struct NurbsTessellator *)((((char *)__0this ))+ (__0this -> __vptr__16NurbsTessellator [5]).d)), __1msg ) ;
  982. }
  983. int __glvalidate__10KnotvectorFv (struct Knotvector *);
  984. void __glshow__10KnotvectorFPc (struct Knotvector *, char *);
  985. int __gldo_check_knots__16NurbsTes0 (struct NurbsTessellator *__0this , struct Knotvector *__1knots , char *__1msg )
  986. {
  987. int __1status ;
  988. __1status = __glvalidate__10KnotvectorFv ( (struct Knotvector *)__1knots ) ;
  989. if (__1status ){
  990. __gldo_nurbserror__16NurbsTess0 ( __0this , __1status ) ;
  991. if (__0this -> renderhints__16NurbsTessellator . errorchecking__11Renderhints != 0.0 )__glshow__10KnotvectorFPc ( (struct Knotvector *)__1knots , __1msg ) ;
  992. }
  993. return __1status ;
  994. }
  995. struct __mptr __gl__vtbl__16NurbsTessellator[] = {0,0,0,
  996. 0,0,(__vptp)__glbgnrender__16NurbsTessella0 ,
  997. 0,0,(__vptp)__glendrender__16NurbsTessella0 ,
  998. 0,0,(__vptp)__glmakeobj__16NurbsTessellato0 ,
  999. 0,0,(__vptp)__glcloseobj__16NurbsTessellat0 ,
  1000. 0,0,(__vptp)__glerrorHandler__16NurbsTesse0 ,
  1001. 0,0,0};
  1002. /* the end */