home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 136.lha / AirFoil / airfoilx.h < prev    next >
C/C++ Source or Header  |  1986-11-20  |  19KB  |  501 lines

  1. /********************************************************************
  2. *                                                                   *
  3. * Joukowski Airfoil Generator with Streamlines and Pressure         *
  4. * Distribution Algorithm                                            *
  5. *                                                                   *
  6. * Written by:   Russell Leighton      15 March 1987                 *
  7. *               Lancaster, CA                                       *
  8. *                                                                   *
  9. * Expansion memory fixes by Fred Wright, 1 Jun 1987                 *
  10. *                                                                   *
  11. ********************************************************************/
  12.  
  13. /* FW - pruned unnecessary includes */
  14. #include <exec/types.h>
  15. /* #include <exec/nodes.h>      */
  16. /* #include <exec/lists.h>      */
  17. /* #include <exec/ports.h>      */
  18. /* #include <exec/devices.h>    */
  19. /* #include <devices/keymap.h>  */
  20. /* #include <graphics/regions.h> */
  21. /* #include <graphics/copper.h> */
  22. /* #include <graphics/gels.h>   */
  23. #include <graphics/gfxbase.h>
  24. #include <graphics/gfxmacros.h>
  25. /* #include <graphics/gfx.h>    */
  26. /* #include <graphics/clip.h>   */
  27. #include <graphics/view.h>
  28. #include <graphics/rastport.h>
  29. /* #include <graphics/layers.h> */
  30. #include <intuition/intuition.h>
  31. /* #include <hardware/blit.h>   */
  32. #include <math.h>
  33. #include <libraries/mathffp.h>
  34.  
  35. #include <exec/memory.h>        /* FW - for MEMF_CHIP */
  36.  
  37. #undef NULL
  38. #define NULL  ((void *)0)
  39. #define XMIN  0
  40. #define YMIN  0
  41. #define XMAX  639
  42. #define YMAX  399
  43. #define XCEN  320
  44. #define YCEN  210
  45. #define SFAC  100
  46. #define TOL   1.0e-8
  47. #define PENUP    (PEN = 0)
  48. #define PENDOWN  (PEN = 1)
  49.  
  50. unsigned int mask = 0;             /* one bit set for each open */
  51.  
  52. #define INTUITION  0x0001
  53. #define GRAPHICS   0x0002
  54. #define SCREEN     0x0004
  55. #define WINDOW     0x0008
  56. #define AREAFILL   0x0010
  57. #define DMREQUEST  0x0020
  58.  
  59. struct IntuitionBase *IntuitionBase;
  60. struct GfxBase *GfxBase;
  61. struct IntuiMessage *message;
  62. struct Message *GetMsg();
  63. struct ViewPort *vp;
  64. struct RastPort *rp;
  65. struct Screen *s;
  66. struct Window *w;
  67. struct Requester AirRequest;
  68. struct TmpRas trp;
  69. struct AreaInfo area;
  70.  
  71. WORD buffer[625];
  72. ULONG camber = 4,thickness = 6,angle = 0,velocity = 8;
  73. float a,b,c,t,r,alpha;
  74. int PEN,FILL,Continue = TRUE,mode = TRUE,title = FALSE;
  75. long ixo,iyo;
  76.  
  77. char *about[] = {
  78. "        Airfoil Generator Utilizing the Joukowski Transformation",
  79. " ",
  80. "        Written by:  Russell Leighton",
  81. "                     Lancaster, CA",
  82. "                     March 1987",
  83. " ",
  84. "        To use this program bring up the requester by double clicking",
  85. "        the right mouse button (the menu button).  This requester can be",
  86. "        brought up at any time (even during plotting) by double clicking",
  87. "        the right mouse button.  The requester gadgets are located and",
  88. "        described as follows.",
  89. " ",
  90. "        Gadget     Location                Description",
  91. "        ------     --------                -----------",
  92. " ",
  93. "        Quit       Upper left corner       Exits from program",
  94. "        Close      Upper right corner      Starts or continues plot",
  95. "        ShowTitle  Upper center            Toggles screen title bar",
  96. "        Airfoil    Below ShowTitle gadget  Toggles streamline/pressure plot",
  97. "        Camber     Below Airfoil gadget    Mid-chord camber entry",
  98. "        Thickness  Below Camber gadget     Mid-chord thickness entry",
  99. "        Angle      Below Thickness gadget  Angle of attack entry",
  100. "        Velocity   Bottom edge             Slider for velocity entry",
  101. " "
  102. };
  103.  
  104. UWORD colors[] = {
  105. 0x046, 0x000, 0xC00, 0xC60,
  106. 0xC90, 0xCC0, 0x0C0, 0x0C7,
  107. 0x0CC, 0x09C, 0x06C, 0x00C,
  108. 0x009, 0x006, 0x000, 0xCCC
  109. };
  110.  
  111. struct ImageMem {    /* FW - make all this data a structure */
  112. UWORD closeimage[10*2];
  113. UWORD streamimage[11*4*3];
  114. UWORD pressureimage[11*4*3];
  115. } gadgimgs = {
  116.  
  117. /* closeimage */ {
  118. /* plane 0 */
  119. 0x3FFF, 0xFC00,
  120. 0x3000, 0x0C00,
  121. 0x33FF, 0xCC00,
  122. 0x33FF, 0xCC00,
  123. 0x33C3, 0xCC00,
  124. 0x33C3, 0xCC00,
  125. 0x33FF, 0xCC00,
  126. 0x33FF, 0xCC00,
  127. 0x3000, 0x0C00,
  128. 0x3FFF, 0xFC00
  129. },
  130.  
  131. /* streamimage */ {
  132. /* plane 0 */
  133. 0x0000, 0x0000, 0x0000, 0x0000,
  134. 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
  135. 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
  136. 0xFFFF, 0xFFFF, 0xFFF0, 0x000F,
  137. 0xFC00, 0xFFE1, 0x003F, 0xFFFC,
  138. 0x03FF, 0xFFFE, 0x7FFF, 0xFFFE,
  139. 0x0000, 0xFFFC, 0x0000, 0x0000,
  140. 0xFFFE, 0x0003, 0xFFFF, 0xFFFF,
  141. 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
  142. 0xFFFF, 0xFFFF, 0xFFFF, 0xFFFF,
  143. 0xFFFF, 0xFFFF, 0x0000, 0x0000,
  144. /* plane 1 */
  145. 0x0000, 0x0000, 0x0000, 0x0000,
  146. 0x0000, 0x0000, 0x0000, 0x0000,
  147. 0x0000, 0x0000, 0x00FF, 0xFFF8,
  148. 0xFFF0, 0x000F, 0xFC0F, 0xFFF1,
  149. 0x03FF, 0x001E, 0xFFC0, 0x0003,
  150. 0xFC00, 0x0001, 0x8000, 0x0001,
  151. 0xFFFF, 0x0003, 0xFFFF, 0xFFFF,
  152. 0x0001, 0xFFFC, 0xFFFE, 0x0003,
  153. 0xFFFF, 0xFFFF, 0x0000, 0x01FE,
  154. 0x0000, 0x0000, 0x0000, 0x0000,
  155. 0x0000, 0x0000, 0x0000, 0x0000,
  156. /* plane 2 */
  157. 0x0000, 0x0000, 0x0000, 0x0000,
  158. 0x0000, 0x0000, 0xFFFF, 0xFFFF,
  159. 0xFF00, 0x0007, 0x00FF, 0xFFF8,
  160. 0xFFF0, 0x000F, 0xFC00, 0x0001,
  161. 0x0000, 0x0000, 0x0000, 0x0000,
  162. 0x0000, 0x0000, 0x0000, 0x0000,
  163. 0x0000, 0x0000, 0x0000, 0x0000,
  164. 0x0000, 0x0000, 0xFFFE, 0x0003,
  165. 0xFFFF, 0xFFFF, 0x0000, 0x01FE,
  166. 0xFFFF, 0xFE01, 0xFFFF, 0xFFFF,
  167. 0x0000, 0x0000, 0x0000, 0x0000
  168. },
  169.  
  170. /* pressureimage */ {
  171. /* plane 0 */
  172. 0x0000, 0xFF80, 0x0007, 0x0060,
  173. 0x0038, 0x0010, 0x00C0, 0x0008,
  174. 0x0100, 0x0004, 0x0200, 0x0002,
  175. 0x0400, 0x0002, 0x0800, 0x0001,
  176. 0x1000, 0xFFE1, 0x203F, 0xFFFD,
  177. 0x43FF, 0xFFFE, 0x7FFF, 0xFFFE,
  178. 0x4000, 0xFFFD, 0x2000, 0x0001,
  179. 0x1000, 0x0002, 0x0C00, 0x0004,
  180. 0x0380, 0x0008, 0x0070, 0x0030,
  181. 0x000F, 0x00C0, 0x0000, 0xFF00,
  182. 0x0000, 0x0000, 0x0000, 0x0000,
  183. /* plane 1 */
  184. 0x0000, 0x0000, 0x0000, 0xFF80,
  185. 0x0007, 0xFFE0, 0x003F, 0xFFF0,
  186. 0x00FF, 0xFFF8, 0x01FF, 0xFFFC,
  187. 0x03FF, 0xFFFC, 0x07FF, 0xFFFE,
  188. 0x0FFF, 0x001E, 0x1FC0, 0x0002,
  189. 0x3C00, 0x0000, 0x0000, 0x0000,
  190. 0x3FFF, 0x0002, 0x1FFF, 0xFFFE,
  191. 0x0FFF, 0xFFFC, 0x03FF, 0xFFF8,
  192. 0x007F, 0xFFF0, 0x000F, 0xFFC0,
  193. 0x0000, 0xFF00, 0x0000, 0x0000,
  194. 0x0000, 0x0000, 0x0000, 0x0000
  195. }
  196.  
  197. };         /* FW - end of gadget imagery */
  198.  
  199. struct ImageMem * ChipImg = NULL;    /* FW - pointer to chip mem for copy */
  200. #define CHIP_IMG_SIZ  ( (long) sizeof(struct ImageMem) ) /* FW how big */
  201.  
  202. SHORT title_xy[] = {
  203.      0,   0,
  204.    151,   0,
  205.    151,  10,
  206.      0,  10,
  207.      0,   0
  208. };
  209.  
  210. struct Border title_border = {
  211.    0L, 0L,                      /* LeftEdge, TopEdge */
  212.    1L, 1L, JAM1,                /* FrontPen, BackPen, DrawMode */
  213.    5L,                          /* Count (no. of vertices) */
  214.    &title_xy[0],                /* Pointer to coordinates */
  215.    NULL                         /* No NextBorder */
  216. };
  217.  
  218. struct Image quit_image = {
  219.    0L, 0L,                      /* LeftEdge, TopEdge */
  220.    24L, 10L, 1L,                /* Width, Height, Depth */
  221.    &gadgimgs.closeimage[0],     /* Pointer to bit image (FW will change) */
  222.    0x2, 0x0,                    /* PlanePick, PlaneOnOff */
  223.    NULL                         /* No other images */
  224. };
  225.  
  226. struct Image close_image = {
  227.    0L, 0L,                      /* LeftEdge, TopEdge */
  228.    24L, 10L, 1L,                /* Width, Height, Depth */
  229.    &gadgimgs.closeimage[0],     /* Pointer to bit image (FW will change) */
  230.    0x1, 0x0,                    /* PlanePick, PlaneOnOff */
  231.    NULL                         /* No other images */
  232. };
  233.  
  234. struct Image stream_image = {
  235.    0L, 0L,                      /* LeftEdge, TopEdge */
  236.    32L, 22L, 3L,                /* Width, Height, Depth */
  237.    &gadgimgs.streamimage[0],    /* Pointer to bit image (FW will change) */
  238.    0xD, 0x0,                    /* PlanePick, PlaneOnOff */
  239.    NULL                         /* No other images */
  240. };
  241.  
  242. struct Image pressure_image = {
  243.    0L, 0L,                      /* LeftEdge, TopEdge */
  244.    32L, 22L, 2L,                /* Width, Height, Depth */
  245.    &gadgimgs.pressureimage[0],  /* Pointer to bit image (FW will change) */
  246.    0x3, 0x0,                    /* PlanePick, PlaneOnOff */
  247.    NULL                         /* No other images */
  248. };
  249.  
  250. struct Image prop_image;
  251.  
  252. struct IntuiText camber_text = {1L,1L,JAM1,2L,-11L,NULL,
  253.    (UBYTE *)"Camber (% of chord):",NULL};
  254.  
  255. struct IntuiText thick_text = {1L,1L,JAM1,2L,-11L,NULL,
  256.    (UBYTE *)"Thickness (% of chord):",NULL};
  257.  
  258. struct IntuiText angle_text = {1L,1L,JAM1,2L,-11L,NULL,
  259.    (UBYTE *)"Angle of attack (deg):",NULL};
  260.  
  261. struct IntuiText velocity_text = {1L,1L,JAM1,2L,-11L,NULL,
  262.    (UBYTE *)"+       Velocity       -",NULL};
  263.  
  264. #define BUFSIZE 16
  265. UBYTE CambBuf[BUFSIZE] = "4";
  266. UBYTE ThicBuf[BUFSIZE] = "6";
  267. UBYTE AnglBuf[BUFSIZE] = "0";
  268. UBYTE UndoBuf[BUFSIZE];
  269.  
  270. struct StringInfo camber_string = {
  271.    CambBuf,                     /* Buffer */
  272.    UndoBuf,                     /* UndoBuffer */
  273.    0L,                          /* BufferPos */
  274.    BUFSIZE,                     /* MaxChars */
  275.    0L,0L,                       /* DispPos, UndoPos */
  276.    8L,                          /* NumChars */
  277.    0L,0L,0L,                    /* Posn Vars calc by intuition */
  278.    NULL,                        /* No pointer to layer */
  279.    0L,                          /* Longint value returned */
  280.    NULL                         /* No AltKeyMap */
  281. };
  282.  
  283. struct StringInfo thick_string = {
  284.    ThicBuf,                     /* Buffer */
  285.    UndoBuf,                     /* UndoBuffer */
  286.    0L,                          /* BufferPos */
  287.    BUFSIZE,                     /* MaxChars */
  288.    0L,0L,                       /* DispPos, UndoPos */
  289.    8L,                          /* NumChars */
  290.    0L,0L,0L,                    /* Posn Vars calc by intuition */
  291.    NULL,                        /* No pointer to layer */
  292.    0L,                          /* Longint value returned */
  293.    NULL                         /* No AltKeyMap */
  294. };
  295.  
  296. struct StringInfo angle_string = {
  297.    AnglBuf,                     /* Buffer */
  298.    UndoBuf,                     /* UndoBuffer */
  299.    0L,                          /* BufferPos */
  300.    BUFSIZE,                     /* MaxChars */
  301.    0L,0L,                       /* DispPos, UndoPos */
  302.    8L,                          /* NumChars */
  303.    0L,0L,0L,                    /* Posn Vars calc by intuition */
  304.    NULL,                        /* No pointer to layer */
  305.    0L,                          /* Longint value returned */
  306.    NULL                         /* No AltKeyMap */
  307. };
  308.  
  309. struct PropInfo velocity_prop = {
  310.    AUTOKNOB |                   /* Select auto-knob gadget */
  311.    FREEHORIZ,                   /* Knob can move horizontal */
  312.    0x7FFF, 0x0000,              /* Initially knob is at center */
  313.    0x0800, 0x0000,              /* HorizBody, VertBody */
  314.    200L,11L,                    /* CWidth, CHeight */
  315.    1L,1L,                       /* HPotRes, VPotRes */
  316.    0L,0L                        /* LeftBorder, TopBorder */
  317. };
  318.  
  319. #define CAMBER_GAD 0
  320. struct Gadget camber_gad = {
  321.    NULL,                        /* First gadget */
  322.    10L,50L,100L,11L,            /* LeftEdge, TopEdge, Width, Height */
  323.    GADGHCOMP,                   /* Complement image for select */
  324.    LONGINT |                    /* This is an integer gadget */
  325.    RELVERIFY,                   /* Release verify */
  326.    STRGADGET |                  /* This is a string gadget */
  327.    REQGADGET,                   /* This is a requester gadget */
  328.    NULL,                        /* No gadget image */
  329.    NULL,                        /* No selected image */
  330.    &camber_text,                /* GadgetText */
  331.    0,                           /* No mutual exclusion */
  332.    (APTR)&camber_string,        /* SpecialInfo */
  333.    CAMBER_GAD,                  /* Gadget id */
  334.    NULL                         /* No user data */
  335. };
  336.  
  337. #define THICK_GAD 1
  338. struct Gadget thick_gad = {
  339.    &camber_gad,                 /* NextGadget */
  340.    10L,80L,100L,11L,            /* LeftEdge, TopEdge, Width, Height */
  341.    GADGHCOMP,                   /* Complement image for select */
  342.    LONGINT |                    /* This is an integer gadget */
  343.    RELVERIFY,                   /* Release verify */
  344.    STRGADGET |                  /* This is a string gadget */
  345.    REQGADGET,                   /* This is a requester gadget */
  346.    NULL,                        /* No gadget image */
  347.    NULL,                        /* No selected image */
  348.    &thick_text,                 /* GadgetText */
  349.    0,                           /* No mutual exclusion */
  350.    (APTR)&thick_string,         /* SpecialInfo */
  351.    THICK_GAD,                   /* Gadget id */
  352.    NULL                         /* No user data */
  353. };
  354.  
  355. #define ANGLE_GAD 2
  356. struct Gadget angle_gad = {
  357.    &thick_gad,                  /* NextGadget */
  358.    10L,110L,100L,11L,           /* LeftEdge, TopEdge, Width, Height */
  359.    GADGHCOMP,                   /* Complement image for select */
  360.    LONGINT |                    /* This is an integer gadget */
  361.    RELVERIFY,                   /* Release verify */
  362.    STRGADGET |                  /* This is a string gadget */
  363.    REQGADGET,                   /* This is a requester gadget */
  364.    NULL,                        /* No gadget image */
  365.    NULL,                        /* No selected image */
  366.    &angle_text,                 /* GadgetText */
  367.    0,                           /* No mutual exclusion */
  368.    (APTR)&angle_string,         /* SpecialInfo */
  369.    ANGLE_GAD,                   /* Gadget id */
  370.    NULL                         /* No user data */
  371. };
  372.  
  373. #define VELOCITY_GAD 3
  374. struct Gadget velocity_gad = {
  375.    &angle_gad,                  /* NextGadget */
  376.    0L,138L,199L,11L,            /* LeftEdge, TopEdge, Width, Height */
  377.    GADGHCOMP,                   /* Complement image for select */
  378.    RELVERIFY,                   /* Release verify */
  379.    PROPGADGET |                 /* This is a proportional gadget */
  380.    REQGADGET,                   /* This is a requester gadget */
  381.    (APTR)&prop_image,           /* Gadget image */
  382.    NULL,                        /* No selected image */
  383.    &velocity_text,              /* GadgetText */
  384.    0,                           /* No mutual exclusion */
  385.    (APTR)&velocity_prop,        /* SpecialInfo */
  386.    VELOCITY_GAD,                /* Gadget id */
  387.    NULL                         /* No user data */
  388. };
  389.  
  390. #define AIRFOIL_GAD 4
  391. struct Gadget airfoil_gad = {
  392.    &velocity_gad,               /* NextGadget */
  393.    84L,15L,32L,22L,             /* LeftEdge, TopEdge, Width, Height */
  394.    GADGHIMAGE |                 /* Use alternate image for select */
  395.    GADGIMAGE,                   /* Render gadget as an image */
  396.    TOGGLESELECT |               /* Toggle gadget each time it is selected */
  397.    GADGIMMEDIATE,               /* Signal me when user selects gadget */
  398.    BOOLGADGET |                 /* This is a boolean gadget */
  399.    REQGADGET,                   /* This is a requester gadget */
  400.    (APTR)&stream_image,         /* Pointer to gadget image */
  401.    (APTR)&pressure_image,       /* Pointer to selected image */
  402.    NULL,                        /* No text */
  403.    0,                           /* No mutual exclusion */
  404.    NULL,                        /* No special info */
  405.    AIRFOIL_GAD,                 /* Gadget id */
  406.    NULL                         /* No user data */
  407. };
  408.  
  409. #define TITLE_GAD 5
  410. struct Gadget title_gad = {
  411.    &airfoil_gad,                /* NextGadget */
  412.    24L,0L,151L,10L,             /* LeftEdge, TopEdge, Width, Height */
  413.    GADGHCOMP,                   /* Complement image for select */
  414.    TOGGLESELECT |               /* Toggle gadget each time it is selected */
  415.    GADGIMMEDIATE,               /* Signal me when user selects gadget */
  416.    BOOLGADGET |                 /* This is a boolean gadget */
  417.    REQGADGET,                   /* This is a requester gadget */
  418.    (APTR)&title_border,         /* Pointer to gadget image */
  419.    NULL,                        /* No selected image */
  420.    NULL,                        /* No text */
  421.    0,                           /* No mutual exclusion */
  422.    NULL,                        /* No special info */
  423.    TITLE_GAD,                   /* Gadget id */
  424.    NULL                         /* No user data */
  425. };
  426.  
  427. #define CLOSE_GAD 6
  428. struct Gadget close_gad = {
  429.    &title_gad,                  /* NextGadget */
  430.    176L,0L,24L,10L,             /* LeftEdge, TopEdge, Width, Height */
  431.    GADGHCOMP |                  /* Complement image for select */
  432.    GADGIMAGE,                   /* Render gadget as an image */
  433.    GADGIMMEDIATE |              /* Signal me when user selects gadget */
  434.    RELVERIFY |                  /* Release verify */
  435.    ENDGADGET,                   /* This gadget ends requester */
  436.    BOOLGADGET |                 /* This is a boolean gadget */
  437.    REQGADGET,                   /* This is a requester gadget */
  438.    (APTR)&close_image,          /* Pointer to gadget image */
  439.    NULL,                        /* No selected image */
  440.    NULL,                        /* No text */
  441.    0,                           /* No mutual exclusion */
  442.    NULL,                        /* No special info */
  443.    CLOSE_GAD,                   /* Gadget id */
  444.    NULL                         /* No user data */
  445. };
  446.  
  447. #define QUIT_GAD 7
  448. struct Gadget quit_gad = {
  449.    &close_gad,                  /* NextGadget */
  450.    0L,0L,24L,10L,               /* LeftEdge, TopEdge, Width, Height */
  451.    GADGHCOMP |                  /* Complement image for select */
  452.    GADGIMAGE,                   /* Render gadget as an image */
  453.    GADGIMMEDIATE |              /* Signal me when user selects gadget */
  454.    RELVERIFY |                  /* Release verify */
  455.    ENDGADGET,                   /* This gadget ends requester */
  456.    BOOLGADGET |                 /* This is a boolean gadget */
  457.    REQGADGET,                   /* This is a requester gadget */
  458.    (APTR)&quit_image,           /* Pointer to gadget image */
  459.    NULL,                        /* No selected image */
  460.    NULL,                        /* No text */
  461.    0,                           /* No mutual exclusion */
  462.    NULL,                        /* No special info */
  463.    QUIT_GAD,                    /* Gadget id */
  464.    NULL                         /* No user data */
  465. };
  466.  
  467. struct NewScreen ns = {
  468.    0L, 0L,                      /* LeftEdge, TopEdge */
  469.    640L, 400L, 4L,              /* Width, Height, Depth */
  470.    0L, 1L,                      /* DetailPen, BlockPen */
  471.    HIRES |                      /* ViewMode flags */
  472.    LACE,
  473.    CUSTOMSCREEN,                /* Type */
  474.    NULL,                        /* Default Font */
  475.  
  476.    (UBYTE *)"JOUKOWSKI AIRFOIL GENERATOR",
  477.  
  478.    NULL,                        /* No custom gadgets */
  479.    NULL                         /* No CustomBitMap */
  480. };
  481.  
  482. struct NewWindow nw = {
  483.    0L, 0L,                      /* LeftEdge, TopEdge */
  484.    640L, 400L,                  /* Width, Height */
  485.    0L, 1L,                      /* DetailPen, BlockPen */
  486.    GADGETDOWN |                 /* IDCMP flags */
  487.    GADGETUP |
  488.    REQVERIFY |
  489.    REQCLEAR,
  490.    SMART_REFRESH |              /* Flags */
  491.    ACTIVATE |
  492.    BACKDROP,
  493.    NULL,                        /* No gadgets in window */
  494.    NULL,                        /* Use default checkmark */
  495.    NULL,                        /* No Title */
  496.    NULL,                        /* Pointer to screen, to be set later */
  497.    NULL,                        /* No superbitmap is used */
  498.    0L, 0L, 0L, 0L,              /* Window is not resizable */
  499.    CUSTOMSCREEN                 /* Screen Type */
  500. };
  501.