From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,df430594845cd83d X-Google-Attributes: gid103376,public From: tmoran@bix.com (Tom Moran) Subject: Re: Windows, DirectX, DLLs, and Gnat Date: 1998/08/14 Message-ID: <35d49ab9.8756150@SantaClara01.news.InterNex.Net>#1/1 X-Deja-AN: 381227303 References: <9808131610.AA3749854@camelot> Organization: InterNex Information Services 1-800-595-3333 Newsgroups: comp.lang.ada Date: 1998-08-14T00:00:00+00:00 List-Id: There is complete source for several compilers for three demos of Claw at www.rrsoftware.com Even if you don't decide to buy the full Claw, you can get answers to some of your questions just by looking at a few specific parts of the downloadable source code. >How do I get to WinMain? I need my hInstance See the Claw.Low_Level package body - this is one of the few compiler specific parts, so make sure you look at the correct one.. >pragmas to > interface to the Windows DLL's, but how do i > a) Ensure I am using the correct parameter passing system > b) Ensure that the structures going to and from these functions will be > the right size, with the right fields See any of the Claw packages, most simply Claw.adb Note that not all compilers "do the expected thing" with record layout - you ought to write rep clauses for anything where layout matters (ie, any records passed to/from the OS). >I am planning to draw by rendering the full image into a buffer, and blitting > it to the graphics card using DirectDraw. How do I create a dynamically > allocated storage for the drawing buffer? There is an example of this in the Shelves demo in the full (not the demo) version of Claw. > Are there any valuable online resources specifically for people interested in > coding Ada under Win32 that I should know about? As one of its authors, I naturally think the TriAda '1997 paper "CLAW, a High Level, Portable, Ada 95 Binding for Microsoft Windows" is such a resource. :) > Is there a package that already does this for Ada? Claw. There are also others, of course. I presume you've looked at the thinner win32ada and at http://stad.dsl.nl/~jvandyk