![]() |
||
| Home | SwiftForth Archive | SwiftX Archive | |

Sorry Christy,
Effectivelly, I just checked my code don't work with any display =
callback.
I don't know where is the problem.=20
Possibly the calling program have to be a console-program.=20
Possibly glut callback uses _CDECL convention.
Charles
-----Message d'origine-----
De : sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com] De la part =
de
Warrender, Christina E
Envoy=E9 : mercredi 9 f=E9vrier 2005 0:47
=C0 : sftalk_at_forth.com
Objet : [sftalk] Re: RE : Re: RE : Re: GLUT
Some of my problems were apparently due to using cimport: instead of
function:=3D20 What's the criteria for choosing between these and =
import:?
Using your examples gets me back to where Roger was. I do get a =
window=3D20
(or at least its frame - the contents look like whatever was on the
screen=3D20 underneath the window) but I also get an access violation.
glutDisplayFunc expects a pointer to a function with no parameters and =
no
return value. =3D20 Should this be set up the same way as Windows =
callbacks?
Christy
=3D20
-----Original Message-----
From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com] On Behalf =
Of
Charles Melice
Sent: Tuesday, February 08, 2005 5:29 AM
To: sftalk_at_forth.com
Subject: [sftalk] RE : Re: RE : Re: GLUT
\ GLUT bed test
library somewhere\glut32.dll
function: glutInit ( *argcp **argv -- )
function: glutInitDisplayMode ( mode -- )
function: glutCreateWindow ( ztitle -- glutid )
function: glutDestroyWindow ( glutid -- )
function: glutMainLoop ( -- )
\ function: glutSetWindow ( glutid -- )
function: glutDisplayFunc ( *func -- )
: #define ( "name" "const" -- )
>in @ >r
bl word drop
bl word count evaluate
r> >in ! constant
bl word drop ;
#define GLUT_RGB 0
#define GLUT_RGBA GLUT_RGB
#define GLUT_INDEX 1
#define GLUT_SINGLE 0
#define GLUT_DOUBLE 2
#define GLUT_ACCUM 4
#define GLUT_ALPHA 8
#define GLUT_DEPTH 16
#define GLUT_STENCIL 32
:NONAME ( -- ) ; 0 CB: DisplayCB
here ,z" prog" here swap , constant **argv
: MAIN ( -- )
0 locals| glutid |
1 pad ! pad **argv glutInit
GLUT_RGBA=3D3D20
GLUT_DOUBLE or=3D3D20
GLUT_ACCUM or=3D3D20
GLUT_DEPTH or
GLUT_STENCIL or glutInitDisplayMode
=3D3D20
z" GLUT Test" glutCreateWindow to glutid
DisplayCB glutDisplayFunc
glutMainLoop
glutid glutDestroyWindow
;
-----Message d'origine-----
De : sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com] De la part =
=3D3D
de Warrender, Christina E Envoy=3D3DE9 : lundi 7 f=3D3DE9vrier 2005 =
17:48 =3D3DC0
: sftalk_at_forth.com Objet : [sftalk] Re: RE : Re: GLUT
Thanks for the tips. Unfortunately, I'm having even less success than =
=3D =3D3D
Roger did originally; I get an access violation on the glutInit right at =
the
beginning. If I try to do glutInit interactively, the problem seems to
happen somewhere in ?IMPORTED. =3D3D3D20
----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com =
For
list command help, send subject "help" to sftalk-request_at_forth.com =
Message
archives are located at http://www.forth.com/archive/sftalk
----------------------------------------------------------------------
This list is a forum for SwiftForth users. For product support and bug
reports, please send email to support_at_forth.com
----------------------------------------------------------------------
----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com =
For
list command help, send subject "help" to sftalk-request_at_forth.com =
Message
archives are located at http://www.forth.com/archive/sftalk
----------------------------------------------------------------------
This list is a forum for SwiftForth users. For product support and bug=20
reports, please send email to support_at_forth.com
----------------------------------------------------------------------
----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
For list command help, send subject "help" to sftalk-request_at_forth.com
Message archives are located at http://www.forth.com/archive/sftalk
----------------------------------------------------------------------
This list is a forum for SwiftForth users. For product support and bug
reports, please send email to support_at_forth.com
----------------------------------------------------------------------
Received on Wed Feb 09 2005 - 02:46:21 PST
This archive was generated by hypermail 2.2.0 : Wed Jan 07 2009 - 03:04:13 PST