2 Copyright © 1995-2014, The AROS Development Team. All rights reserved.
6 #include <exec/types.h>
7 #include <intuition/intuition.h>
8 #include <intuition/intuitionbase.h>
9 #include <intuition/screens.h>
11 #include <proto/exec.h>
12 #include <proto/dos.h>
13 #include <proto/intuition.h>
21 GLAContext glcont
=NULL
;
25 PFNGLUNIFORM4IPROC AROSglUniform4i
= NULL
;
29 printf("Getting pointer to glUniform4i...\n");
30 AROSglUniform4i
= glAGetProcAddress("glUniform4i");
32 if (AROSglUniform4i
!= NULL
)
34 printf("Pointer to glUniform4i acquired\n");
35 printf("Calling glUniform4i via pointer\n");
36 AROSglUniform4i(0, 0, 0, 0, 0);
37 printf("glUniform4i called\n");
41 printf("Failed to get pointer to glUniform4i");
45 struct Window
* win
= NULL
;
49 struct TagItem attributes
[ 14 ]; /* 14 should be more than enough :) */
52 // default config. Always used...
53 attributes
[i
].ti_Tag
= GLA_Window
; attributes
[i
++].ti_Data
= (IPTR
)win
;
54 attributes
[i
].ti_Tag
= GLA_Left
; attributes
[i
++].ti_Data
= win
->BorderLeft
;
55 attributes
[i
].ti_Tag
= GLA_Top
; attributes
[i
++].ti_Data
= win
->BorderTop
;
56 attributes
[i
].ti_Tag
= GLA_Bottom
; attributes
[i
++].ti_Data
= win
->BorderBottom
;
57 attributes
[i
].ti_Tag
= GLA_Right
; attributes
[i
++].ti_Data
= win
->BorderRight
;
60 attributes
[i
].ti_Tag
= GLA_DoubleBuf
; attributes
[i
++].ti_Data
= GL_TRUE
;
63 attributes
[i
].ti_Tag
= GLA_RGBMode
; attributes
[i
++].ti_Data
= GL_TRUE
;
66 attributes
[i
].ti_Tag
= TAG_DONE
;
68 glcont
= glACreateContext(attributes
);
69 glAMakeCurrent(glcont
);
74 glADestroyContext(glcont
);
80 ** Open a simple window using OpenWindowTagList()
82 int main(int argc
, char **argv
)
85 win
= OpenWindowTags(0,
86 WA_Title
, (IPTR
)"MesaGetProcAddress",
96 WA_SimpleRefresh
, TRUE
,
97 WA_NoCareRefresh
, TRUE
,
98 WA_IDCMP
, IDCMP_CLOSEWINDOW
,