mantielero

Untitled

Nov 12th, 2022
182
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 41.24 KB | None | 0 0
  1. /* Generated by Nim Compiler v1.6.6 */
  2. /* Compiled for: Linux, amd64, gcc */
  3. /* Command for C compiler:
  4.    g++ -c -std=gnu++14 -funsigned-char  -w -fmax-errors=3 -fpermissive -I/usr/include/opencascade/ -I/usr/import/opencascade/   -I/home/jose/.choosenim/toolchains/nim-1.6.6/lib -I/home/jose/src/nimlang/occt.nim/examples -o /home/jose/src/nimlang/occt.nim/examples/cache/@mviewer04.nim.cpp.o /home/jose/src/nimlang/occt.nim/examples/cache/@mviewer04.nim.cpp */
  5. #define NIM_INTBITS 64
  6.  
  7. #include "nimbase.h"
  8. #include "Standard_Handle.hxx"
  9. #include "AIS_ViewController.hxx"
  10. #include "AIS_InteractiveContext.hxx"
  11. #include "Standard_Transient.hxx"
  12. #include "V3d_View.hxx"
  13. #include <string.h>
  14. #include "Aspect_DisplayConnection.hxx"
  15. #include "OpenGl_GraphicDriver.hxx"
  16. #include "Graphic3d_GraphicDriver.hxx"
  17. #include "V3d_Viewer.hxx"
  18. #include "V3d_TypeOfView.hxx"
  19. #include "Xw_Window.hxx"
  20. #include "Aspect_Window.hxx"
  21. #include "Quantity_Color.hxx"
  22. #include "Quantity_NameOfColor.hxx"
  23. #include "Aspect_TypeOfTriedronPosition.hxx"
  24. #include "V3d_TypeOfVisualization.hxx"
  25. #include "Graphic3d_RenderingParams.hxx"
  26. #include "BRepPrimAPI_MakeBox.hxx"
  27. #include "BRepBuilderAPI_MakeShape.hxx"
  28. #include "BRepBuilderAPI_Command.hxx"
  29. #include "TopoDS_Solid.hxx"
  30. #include "TopoDS_Shape.hxx"
  31. #include "AIS_Shape.hxx"
  32. #include "AIS_InteractiveObject.hxx"
  33. #include "SelectMgr_SelectableObject.hxx"
  34. #include "PrsMgr_PresentableObject.hxx"
  35. #include "AIS_DisplayStatus.hxx"
  36. #undef LANGUAGE_C
  37. #undef MIPSEB
  38. #undef MIPSEL
  39. #undef PPC
  40. #undef R3000
  41. #undef R4000
  42. #undef i386
  43. #undef linux
  44. #undef mips
  45. #undef near
  46. #undef far
  47. #undef powerpc
  48. #undef unix
  49.   #  define nimfr_(proc, file) \
  50.       TFrame FR_; \
  51.       FR_.procname = proc; FR_.filename = file; FR_.line = 0; FR_.len = 0; nimFrame(&FR_);
  52.  
  53.   #  define nimfrs_(proc, file, slots, length) \
  54.       struct {TFrame* prev;NCSTRING procname;NI line;NCSTRING filename; NI len; VarSlot s[slots];} FR_; \
  55.       FR_.procname = proc; FR_.filename = file; FR_.line = 0; FR_.len = length; nimFrame((TFrame*)&FR_);
  56.  
  57.   #  define nimln_(n, file) \
  58.       FR_.line = n; FR_.filename = file;
  59.   struct tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg;
  60. struct tyTuple__mOcJMV5G9c4Xbhu28ljzjXA;
  61. struct tyObject_NSOpenGLContext__cXoy3V9c0amLPn8ieCuKwyA;
  62. struct tyObject_ValueError__yoNlBGx0D2tRizIdhQuENw;
  63. struct tyObject_CatchableError__qrLSDoe2oBoAqNtJ9badtnA;
  64. struct Exception;
  65. struct RootObj;
  66. struct TNimType;
  67. struct TNimNode;
  68. struct NimStringDesc;
  69. struct TGenericSeq;
  70. struct tySequence__uB9b75OUPRENsBAu4AnoePA;
  71. struct tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g;
  72. struct tyObject_CellSeq__Axo1XVm9aaQueTOldv8le5w;
  73. struct tyObject_GcHeap__1TRH1TZMaVZTnLNcIHuNFQ;
  74. struct tyObject_GcStack__7fytPA5bBsob6See21YMRA;
  75. struct tyObject_MemRegion__x81NhDv59b8ercDZ9bi85jyg;
  76. struct tyObject_SmallChunk__tXn60W2f8h3jgAYdEmy5NQ;
  77. struct tyObject_BigChunk__Rv9c70Uhp2TytkX7eH78qEg;
  78. struct tyObject_LLChunk__XsENErzHIZV9bhvyJx56wGw;
  79. struct tyObject_IntSet__EZObFrE3NC9bIb3YMkY9crZA;
  80. struct tyObject_Trunk__W0r8S0Y3UGke6T9bIUWnnuw;
  81. struct tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw;
  82. struct tyObject_HeapLinks__PDV1HBZ8CQSQJC9aOBFNRSg;
  83. struct tyTuple__ujsjpB2O9cjj3uDHsXbnSzg;
  84. struct tyObject_GcStat__0RwLoVBHZPfUAcLczmfQAg;
  85. struct tyObject_CellSet__jG87P0AI9aZtss9ccTYBIISQ;
  86. struct tyObject_PageDesc__fublkgIY4LG3mT51LU2WHg;
  87. union tyObject_XEvent__EZvRvOUywFnBp4PzilZBoA;
  88. struct tyObject_XAnyEvent__1ezXFSdvNym3JpvCnlsENg;
  89. struct tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q;
  90. struct tyObject_XKeyEvent__R59aUOCz38cH7kW8WZOY0fg;
  91. struct tyObject_XButtonEvent__iRbydJb1sLXZm2LAsp2Y9cA;
  92. struct tyObject_XMotionEvent__quIqNclnyTLRzhZ9baI9b4Mw;
  93. struct tyObject_XCrossingEvent__CwFNdmeikq1aI6Csp6M1TA;
  94. struct tyObject_XFocusChangeEvent__qWetk9cjWxGBS3eJVs3yD8g;
  95. struct tyObject_XExposeEvent__GlotzqzjF0UF69cdWtF3UmA;
  96. struct tyObject_XGraphicsExposeEvent__vqoMwYGbpvggSS5CE7yfDg;
  97. struct tyObject_XNoExposeEvent__OBeJnywKIxPbSlIDKzOCAw;
  98. struct tyObject_XVisibilityEvent__QIE8z6fsM14nzlNuZ4qx1g;
  99. struct tyObject_XCreateWindowEvent__gkTdbvHrseR8byhpmIGCOQ;
  100. struct tyObject_XDestroyWindowEvent__Tp9aCI6GD3XFIuCb9bdElOuQ;
  101. struct tyObject_XUnmapEvent__dcLuf3f3TlbopgMrXs9bCGQ;
  102. struct tyObject_XMapEvent__RhdYUwfbWPzmyx2xTyV2FA;
  103. struct tyObject_XMapRequestEvent__FaVNekhwNIncxldv52k8Lw;
  104. struct tyObject_XReparentEvent__0ud6oL9auF2YpEcfxEUnWsw;
  105. struct tyObject_XConfigureEvent__t9c9cC7EhkcyFJI9aMaDAboHA;
  106. struct tyObject_XGravityEvent__i47ge3KLMlyylKb7nomPgQ;
  107. struct tyObject_XResizeRequestEvent__6P9c2mszwxUkchOWHCWX4pw;
  108. struct tyObject_XConfigureRequestEvent__lqOXYk4ucPkV6vo82rcRfA;
  109. struct tyObject_XCirculateEvent__PZ5EpxBAqiDQSX2toN9bNVQ;
  110. struct tyObject_XCirculateRequestEvent__d1aa9cXr9a9bw8vIT3mxwrJoQ;
  111. struct tyObject_XPropertyEvent__8VLR5srdJmMgpN5n3xA9aYQ;
  112. struct tyObject_XSelectionClearEvent__bln1Oj561KhuR8PFhQdugA;
  113. struct tyObject_XSelectionRequestEvent__FKYV6bvwXA2X0DguhHqR9ag;
  114. struct tyObject_XSelectionEvent__vVuKKVLJTVeC347zxsVdyg;
  115. struct tyObject_XColormapEvent__uqOhwoxMeCXt84TvPXgUgA;
  116. struct tyObject_XClientMessageEvent__xo4p0BsKjqHQ1YGbKn8Gwg;
  117. union tyObject_XClientMessageData__OKbi4O7vRg7iM9cNCZ0JrCA;
  118. struct tyObject_XMappingEvent__9boqTjTHll5ddMwGFM6CFMw;
  119. struct tyObject_XErrorEvent__KFlW9cH2fxpW1RXJX7y9caGQ;
  120. struct tyObject_XKeymapEvent__CrUb4iNeKC4ksLHETVzgRQ;
  121. struct tyObject_XGenericEvent__BMeayQYhmFza5aSAzlZ4qg;
  122. struct tyObject_XGenericEventCookie__oilhtNjFFwRywZzkahsLvQ;
  123. struct tyObject_StackTraceEntry__oLyohQ7O2XOvGnflOss8EA;
  124. typedef opencascade::handle<AIS_InteractiveContext> TY__U9azJ3jnkWQljuWXj5dG30g;
  125. typedef opencascade::handle<V3d_View> TY__icTQkUhVkd9cEc0gJ9c2VwPg;
  126. struct tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg : public AIS_ViewController {
  127. TY__U9azJ3jnkWQljuWXj5dG30g myContext;
  128. TY__icTQkUhVkd9cEc0gJ9c2VwPg myView;
  129. };
  130. struct tyTuple__mOcJMV5G9c4Xbhu28ljzjXA {
  131. TY__U9azJ3jnkWQljuWXj5dG30g Field0;
  132. TY__icTQkUhVkd9cEc0gJ9c2VwPg Field1;
  133. };
  134. typedef opencascade::handle<Aspect_DisplayConnection> TY__keu8dJZTmN1bTjmh2YTMeA;
  135. typedef opencascade::handle<OpenGl_GraphicDriver> TY__FZHdszn6vruH9aCoz9aCktYQ;
  136. typedef opencascade::handle<Graphic3d_GraphicDriver> TY__WzQHB9c9cwo6CTGferBwI78g;
  137. typedef opencascade::handle<V3d_Viewer> TY__47tV2K1aaSZXiNrxUNujaw;
  138. typedef opencascade::handle<Xw_Window> TY__LyS0CtE7Da8V9c3SncboSbA;
  139. typedef opencascade::handle<Aspect_Window> TY__yB86VfuSyzthqado7ziZgg;
  140. typedef NU8 tyEnum_TNimKind__jIBKr1ejBgsfM33Kxw4j7A;
  141. typedef NU8 tySet_tyEnum_TNimTypeFlag__v8QUszD1sWlSIWZz7mC4bQ;
  142. typedef N_NIMCALL_PTR(void, tyProc__ojoeKfW4VYIm36I9cpDTQIg) (void* p, NI op);
  143. typedef N_NIMCALL_PTR(void*, tyProc__WSm2xU5ARYv9aAR4l0z9c9auQ) (void* p);
  144. struct TNimType {
  145. NI size;
  146. NI align;
  147. tyEnum_TNimKind__jIBKr1ejBgsfM33Kxw4j7A kind;
  148. tySet_tyEnum_TNimTypeFlag__v8QUszD1sWlSIWZz7mC4bQ flags;
  149. TNimType* base;
  150. TNimNode* node;
  151. void* finalizer;
  152. tyProc__ojoeKfW4VYIm36I9cpDTQIg marker;
  153. tyProc__WSm2xU5ARYv9aAR4l0z9c9auQ deepcopy;
  154. };
  155. struct RootObj {
  156. TNimType* m_type;
  157. };
  158. struct TGenericSeq {
  159. NI len;
  160. NI reserved;
  161. };
  162. struct NimStringDesc : public TGenericSeq {
  163. NIM_CHAR data[SEQ_DECL_SIZE];
  164. };
  165. struct Exception : public RootObj {
  166. Exception* parent;
  167. NCSTRING name;
  168. NimStringDesc* message;
  169. tySequence__uB9b75OUPRENsBAu4AnoePA* trace;
  170. Exception* up;
  171. };
  172. struct tyObject_CatchableError__qrLSDoe2oBoAqNtJ9badtnA : public Exception {
  173. };
  174. struct tyObject_ValueError__yoNlBGx0D2tRizIdhQuENw : public tyObject_CatchableError__qrLSDoe2oBoAqNtJ9badtnA {
  175. };
  176. typedef NU8 tyEnum_TNimNodeKind__unfNsxrcATrufDZmpBq4HQ;
  177. struct TNimNode {
  178. tyEnum_TNimNodeKind__unfNsxrcATrufDZmpBq4HQ kind;
  179. NI offset;
  180. TNimType* typ;
  181. NCSTRING name;
  182. NI len;
  183. TNimNode** sons;
  184. };
  185. struct tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g {
  186. NI refcount;
  187. TNimType* typ;
  188. };
  189. struct tyObject_GcStack__7fytPA5bBsob6See21YMRA {
  190. void* bottom;
  191. };
  192. struct tyObject_CellSeq__Axo1XVm9aaQueTOldv8le5w {
  193. NI len;
  194. NI cap;
  195. tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g** d;
  196. };
  197. typedef tyObject_SmallChunk__tXn60W2f8h3jgAYdEmy5NQ* tyArray__SPr7N6UKfuF549bNPiUvSRw[256];
  198. typedef NU32 tyArray__BHbOSqU1t9b3Gt7K2c6fQig[24];
  199. typedef tyObject_BigChunk__Rv9c70Uhp2TytkX7eH78qEg* tyArray__N1u1nqOgmuJN9cSZrnMHgOQ[32];
  200. typedef tyArray__N1u1nqOgmuJN9cSZrnMHgOQ tyArray__B6durA4ZCi1xjJvRtyYxMg[24];
  201. typedef tyObject_Trunk__W0r8S0Y3UGke6T9bIUWnnuw* tyArray__lh2A89ahMmYg9bCmpVaplLbA[256];
  202. struct tyObject_IntSet__EZObFrE3NC9bIb3YMkY9crZA {
  203. tyArray__lh2A89ahMmYg9bCmpVaplLbA data;
  204. };
  205. typedef tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw* tyArray__0aOLqZchNi8nWtMTi8ND8w[2];
  206. struct tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw {
  207. tyArray__0aOLqZchNi8nWtMTi8ND8w link;
  208. NI key;
  209. NI upperBound;
  210. NI level;
  211. };
  212. struct tyTuple__ujsjpB2O9cjj3uDHsXbnSzg {
  213. tyObject_BigChunk__Rv9c70Uhp2TytkX7eH78qEg* Field0;
  214. NI Field1;
  215. };
  216. typedef tyTuple__ujsjpB2O9cjj3uDHsXbnSzg tyArray__LzOv2eCDGiceMKQstCLmhw[30];
  217. struct tyObject_HeapLinks__PDV1HBZ8CQSQJC9aOBFNRSg {
  218. NI len;
  219. tyArray__LzOv2eCDGiceMKQstCLmhw chunks;
  220. tyObject_HeapLinks__PDV1HBZ8CQSQJC9aOBFNRSg* next;
  221. };
  222. struct tyObject_MemRegion__x81NhDv59b8ercDZ9bi85jyg {
  223. NI minLargeObj;
  224. NI maxLargeObj;
  225. tyArray__SPr7N6UKfuF549bNPiUvSRw freeSmallChunks;
  226. NU32 flBitmap;
  227. tyArray__BHbOSqU1t9b3Gt7K2c6fQig slBitmap;
  228. tyArray__B6durA4ZCi1xjJvRtyYxMg matrix;
  229. tyObject_LLChunk__XsENErzHIZV9bhvyJx56wGw* llmem;
  230. NI currMem;
  231. NI maxMem;
  232. NI freeMem;
  233. NI occ;
  234. NI lastSize;
  235. tyObject_IntSet__EZObFrE3NC9bIb3YMkY9crZA chunkStarts;
  236. tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw* root;
  237. tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw* deleted;
  238. tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw* last;
  239. tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw* freeAvlNodes;
  240. NIM_BOOL locked;
  241. NIM_BOOL blockChunkSizeIncrease;
  242. NI nextChunkSize;
  243. tyObject_AvlNode__IaqjtwKhxLEpvDS9bct9blEw bottomData;
  244. tyObject_HeapLinks__PDV1HBZ8CQSQJC9aOBFNRSg heapLinks;
  245. };
  246. struct tyObject_GcStat__0RwLoVBHZPfUAcLczmfQAg {
  247. NI stackScans;
  248. NI cycleCollections;
  249. NI maxThreshold;
  250. NI maxStackSize;
  251. NI maxStackCells;
  252. NI cycleTableSize;
  253. NI64 maxPause;
  254. };
  255. struct tyObject_CellSet__jG87P0AI9aZtss9ccTYBIISQ {
  256. NI counter;
  257. NI max;
  258. tyObject_PageDesc__fublkgIY4LG3mT51LU2WHg* head;
  259. tyObject_PageDesc__fublkgIY4LG3mT51LU2WHg** data;
  260. };
  261. struct tyObject_GcHeap__1TRH1TZMaVZTnLNcIHuNFQ {
  262. tyObject_GcStack__7fytPA5bBsob6See21YMRA stack;
  263. NI cycleThreshold;
  264. NI zctThreshold;
  265. tyObject_CellSeq__Axo1XVm9aaQueTOldv8le5w zct;
  266. tyObject_CellSeq__Axo1XVm9aaQueTOldv8le5w decStack;
  267. tyObject_CellSeq__Axo1XVm9aaQueTOldv8le5w tempStack;
  268. NI recGcLock;
  269. tyObject_MemRegion__x81NhDv59b8ercDZ9bi85jyg region;
  270. tyObject_GcStat__0RwLoVBHZPfUAcLczmfQAg stat;
  271. tyObject_CellSet__jG87P0AI9aZtss9ccTYBIISQ marked;
  272. tyObject_CellSeq__Axo1XVm9aaQueTOldv8le5w additionalRoots;
  273. NI gcThreadId;
  274. };
  275. typedef opencascade::handle<AIS_Shape> TY__0sNjvi6cy22LOUKb6aOHyA;
  276. typedef opencascade::handle<AIS_InteractiveObject> TY__9cLINH5i7M3YCUgLs46CBaA;
  277. struct tyObject_XAnyEvent__1ezXFSdvNym3JpvCnlsENg {
  278. int theType;
  279. unsigned long serial;
  280. int send_event;
  281. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  282. unsigned long window;
  283. };
  284. struct tyObject_XKeyEvent__R59aUOCz38cH7kW8WZOY0fg {
  285. int theType;
  286. unsigned long serial;
  287. int send_event;
  288. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  289. unsigned long window;
  290. unsigned long root;
  291. unsigned long subwindow;
  292. unsigned long time;
  293. int x;
  294. int y;
  295. int x_root;
  296. int y_root;
  297. unsigned int state;
  298. unsigned int keycode;
  299. int same_screen;
  300. };
  301. struct tyObject_XButtonEvent__iRbydJb1sLXZm2LAsp2Y9cA {
  302. int theType;
  303. unsigned long serial;
  304. int send_event;
  305. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  306. unsigned long window;
  307. unsigned long root;
  308. unsigned long subwindow;
  309. unsigned long time;
  310. int x;
  311. int y;
  312. int x_root;
  313. int y_root;
  314. unsigned int state;
  315. unsigned int button;
  316. int same_screen;
  317. };
  318. struct tyObject_XMotionEvent__quIqNclnyTLRzhZ9baI9b4Mw {
  319. int theType;
  320. unsigned long serial;
  321. int send_event;
  322. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  323. unsigned long window;
  324. unsigned long root;
  325. unsigned long subwindow;
  326. unsigned long time;
  327. int x;
  328. int y;
  329. int x_root;
  330. int y_root;
  331. unsigned int state;
  332. char is_hint;
  333. int same_screen;
  334. };
  335. struct tyObject_XCrossingEvent__CwFNdmeikq1aI6Csp6M1TA {
  336. int theType;
  337. unsigned long serial;
  338. int send_event;
  339. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  340. unsigned long window;
  341. unsigned long root;
  342. unsigned long subwindow;
  343. unsigned long time;
  344. int x;
  345. int y;
  346. int x_root;
  347. int y_root;
  348. int mode;
  349. int detail;
  350. int same_screen;
  351. int focus;
  352. unsigned int state;
  353. };
  354. struct tyObject_XFocusChangeEvent__qWetk9cjWxGBS3eJVs3yD8g {
  355. int theType;
  356. unsigned long serial;
  357. int send_event;
  358. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  359. unsigned long window;
  360. int mode;
  361. int detail;
  362. };
  363. struct tyObject_XExposeEvent__GlotzqzjF0UF69cdWtF3UmA {
  364. int theType;
  365. unsigned long serial;
  366. int send_event;
  367. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  368. unsigned long window;
  369. int x;
  370. int y;
  371. int width;
  372. int height;
  373. int count;
  374. };
  375. struct tyObject_XGraphicsExposeEvent__vqoMwYGbpvggSS5CE7yfDg {
  376. int theType;
  377. unsigned long serial;
  378. int send_event;
  379. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  380. unsigned long drawable;
  381. int x;
  382. int y;
  383. int width;
  384. int height;
  385. int count;
  386. int major_code;
  387. int minor_code;
  388. };
  389. struct tyObject_XNoExposeEvent__OBeJnywKIxPbSlIDKzOCAw {
  390. int theType;
  391. unsigned long serial;
  392. int send_event;
  393. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  394. unsigned long drawable;
  395. int major_code;
  396. int minor_code;
  397. };
  398. struct tyObject_XVisibilityEvent__QIE8z6fsM14nzlNuZ4qx1g {
  399. int theType;
  400. unsigned long serial;
  401. int send_event;
  402. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  403. unsigned long window;
  404. int state;
  405. };
  406. struct tyObject_XCreateWindowEvent__gkTdbvHrseR8byhpmIGCOQ {
  407. int theType;
  408. unsigned long serial;
  409. int send_event;
  410. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  411. unsigned long parent;
  412. unsigned long window;
  413. int x;
  414. int y;
  415. int width;
  416. int height;
  417. int border_width;
  418. int override_redirect;
  419. };
  420. struct tyObject_XDestroyWindowEvent__Tp9aCI6GD3XFIuCb9bdElOuQ {
  421. int theType;
  422. unsigned long serial;
  423. int send_event;
  424. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  425. unsigned long event;
  426. unsigned long window;
  427. };
  428. struct tyObject_XUnmapEvent__dcLuf3f3TlbopgMrXs9bCGQ {
  429. int theType;
  430. unsigned long serial;
  431. int send_event;
  432. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  433. unsigned long event;
  434. unsigned long window;
  435. int from_configure;
  436. };
  437. struct tyObject_XMapEvent__RhdYUwfbWPzmyx2xTyV2FA {
  438. int theType;
  439. unsigned long serial;
  440. int send_event;
  441. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  442. unsigned long event;
  443. unsigned long window;
  444. int override_redirect;
  445. };
  446. struct tyObject_XMapRequestEvent__FaVNekhwNIncxldv52k8Lw {
  447. int theType;
  448. unsigned long serial;
  449. int send_event;
  450. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  451. unsigned long parent;
  452. unsigned long window;
  453. };
  454. struct tyObject_XReparentEvent__0ud6oL9auF2YpEcfxEUnWsw {
  455. int theType;
  456. unsigned long serial;
  457. int send_event;
  458. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  459. unsigned long event;
  460. unsigned long window;
  461. unsigned long parent;
  462. int x;
  463. int y;
  464. int override_redirect;
  465. };
  466. struct tyObject_XConfigureEvent__t9c9cC7EhkcyFJI9aMaDAboHA {
  467. int theType;
  468. unsigned long serial;
  469. int send_event;
  470. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  471. unsigned long event;
  472. unsigned long window;
  473. int x;
  474. int y;
  475. int width;
  476. int height;
  477. int border_width;
  478. unsigned long above;
  479. int override_redirect;
  480. };
  481. struct tyObject_XGravityEvent__i47ge3KLMlyylKb7nomPgQ {
  482. int theType;
  483. unsigned long serial;
  484. int send_event;
  485. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  486. unsigned long event;
  487. unsigned long window;
  488. int x;
  489. int y;
  490. };
  491. struct tyObject_XResizeRequestEvent__6P9c2mszwxUkchOWHCWX4pw {
  492. int theType;
  493. unsigned long serial;
  494. int send_event;
  495. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  496. unsigned long window;
  497. int width;
  498. int height;
  499. };
  500. struct tyObject_XConfigureRequestEvent__lqOXYk4ucPkV6vo82rcRfA {
  501. int theType;
  502. unsigned long serial;
  503. int send_event;
  504. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  505. unsigned long parent;
  506. unsigned long window;
  507. int x;
  508. int y;
  509. int width;
  510. int height;
  511. int border_width;
  512. unsigned long above;
  513. int detail;
  514. unsigned long value_mask;
  515. };
  516. struct tyObject_XCirculateEvent__PZ5EpxBAqiDQSX2toN9bNVQ {
  517. int theType;
  518. unsigned long serial;
  519. int send_event;
  520. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  521. unsigned long event;
  522. unsigned long window;
  523. int place;
  524. };
  525. struct tyObject_XCirculateRequestEvent__d1aa9cXr9a9bw8vIT3mxwrJoQ {
  526. int theType;
  527. unsigned long serial;
  528. int send_event;
  529. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  530. unsigned long parent;
  531. unsigned long window;
  532. int place;
  533. };
  534. struct tyObject_XPropertyEvent__8VLR5srdJmMgpN5n3xA9aYQ {
  535. int theType;
  536. unsigned long serial;
  537. int send_event;
  538. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  539. unsigned long window;
  540. unsigned long atom;
  541. unsigned long time;
  542. int state;
  543. };
  544. struct tyObject_XSelectionClearEvent__bln1Oj561KhuR8PFhQdugA {
  545. int theType;
  546. unsigned long serial;
  547. int send_event;
  548. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  549. unsigned long window;
  550. unsigned long selection;
  551. unsigned long time;
  552. };
  553. struct tyObject_XSelectionRequestEvent__FKYV6bvwXA2X0DguhHqR9ag {
  554. int theType;
  555. unsigned long serial;
  556. int send_event;
  557. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  558. unsigned long owner;
  559. unsigned long requestor;
  560. unsigned long selection;
  561. unsigned long target;
  562. unsigned long property;
  563. unsigned long time;
  564. };
  565. struct tyObject_XSelectionEvent__vVuKKVLJTVeC347zxsVdyg {
  566. int theType;
  567. unsigned long serial;
  568. int send_event;
  569. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  570. unsigned long requestor;
  571. unsigned long selection;
  572. unsigned long target;
  573. unsigned long property;
  574. unsigned long time;
  575. };
  576. struct tyObject_XColormapEvent__uqOhwoxMeCXt84TvPXgUgA {
  577. int theType;
  578. unsigned long serial;
  579. int send_event;
  580. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  581. unsigned long window;
  582. unsigned long colormap;
  583. int c_new;
  584. int state;
  585. };
  586. typedef char tyArray__nNbxUiwYsukKERsPpdjNlQ[20];
  587. typedef short tyArray__o84zoeJk2qehCRP3mCX84g[10];
  588. typedef long tyArray__xDUyu9aScDpt0JZLU6q9aEZQ[5];
  589. union tyObject_XClientMessageData__OKbi4O7vRg7iM9cNCZ0JrCA {
  590. tyArray__nNbxUiwYsukKERsPpdjNlQ b;
  591. tyArray__o84zoeJk2qehCRP3mCX84g s;
  592. tyArray__xDUyu9aScDpt0JZLU6q9aEZQ l;
  593. };
  594. struct tyObject_XClientMessageEvent__xo4p0BsKjqHQ1YGbKn8Gwg {
  595. int theType;
  596. unsigned long serial;
  597. int send_event;
  598. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  599. unsigned long window;
  600. unsigned long message_type;
  601. int format;
  602. tyObject_XClientMessageData__OKbi4O7vRg7iM9cNCZ0JrCA data;
  603. };
  604. struct tyObject_XMappingEvent__9boqTjTHll5ddMwGFM6CFMw {
  605. int theType;
  606. unsigned long serial;
  607. int send_event;
  608. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  609. unsigned long window;
  610. int request;
  611. int first_keycode;
  612. int count;
  613. };
  614. struct tyObject_XErrorEvent__KFlW9cH2fxpW1RXJX7y9caGQ {
  615. int theType;
  616. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  617. unsigned long resourceid;
  618. unsigned long serial;
  619. unsigned char error_code;
  620. unsigned char request_code;
  621. unsigned char minor_code;
  622. };
  623. typedef char tyArray__4aFG3pQPUlTEoAKtMVpzjw[32];
  624. struct tyObject_XKeymapEvent__CrUb4iNeKC4ksLHETVzgRQ {
  625. int theType;
  626. unsigned long serial;
  627. int send_event;
  628. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  629. unsigned long window;
  630. tyArray__4aFG3pQPUlTEoAKtMVpzjw key_vector;
  631. };
  632. struct tyObject_XGenericEvent__BMeayQYhmFza5aSAzlZ4qg {
  633. int theType;
  634. unsigned long serial;
  635. int send_event;
  636. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  637. int extension;
  638. int evtype;
  639. };
  640. struct tyObject_XGenericEventCookie__oilhtNjFFwRywZzkahsLvQ {
  641. int theType;
  642. unsigned long serial;
  643. int send_event;
  644. tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* display;
  645. int extension;
  646. int evtype;
  647. unsigned int cookie;
  648. void* data;
  649. };
  650. typedef long tyArray__Sdaj3sYaqpvcWUW4S9aIRBg[24];
  651. union tyObject_XEvent__EZvRvOUywFnBp4PzilZBoA {
  652. int theType;
  653. tyObject_XAnyEvent__1ezXFSdvNym3JpvCnlsENg xany;
  654. tyObject_XKeyEvent__R59aUOCz38cH7kW8WZOY0fg xkey;
  655. tyObject_XButtonEvent__iRbydJb1sLXZm2LAsp2Y9cA xbutton;
  656. tyObject_XMotionEvent__quIqNclnyTLRzhZ9baI9b4Mw xmotion;
  657. tyObject_XCrossingEvent__CwFNdmeikq1aI6Csp6M1TA xcrossing;
  658. tyObject_XFocusChangeEvent__qWetk9cjWxGBS3eJVs3yD8g xfocus;
  659. tyObject_XExposeEvent__GlotzqzjF0UF69cdWtF3UmA xexpose;
  660. tyObject_XGraphicsExposeEvent__vqoMwYGbpvggSS5CE7yfDg xgraphicsexpose;
  661. tyObject_XNoExposeEvent__OBeJnywKIxPbSlIDKzOCAw xnoexpose;
  662. tyObject_XVisibilityEvent__QIE8z6fsM14nzlNuZ4qx1g xvisibility;
  663. tyObject_XCreateWindowEvent__gkTdbvHrseR8byhpmIGCOQ xcreatewindow;
  664. tyObject_XDestroyWindowEvent__Tp9aCI6GD3XFIuCb9bdElOuQ xdestroywindow;
  665. tyObject_XUnmapEvent__dcLuf3f3TlbopgMrXs9bCGQ xunmap;
  666. tyObject_XMapEvent__RhdYUwfbWPzmyx2xTyV2FA xmap;
  667. tyObject_XMapRequestEvent__FaVNekhwNIncxldv52k8Lw xmaprequest;
  668. tyObject_XReparentEvent__0ud6oL9auF2YpEcfxEUnWsw xreparent;
  669. tyObject_XConfigureEvent__t9c9cC7EhkcyFJI9aMaDAboHA xconfigure;
  670. tyObject_XGravityEvent__i47ge3KLMlyylKb7nomPgQ xgravity;
  671. tyObject_XResizeRequestEvent__6P9c2mszwxUkchOWHCWX4pw xresizerequest;
  672. tyObject_XConfigureRequestEvent__lqOXYk4ucPkV6vo82rcRfA xconfigurerequest;
  673. tyObject_XCirculateEvent__PZ5EpxBAqiDQSX2toN9bNVQ xcirculate;
  674. tyObject_XCirculateRequestEvent__d1aa9cXr9a9bw8vIT3mxwrJoQ xcirculaterequest;
  675. tyObject_XPropertyEvent__8VLR5srdJmMgpN5n3xA9aYQ xproperty;
  676. tyObject_XSelectionClearEvent__bln1Oj561KhuR8PFhQdugA xselectionclear;
  677. tyObject_XSelectionRequestEvent__FKYV6bvwXA2X0DguhHqR9ag xselectionrequest;
  678. tyObject_XSelectionEvent__vVuKKVLJTVeC347zxsVdyg xselection;
  679. tyObject_XColormapEvent__uqOhwoxMeCXt84TvPXgUgA xcolormap;
  680. tyObject_XClientMessageEvent__xo4p0BsKjqHQ1YGbKn8Gwg xclient;
  681. tyObject_XMappingEvent__9boqTjTHll5ddMwGFM6CFMw xmapping;
  682. tyObject_XErrorEvent__KFlW9cH2fxpW1RXJX7y9caGQ xerror;
  683. tyObject_XKeymapEvent__CrUb4iNeKC4ksLHETVzgRQ xkeymap;
  684. tyObject_XGenericEvent__BMeayQYhmFza5aSAzlZ4qg xgeneric;
  685. tyObject_XGenericEventCookie__oilhtNjFFwRywZzkahsLvQ xcookie;
  686. tyArray__Sdaj3sYaqpvcWUW4S9aIRBg pad;
  687. };
  688. typedef N_CDECL_PTR(int, tyProc__Q0f6PP79abfOLb4bhA213Hw) (tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* para1, tyObject_XEvent__EZvRvOUywFnBp4PzilZBoA* para2);
  689. struct tyObject_StackTraceEntry__oLyohQ7O2XOvGnflOss8EA {
  690. NCSTRING procname;
  691. NI line;
  692. NCSTRING filename;
  693. };
  694. struct tySequence__uB9b75OUPRENsBAu4AnoePA : TGenericSeq {
  695.   tyObject_StackTraceEntry__oLyohQ7O2XOvGnflOss8EA data[SEQ_DECL_SIZE];
  696. };
  697. extern "C" N_LIB_PRIVATE N_NIMCALL(void, processExpose)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0);
  698. static N_INLINE(void, nimFrame)(TFrame* s);
  699. N_LIB_PRIVATE N_NOINLINE(void, callDepthLimitReached__system_2993)(void);
  700. static N_INLINE(void, popFrame)(void);
  701. extern "C" N_LIB_PRIVATE N_NIMCALL(void, processConfigure)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0, NIM_BOOL theIsResized);
  702. extern "C" N_LIB_PRIVATE N_NIMCALL(void, processInput)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0);
  703. extern "C" N_LIB_PRIVATE N_NIMCALL(void, processExpose__viewer4852_47)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0);
  704. N_LIB_PRIVATE N_NIMCALL(void, main__viewer4852_463)(void);
  705. static N_INLINE(void, nimZeroMem)(void* p, NI size);
  706. static N_INLINE(void, nimSetMem__systemZmemory_7)(void* a, int v, NI size);
  707. N_LIB_PRIVATE N_NIMCALL(tyTuple__mOcJMV5G9c4Xbhu28ljzjXA, getContextAndView__viewer4852_100)(void);
  708. N_LIB_PRIVATE N_NOINLINE(void*, newObj)(TNimType* typ, NI size);
  709. N_LIB_PRIVATE N_NIMCALL(NimStringDesc*, copyStringRC1)(NimStringDesc* src);
  710. static N_INLINE(void, nimGCunrefNoCycle)(void* p);
  711. static N_INLINE(void, decRef__system_5358)(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* c);
  712. static N_INLINE(NI, minuspercent___system_716)(NI x, NI y);
  713. static N_INLINE(NIM_BOOL, ltpercent___system_1005)(NI x, NI y);
  714. static N_INLINE(void, rtlAddZCT__system_5356)(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* c);
  715. N_LIB_PRIVATE N_NOINLINE(void, addZCT__system_5307)(tyObject_CellSeq__Axo1XVm9aaQueTOldv8le5w& s, tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* c);
  716. static N_INLINE(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g*, usrToCell__system_5313)(void* usr);
  717. static N_INLINE(void, asgnRef)(void** dest, void* src);
  718. static N_INLINE(void, incRef__system_5351)(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* c);
  719. static N_INLINE(NI, pluspercent___system_696)(NI x, NI y);
  720. N_LIB_PRIVATE N_NIMCALL(void, raiseExceptionEx)(Exception* e, NCSTRING ename, NCSTRING procname, NCSTRING filename, NI line);
  721. N_LIB_PRIVATE N_NIMCALL(TY__icTQkUhVkd9cEc0gJ9c2VwPg, view__viewer4852_20)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg* this_0);
  722. static N_INLINE(void, initStackBottomWith)(void* locals);
  723. N_LIB_PRIVATE N_NOINLINE(void, nimGC_setStackBottom)(void* theStackBottom);
  724. N_LIB_PRIVATE N_NIMCALL(void, systemDatInit000)(void);
  725. N_LIB_PRIVATE N_NIMCALL(void, systemInit000)(void);
  726. N_LIB_PRIVATE N_NIMCALL(void, x11_xlibDatInit000)(void);
  727. N_LIB_PRIVATE N_NIMCALL(void, NimMainModule)(void);
  728. extern TNimType NTIrefvalueerror__Ie1m0dv1ZHg72IgPRr1cDw_;
  729. extern TNimType NTIvalueerror__yoNlBGx0D2tRizIdhQuENw_;
  730. STRING_LITERAL(TM__wD429azSPMakedXQ1XuV5lw_2, "Can\'t export null shape to STEP", 31);
  731. extern TFrame* framePtr__system_2564;
  732. extern TFrame* framePtr__system_2564;
  733. extern TFrame* framePtr__system_2564;
  734. extern TFrame* framePtr__system_2564;
  735. extern TFrame* framePtr__system_2564;
  736. extern TFrame* framePtr__system_2564;
  737. extern tyObject_GcHeap__1TRH1TZMaVZTnLNcIHuNFQ gch__system_5260;
  738. extern tyProc__Q0f6PP79abfOLb4bhA213Hw Dl_30819748081_;
  739. static N_INLINE(void, nimFrame)(TFrame* s) {
  740.     {
  741.         if (!(framePtr__system_2564 == ((TFrame*) NIM_NIL))) goto LA3_;
  742. {       (*s).calldepth = ((NI16) 0);
  743. }   }
  744.     goto LA1_;
  745.     LA3_: ;
  746.     {
  747.         (*s).calldepth = (NI16)((*framePtr__system_2564).calldepth + ((NI16) 1));
  748.     }
  749.     LA1_: ;
  750.     (*s).prev = framePtr__system_2564;
  751.     framePtr__system_2564 = s;
  752.     {
  753.         if (!((*s).calldepth == ((NI16) 2000))) goto LA8_;
  754. {       callDepthLimitReached__system_2993();
  755. }   }
  756.     LA8_: ;
  757. }
  758. static N_INLINE(void, popFrame)(void) {
  759.     framePtr__system_2564 = (*framePtr__system_2564).prev;
  760. }
  761. N_LIB_PRIVATE N_NIMCALL(void, processExpose)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0) {
  762.     nimfr_("processExpose", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  763.     nimln_(24, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  764.     {
  765.         NIM_BOOL T3_ = this_0.myView.IsNull();
  766.         if (!!(T3_)) goto LA4_;
  767. {       nimln_(25, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  768.         this_0.FlushViewEvents(this_0.myContext, this_0.myView, NIM_TRUE);
  769. }   }
  770.     LA4_: ;
  771.     popFrame();
  772. }
  773. N_LIB_PRIVATE N_NIMCALL(void, processConfigure)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0, NIM_BOOL theIsResized) {
  774.     nimfr_("processConfigure", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  775.     nimln_(29, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  776.     {
  777.         NIM_BOOL T3_;
  778.         NIM_BOOL T4_;
  779.         T3_ = (NIM_BOOL)0;
  780.         T4_ = (NIM_BOOL)0;
  781.         T4_ = this_0.myView.IsNull();
  782.         T3_ = !(T4_);
  783.         if (!(T3_)) goto LA5_;
  784.         T3_ = theIsResized;
  785.         LA5_: ;
  786.         if (!T3_) goto LA6_;
  787. {       nimln_(30, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  788.         (void)((* (* this_0.myView).Window()).DoResize());
  789.         nimln_(31, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  790.         (* this_0.myView).MustBeResized();
  791.         nimln_(32, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  792.         (* this_0.myView).Invalidate();
  793.         nimln_(33, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  794.         this_0.FlushViewEvents(this_0.myContext, this_0.myView, NIM_TRUE);
  795. }   }
  796.     LA6_: ;
  797.     popFrame();
  798. }
  799. N_LIB_PRIVATE N_NIMCALL(void, processInput)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0) {
  800.     nimfr_("processInput", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  801.     nimln_(37, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  802.     {
  803.         NIM_BOOL T3_ = this_0.myView.IsNull();
  804.         if (!!(T3_)) goto LA4_;
  805. {       nimln_(38, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  806.         processExpose__viewer4852_47(this_0);
  807. }   }
  808.     LA4_: ;
  809.     popFrame();
  810. }
  811. static N_INLINE(void, nimSetMem__systemZmemory_7)(void* a, int v, NI size) {
  812.     void* T1_ = memset(a, v, ((size_t) (size)));
  813. }
  814. static N_INLINE(void, nimZeroMem)(void* p, NI size) {
  815.     nimSetMem__systemZmemory_7(p, ((int) 0), size);
  816. }
  817. static N_INLINE(NI, minuspercent___system_716)(NI x, NI y) {
  818.     NI result;
  819.     nimfr_("-%", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/arithmetics.nim");
  820.     result = (NI)0;
  821.     nimln_(414, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/arithmetics.nim");
  822.     nimln_(418, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/arithmetics.nim");
  823.     result = ((NI) ((NU)((NU64)(((NU) (x))) - (NU64)(((NU) (y))))));
  824.     popFrame();
  825.     return result;
  826. }
  827. static N_INLINE(NIM_BOOL, ltpercent___system_1005)(NI x, NI y) {
  828.     NIM_BOOL result;
  829.     nimfr_("<%", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/comparisons.nim");
  830.     result = (NIM_BOOL)0;
  831.     nimln_(186, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/comparisons.nim");
  832.     nimln_(188, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/comparisons.nim");
  833.     result = ((NU64)(((NU) (x))) < (NU64)(((NU) (y))));
  834.     popFrame();
  835.     return result;
  836. }
  837. static N_INLINE(void, rtlAddZCT__system_5356)(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* c) {
  838.     nimfr_("rtlAddZCT", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  839.     nimln_(243, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  840.     addZCT__system_5307(gch__system_5260.zct, c);
  841.     popFrame();
  842. }
  843. static N_INLINE(void, decRef__system_5358)(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* c) {
  844.     nimfr_("decRef", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  845.     nimln_(248, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  846.     (*c).refcount = minuspercent___system_716((*c).refcount, ((NI) 8));
  847.     nimln_(249, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  848.     {
  849.         NIM_BOOL T3_ = ltpercent___system_1005((*c).refcount, ((NI) 8));
  850.         if (!T3_) goto LA4_;
  851. {       nimln_(250, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  852.         rtlAddZCT__system_5356(c);
  853. }   }
  854.     LA4_: ;
  855.     popFrame();
  856. }
  857. static N_INLINE(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g*, usrToCell__system_5313)(void* usr) {
  858.     tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* result;
  859.     nimfr_("usrToCell", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  860.     result = (tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g*)0;
  861.     nimln_(177, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  862.     NI T1_ = minuspercent___system_716(((NI) (ptrdiff_t) (usr)), ((NI) 16));
  863.     result = ((tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g*) (T1_));
  864.     popFrame();
  865.     return result;
  866. }
  867. static N_INLINE(void, nimGCunrefNoCycle)(void* p) {
  868.     nimfr_("nimGCunrefNoCycle", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  869.     nimln_(276, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  870.     tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* T1_ = usrToCell__system_5313(p);
  871.     decRef__system_5358(T1_);
  872.     popFrame();
  873. }
  874. static N_INLINE(NI, pluspercent___system_696)(NI x, NI y) {
  875.     NI result;
  876.     nimfr_("+%", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/arithmetics.nim");
  877.     result = (NI)0;
  878.     nimln_(403, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/arithmetics.nim");
  879.     nimln_(407, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/arithmetics.nim");
  880.     result = ((NI) ((NU)((NU64)(((NU) (x))) + (NU64)(((NU) (y))))));
  881.     popFrame();
  882.     return result;
  883. }
  884. static N_INLINE(void, incRef__system_5351)(tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* c) {
  885.     nimfr_("incRef", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  886.     nimln_(231, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  887.     (*c).refcount = pluspercent___system_696((*c).refcount, ((NI) 8));
  888.     popFrame();
  889. }
  890. static N_INLINE(void, asgnRef)(void** dest, void* src) {
  891.     nimfr_("asgnRef", "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  892.     nimln_(286, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  893.     {
  894.         if (!!((src == NIM_NIL))) goto LA3_;
  895. {       tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* T5_ = usrToCell__system_5313(src);
  896.         incRef__system_5351(T5_);
  897. }   }
  898.     LA3_: ;
  899.     nimln_(287, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  900.     {
  901.         if (!!(((*dest) == NIM_NIL))) goto LA8_;
  902. {       tyObject_Cell__1zcF9cV8XIAtbN8h5HRUB8g* T10_ = usrToCell__system_5313((*dest));
  903.         decRef__system_5358(T10_);
  904. }   }
  905.     LA8_: ;
  906.     nimln_(288, "/home/jose/.choosenim/toolchains/nim-1.6.6/lib/system/gc.nim");
  907.     (*dest) = src;
  908.     popFrame();
  909. }
  910. N_LIB_PRIVATE N_NIMCALL(tyTuple__mOcJMV5G9c4Xbhu28ljzjXA, getContextAndView__viewer4852_100)(void) {
  911.     tyTuple__mOcJMV5G9c4Xbhu28ljzjXA result;
  912.     nimfr_("getContextAndView", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  913. {   nimZeroMem((void*)(&result), sizeof(tyTuple__mOcJMV5G9c4Xbhu28ljzjXA));
  914.     nimln_(46, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  915.     TY__keu8dJZTmN1bTjmh2YTMeA aDisplay((new Aspect_DisplayConnection()));
  916.     nimln_(47, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  917.     TY__FZHdszn6vruH9aCoz9aCktYQ aDriverOpenGl((new OpenGl_GraphicDriver(aDisplay, NIM_TRUE)));
  918.     nimln_(48, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  919.     OpenGl_GraphicDriver* T1_ = aDriverOpenGl.get();
  920.     TY__WzQHB9c9cwo6CTGferBwI78g aDriver(((Graphic3d_GraphicDriver*) (T1_)));
  921.     nimln_(53, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  922.     TY__47tV2K1aaSZXiNrxUNujaw aViewer((new V3d_Viewer(aDriver)));
  923.     nimln_(54, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  924.     (* aViewer).SetDefaultLights();
  925.     nimln_(55, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  926.     (* aViewer).SetLightOn();
  927.     nimln_(58, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  928.     TY__icTQkUhVkd9cEc0gJ9c2VwPg myView((new V3d_View(aViewer, ((V3d_TypeOfView) 0))));
  929.     nimln_(59, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  930.     TY__LyS0CtE7Da8V9c3SncboSbA aWindow((new Xw_Window(aDisplay, "OCCT Viewer", ((int) 100), ((int) 100), ((int) 512), ((int) 512))));
  931.     nimln_(60, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  932.     Xw_Window* T2_ = aWindow.get();
  933.     TY__yB86VfuSyzthqado7ziZgg aWinAspect(((Aspect_Window*) (T2_)));
  934.     nimln_(62, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  935.     (* myView).SetWindow(aWinAspect, ((tyObject_NSOpenGLContext__cXoy3V9c0amLPn8ieCuKwyA*) NIM_NIL));
  936.     nimln_(63, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  937.     (* myView).SetBackgroundColor(Quantity_Color(((Quantity_NameOfColor) 182)));
  938.     nimln_(64, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  939.     (* myView).TriedronDisplay(((Aspect_TypeOfTriedronPosition) 6), Quantity_Color(((Quantity_NameOfColor) 508)), 0.1f, ((V3d_TypeOfVisualization) 0));
  940.     nimln_(65, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  941.     (* myView).ChangeRenderingParams().RenderResolutionScale = 2.0f;
  942.     nimln_(68, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  943.     TY__U9azJ3jnkWQljuWXj5dG30g myContext((new AIS_InteractiveContext(aViewer)));
  944.     nimln_(71, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  945.     BRepPrimAPI_MakeBox mybox(1.0f, 2.0f, 3.0f);
  946.     nimln_(72, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  947.     mybox.Build();
  948.     nimln_(73, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  949.     TopoDS_Solid solid = mybox.Solid();
  950.     nimln_(74, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  951.     {
  952.         tyObject_ValueError__yoNlBGx0D2tRizIdhQuENw* T7_;
  953.         NimStringDesc* T8_;
  954.         if (!solid.IsNull()) goto LA5_;
  955. {       T7_ = NIM_NIL;
  956.         T7_ = (tyObject_ValueError__yoNlBGx0D2tRizIdhQuENw*) newObj((&NTIrefvalueerror__Ie1m0dv1ZHg72IgPRr1cDw_), sizeof(tyObject_ValueError__yoNlBGx0D2tRizIdhQuENw));
  957.         (*T7_).m_type = (&NTIvalueerror__yoNlBGx0D2tRizIdhQuENw_);
  958.         (*T7_).name = "ValueError";
  959.         T8_ = NIM_NIL;
  960.         T8_ = (*T7_).message; (*T7_).message = copyStringRC1(((NimStringDesc*) &TM__wD429azSPMakedXQ1XuV5lw_2));
  961.         if (T8_) nimGCunrefNoCycle(T8_);
  962.         asgnRef((void**) (&(*T7_).parent), ((Exception*) NIM_NIL));
  963.         nimln_(75, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  964.         raiseExceptionEx((Exception*)T7_, "ValueError", "getContextAndView", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim", 75);
  965. }   }
  966.     LA5_: ;
  967.     nimln_(77, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  968.     TopoDS_Shape aShape = solid;
  969.     nimln_(78, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  970.     TY__0sNjvi6cy22LOUKb6aOHyA aShapeAis((new AIS_Shape(aShape)));
  971.     nimln_(79, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  972.     AIS_Shape* T9_ = aShapeAis.get();
  973.     TY__9cLINH5i7M3YCUgLs46CBaA aShapePrs(((AIS_InteractiveObject*) (T9_)));
  974.     nimln_(80, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  975.     (* myContext).Display(aShapeAis, ((int) 1), ((int) 0), NIM_FALSE, ((AIS_DisplayStatus) 2));
  976.     nimln_(81, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  977.     (* myView).FitAll(0.01f, NIM_FALSE);
  978.     nimln_(83, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  979.     (* aWindow).Map();
  980.     nimln_(84, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  981.     (* myView).Redraw();
  982.     nimln_(85, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  983.     TY__U9azJ3jnkWQljuWXj5dG30g colontmp_ = myContext;
  984.     TY__icTQkUhVkd9cEc0gJ9c2VwPg colontmp__2 = myView;
  985.     result.Field0 = colontmp_;
  986.     result.Field1 = colontmp__2;
  987.     goto BeforeRet_;
  988.     }BeforeRet_: ;
  989.     popFrame();
  990.     return result;
  991. }
  992. N_LIB_PRIVATE N_NIMCALL(TY__icTQkUhVkd9cEc0gJ9c2VwPg, view__viewer4852_20)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg* this_0) {
  993.     TY__icTQkUhVkd9cEc0gJ9c2VwPg result;
  994.     nimfr_("view", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  995. {   nimln_(19, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  996.     result = (*this_0).myView;
  997.     goto BeforeRet_;
  998.     }BeforeRet_: ;
  999.     popFrame();
  1000.     return result;
  1001. }
  1002. N_LIB_PRIVATE N_NIMCALL(void, main__viewer4852_463)(void) {
  1003.     tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg aViewer;
  1004.     tyObject_XEvent__EZvRvOUywFnBp4PzilZBoA event;
  1005.     nimfr_("main", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1006.     nimZeroMem((void*)(&aViewer), sizeof(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg));
  1007.     nimln_(94, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1008.     tyTuple__mOcJMV5G9c4Xbhu28ljzjXA T1_ = getContextAndView__viewer4852_100();
  1009.     tyTuple__mOcJMV5G9c4Xbhu28ljzjXA _ = T1_;
  1010.     aViewer.myContext = _.Field0;
  1011.     aViewer.myView = _.Field1;
  1012.     nimln_(96, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1013.     TY__icTQkUhVkd9cEc0gJ9c2VwPg T2_ = view__viewer4852_20((&aViewer));
  1014.     Aspect_Window* T3_ = (* T2_).Window().get();
  1015.     TY__LyS0CtE7Da8V9c3SncboSbA aWindow(((Xw_Window*) (T3_)));
  1016.     nimln_(97, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1017.     TY__icTQkUhVkd9cEc0gJ9c2VwPg T4_ = view__viewer4852_20((&aViewer));
  1018.     TY__keu8dJZTmN1bTjmh2YTMeA aDispConn = (* (* (* T4_).Viewer()).Driver()).GetDisplayConnection();
  1019.     nimln_(98, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1020.     Aspect_XDisplay* display = (* aDispConn).GetDisplayAspect();
  1021.     nimZeroMem((void*)(&event), sizeof(tyObject_XEvent__EZvRvOUywFnBp4PzilZBoA));
  1022.     nimln_(101, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1023.     tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q* anDisplay = ((tyObject_XDisplay__pUEYXk7cKlFR9bAMzuMcK1Q*) (display));
  1024.     {
  1025.         nimln_(102, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1026.         while (1) {
  1027.             nimln_(103, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1028.             int T7_ = Dl_30819748081_(anDisplay, (&event));
  1029.             (void)(T7_);
  1030.             nimln_(104, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1031.             (void)((* aWindow).ProcessMessage((Aspect_WindowInputListener &) aViewer, (XEvent &) event));
  1032.         }
  1033.     }
  1034.     popFrame();
  1035. }
  1036. static N_INLINE(void, initStackBottomWith)(void* locals) {
  1037.     nimGC_setStackBottom(locals);
  1038. }
  1039. N_LIB_PRIVATE N_NIMCALL(void, processExpose__viewer4852_47)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0) {
  1040.     nimfr_("processExpose", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1041.     nimln_(23, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1042.     processExpose(this_0);
  1043.     popFrame();
  1044. }
  1045. N_LIB_PRIVATE N_NIMCALL(void, processConfigure__viewer4852_93)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0, NIM_BOOL theIsResized) {
  1046.     nimfr_("processConfigure", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1047.     nimln_(28, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1048.     processConfigure(this_0, theIsResized);
  1049.     popFrame();
  1050. }
  1051. N_LIB_PRIVATE N_NIMCALL(void, processInput__viewer4852_99)(tyObject_OcctAisHello__4FfLiMkIhaAMoZFVAV19cSg& this_0) {
  1052.     nimfr_("processInput", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1053.     nimln_(36, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1054.     processInput(this_0);
  1055.     popFrame();
  1056. }
  1057.  
  1058. N_LIB_PRIVATE void PreMainInner(void) {
  1059. }
  1060.  
  1061. N_LIB_PRIVATE int cmdCount;
  1062. N_LIB_PRIVATE char** cmdLine;
  1063. N_LIB_PRIVATE char** gEnv;
  1064. N_LIB_PRIVATE void PreMain(void) {
  1065.     void (*volatile inner)(void);
  1066.     inner = PreMainInner;
  1067.     systemDatInit000();
  1068.     initStackBottomWith((void *)&inner);
  1069.     systemInit000();
  1070.     x11_xlibDatInit000();
  1071.     (*inner)();
  1072. }
  1073.  
  1074. N_LIB_PRIVATE N_CDECL(void, NimMainInner)(void) {
  1075.     NimMainModule();
  1076. }
  1077.  
  1078. N_CDECL(void, NimMain)(void) {
  1079.     void (*volatile inner)(void);
  1080.     PreMain();
  1081.     inner = NimMainInner;
  1082.     initStackBottomWith((void *)&inner);
  1083.     (*inner)();
  1084. }
  1085.  
  1086. int main(int argc, char** args, char** env) {
  1087.     cmdLine = args;
  1088.     cmdCount = argc;
  1089.     gEnv = env;
  1090.     NimMain();
  1091.     return nim_program_result;
  1092. }
  1093.  
  1094. N_LIB_PRIVATE N_NIMCALL(void, NimMainModule)(void) {
  1095. {
  1096.     nimfr_("viewer04", "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1097.     nimln_(108, "/home/jose/src/nimlang/occt.nim/examples/viewer04.nim");
  1098.     main__viewer4852_463();
  1099.     popFrame();
  1100. }
  1101. }
  1102.  
  1103.  
Add Comment
Please, Sign In to add comment