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.

188 lines
4.2 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 <stdlib.h>
  19. #include <setjmp.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/renderhints.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. typedef float REAL ;
  37. typedef void (*Pfvv )(void );
  38. typedef void (*Pfvf )(float *);
  39. typedef int (*cmpfunc )(void *, void *);
  40. typedef REAL Knot ;
  41. typedef REAL *Knot_ptr ;
  42. struct Renderhints;
  43. struct Renderhints {
  44. REAL display_method__11Renderhints ;
  45. REAL errorchecking__11Renderhints ;
  46. REAL subdivisions__11Renderhints ;
  47. REAL tmp1__11Renderhints ;
  48. int displaydomain__11Renderhints ;
  49. int maxsubdivisions__11Renderhints ;
  50. int wiretris__11Renderhints ;
  51. int wirequads__11Renderhints ;
  52. };
  53. extern struct __mptr* __ptbl_vec_____core_renderhints_c_____ct_[];
  54. struct Renderhints *__gl__ct__11RenderhintsFv (struct Renderhints *__0this )
  55. {
  56. void *__1__Xp00uzigaiaa ;
  57. if (__0this || (__0this = (struct Renderhints *)( (__1__Xp00uzigaiaa = malloc ( (sizeof (struct Renderhints))) ), (__1__Xp00uzigaiaa ?(((void *)__1__Xp00uzigaiaa )):(((void *)__1__Xp00uzigaiaa )))) )){
  58. __0this -> display_method__11Renderhints = 1.0 ;
  59. __0this -> errorchecking__11Renderhints = 1.0 ;
  60. __0this -> subdivisions__11Renderhints = 6.0 ;
  61. __0this -> tmp1__11Renderhints = 0.0 ;
  62. } return __0this ;
  63. }
  64. void __glinit__11RenderhintsFv (struct Renderhints *__0this )
  65. {
  66. __0this -> maxsubdivisions__11Renderhints = (((int )__0this -> subdivisions__11Renderhints ));
  67. if (__0this -> maxsubdivisions__11Renderhints < 0 )__0this -> maxsubdivisions__11Renderhints = 0 ;
  68. if (__0this -> display_method__11Renderhints == 1.0 ){
  69. __0this -> wiretris__11Renderhints = 0 ;
  70. __0this -> wirequads__11Renderhints = 0 ;
  71. }
  72. else
  73. if (__0this -> display_method__11Renderhints == 3.0 ){
  74. __0this -> wiretris__11Renderhints = 1 ;
  75. __0this -> wirequads__11Renderhints = 0 ;
  76. }
  77. else
  78. if (__0this -> display_method__11Renderhints == 4.0 ){
  79. __0this -> wiretris__11Renderhints = 0 ;
  80. __0this -> wirequads__11Renderhints = 1 ;
  81. }
  82. else
  83. {
  84. __0this -> wiretris__11Renderhints = 1 ;
  85. __0this -> wirequads__11Renderhints = 1 ;
  86. }
  87. }
  88. int __glisProperty__11RenderhintsF0 (struct Renderhints *__0this , long __1property )
  89. {
  90. switch (__1property ){
  91. case 3 :
  92. case 4 :
  93. case 5 :
  94. case 9 :
  95. return 1 ;
  96. default :
  97. return 0 ;
  98. }
  99. }
  100. // extern void abort (void );
  101. REAL __glgetProperty__11Renderhints0 (struct Renderhints *__0this , long __1property )
  102. {
  103. switch (__1property ){
  104. case 3 :
  105. return __0this -> display_method__11Renderhints ;
  106. case 4 :
  107. return __0this -> errorchecking__11Renderhints ;
  108. case 5 :
  109. return __0this -> subdivisions__11Renderhints ;
  110. case 9 :
  111. return __0this -> tmp1__11Renderhints ;
  112. default :
  113. abort ( ) ;
  114. break ;
  115. }
  116. }
  117. void __glsetProperty__11Renderhints0 (struct Renderhints *__0this , long __1property , REAL __1value )
  118. {
  119. switch (__1property ){
  120. case 3 :
  121. __0this -> display_method__11Renderhints = __1value ;
  122. break ;
  123. case 4 :
  124. __0this -> errorchecking__11Renderhints = __1value ;
  125. break ;
  126. case 5 :
  127. __0this -> subdivisions__11Renderhints = __1value ;
  128. break ;
  129. case 9 :
  130. __0this -> tmp1__11Renderhints = __1value ;
  131. break ;
  132. default :
  133. abort ( ) ;
  134. break ;
  135. }
  136. }
  137. /* the end */