Re: use Fastgraph DLL with swiftforth Problem's

From: Mike Ghan <mikeghan_at_logix-controls.com>
Date: Fri, 21 Dec 2001 07:50:42 -0800

Louis Jean-Pierre, it will be difficult to help you with a
third-party library like Fgw32.DLL. I can only guess:

LIBRARY Fgw32.DLL

Function: fg_Draw ( ix iy -- res )
Function: fg_move ( ix iy -- res )

\ Note: there maybe some sort of library initialization
\ required before drawing is allowed.

40 100 fg_move
120 120 fg_Draw

Regarding your example SETLINE, while it would be fine as a DOS
program, it would be difficult to implement under Windows. The
SwiftForth example program Scribble.f is similar to your example.
Windows requires a different way of coding. An excellent book on
Windows programming is Charles Petzold's "Programming Windows"

Good Luck,
Mike

-----Original Message-----
From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com]On
Behalf
Of Schmitt Louis Jean-Pierre
Sent: Friday, December 21, 2001 2:29 AM
To: sftalk_at_forth.com
Subject: [sftalk] use Fastgraph DLL with swiftforth Problem's

CORRECTION

Fastgraph have an C prototype structure exemple

void fg_draw (int ix, int iy);

Pascal

procedure fg_draw ( ix, iy : integer);

and Basic

Sub fg_draw (BxVal ix As Long, ByVal iy As Long)

y have writen the following code

Library Fgw32.DLL

AS Lineto 2 CImport: fg_Draw
AS Moveto 2 Cimport: fg_move

after y have writen in my definition

40 100 moveto \ = access violation
120 120 lineto \ this command have generated an access violation

what is my error ??

tank you for help

Louis Jean-Pierre

PS.

I have writen an complet graphic library under DOS with fastgraph for
DOS
and TF83

I will transfert it to SwiftForth. For this I needed technical support
because I have not enough knowledge for window programming.
An other difficulty for my is that my english vocabulary is verry
verry smal.
Following you can see an exemple of code with Tf83 + Fastgraph.
It can draw an line from an mousecliq to an other mousecliq
It is verry simplicity
Later you can have free use of my source code when you have interest.

: SETLINE ( --- ) \ Line drawing

   0 639 0 479 Setclip \ limit of clipping in the visible window
   GetMouseCliq moveto
   GetMouseCliq lineto
   XXCLIP 2@ YYclip 2@ SetClip
;

----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe sftalk" to listar_at_forth.com
For help with listar commands, send subject "help" to listar_at_forth.com
Archives are located at http://www.forth.com/sftalk -- check them out!
Search the archives! Visit http://www.forth.com/search for details.

----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe sftalk" to listar_at_forth.com
For help with listar commands, send subject "help" to listar_at_forth.com
Archives are located at http://www.forth.com/sftalk -- check them out!
Search the archives! Visit http://www.forth.com/search for details.
Received on Fri Dec 21 2001 - 07:49:45 PST


Subscribe to our e-mail list service. It's free for all SwiftForth and SwiftX users!

This archive was generated 09-Feb-2012. Archive updated nightly.