Changeset 2689 for trunk/src/opengl
- Timestamp:
- Feb 9, 2000, 9:51:20 AM (26 years ago)
- Location:
- trunk/src/opengl
- Files:
-
- 210 added
- 5 deleted
- 65 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/opengl/glut/Makefile
r2595 r2689 1 # $Id: Makefile,v 1.2 2000-02-09 08:46:06 jeroen Exp $ 1 2 # 2 3 # PD-Win32 API … … 15 16 16 17 !ifdef DEBUG 17 MAKE_CMD=nmake DEBUG=1 18 !else 19 MAKE_CMD=nmake 18 L=/CO 20 19 !endif 21 20 22 CFLAGS = -Tdp $(CFLAGS) -I$(PDWIN32_INCLUDE)23 CXXFLAGS = $(CXXFLAGS) -I$(PDWIN32_INCLUDE)21 CFLAGS = -Tdp -I..\mesa -I..\glu $(CFLAGS) -I$(PDWIN32_INCLUDE) 22 CXXFLAGS = -Tdp -I..\mesa -I..\glu $(CXXFLAGS) -I$(PDWIN32_INCLUDE) 24 23 25 24 TARGET=GLUT32 … … 36 35 glut_tr24.obj glut_util.obj glut_vidresize.obj glut_warp.obj glut_win.obj \ 37 36 glut_winmisc.obj win32_glx.obj win32_menu.obj win32_util.obj win32_winproc.obj \ 38 win32_x11.obj initterm.obj 37 win32_x11.obj initterm.obj glut_term.obj 39 38 40 39 all : $(TARGET).DLL 41 40 42 41 $(TARGET).DLL: $(OBJS) $(TARGET).def $(TARGET).lrf 43 ILINK /FREE /NOE @$(TARGET).lrf42 ILINK /FREE /NOE $(L) @$(TARGET).lrf 44 43 $(CP) $@ $(PDWIN32_BIN) 45 44 … … 105 104 /OUT:$(TARGET).DLL /DLL 106 105 $(PDWIN32_LIB)\ODINCRT.LIB 107 CPPOM30O.LIB 106 $(RTLLIB_O) 108 107 $(PDWIN32_LIB)\WINMM.LIB 109 108 $(PDWIN32_LIB)\KERNEL32.LIB -
trunk/src/opengl/glut/glut.h
r2595 r2689 1 /* $Id: glut.h,v 1.2 2000-02-09 08:46:07 jeroen Exp $ */ 1 2 #ifndef __glut_h__ 2 3 #define __glut_h__ -
trunk/src/opengl/glut/glut32.def
r2595 r2689 1 ; $Id: glut32.def,v 1.2 2000-02-09 08:46:07 jeroen Exp $ 1 2 LIBRARY GLUT32 INITINSTANCE TERMINSTANCE 2 3 -
trunk/src/opengl/glut/glut_8x13.c
r2595 r2689 1 1 /* $Id: glut_8x13.c,v 1.2 2000-02-09 08:46:07 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_9x15.c
r2595 r2689 1 1 /* $Id: glut_9x15.c,v 1.2 2000-02-09 08:46:07 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_bitmap.c
r2595 r2689 1 1 /* $Id: glut_bitmap.c,v 1.2 2000-02-09 08:46:08 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 -
trunk/src/opengl/glut/glut_bwidth.c
r2595 r2689 1 1 /* $Id: glut_bwidth.c,v 1.2 2000-02-09 08:46:08 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 -
trunk/src/opengl/glut/glut_cindex.c
r2595 r2689 1 1 /* $Id: glut_cindex.c,v 1.2 2000-02-09 08:46:08 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1996, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_cmap.c
r2595 r2689 1 1 /* $Id: glut_cmap.c,v 1.2 2000-02-09 08:46:08 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1996, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_cursor.c
r2595 r2689 1 1 /* $Id: glut_cursor.c,v 1.2 2000-02-09 08:46:08 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1995, 1998. */ 3 3 -
trunk/src/opengl/glut/glut_dials.c
r2595 r2689 1 1 /* $Id: glut_dials.c,v 1.2 2000-02-09 08:46:09 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 … … 8 8 #include "glutint.h" 9 9 10 void APIENTRY 10 void APIENTRY 11 11 glutButtonBoxFunc(GLUTbuttonBoxCB buttonBoxFunc) 12 12 { … … 17 17 } 18 18 19 void APIENTRY 19 void APIENTRY 20 20 glutDialsFunc(GLUTdialsCB dialsFunc) 21 21 { -
trunk/src/opengl/glut/glut_dstr.c
r2595 r2689 1 1 /* $Id: glut_dstr.c,v 1.2 2000-02-09 08:46:09 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_event.c
r2595 r2689 1 1 /* $Id: glut_event.c,v 1.2 2000-02-09 08:46:09 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1995, 1996, 1997, 1998. */ 3 3 … … 333 333 TranslateMessage(&event); /* translate virtual-key messages*/ 334 334 #if defined(__WIN32OS2__) 335 DispatchMessageA(&event); 335 DispatchMessageA(&event); /* call the window proc*/ 336 336 #else 337 337 DispatchMessage(&event); /* call the window proc*/ … … 1033 1033 } 1034 1034 /* Be sure to configure window BEFORE map window is done. */ 1035 1036 1035 if (workMask & GLUT_CONFIGURE_WORK) { 1037 1036 #if defined(_WIN32) || defined(__WIN32OS2__) … … 1083 1082 /* Do the repositioning, moving, and push/pop. */ 1084 1083 SetWindowPos(window->win, 1085 window->desiredStack == Above ? HWND_TOP : HWND_NOTOPMOST,1084 window->desiredStack == (Above ? HWND_TOP : HWND_NOTOPMOST), 1086 1085 changes.left, changes.top, 1087 1086 changes.right - changes.left, changes.bottom - changes.top, … … 1098 1097 window->desiredY = point.y; 1099 1098 } 1100 #else /* !_WIN32*/1099 #else /* !_WIN32 */ 1101 1100 XWindowChanges changes; 1102 1101 … … 1114 1113 1115 1114 hints.flags = MWM_HINTS_DECORATIONS; 1116 hints.decorations = 0; /* Absolutely no1115 hints.decorations = 0; /* Absolutely no*/ 1117 1116 decorations. */ 1118 1117 XChangeProperty(__glutDisplay, window->win, … … 1205 1204 1206 1205 __glutSetWindow(window); 1206 1207 1207 window->reshape(window->width, window->height); 1208 1208 window->forceReshape = False; 1209 1210 #ifdef __WIN32OS2__ 1211 /* JvdH - 03/02/2000 */ 1212 /* FIXME: This is a rather stupid hack... */ 1213 /* The client area appears transparent... */ 1214 /* By twice swapping the ZORDER the client area is repainted... */ 1215 /* I'd like a better fix, but for now this seems to work */ 1216 SetWindowPos(window->win, 1217 HWND_BOTTOM, 1218 0,0, 1219 0,0, 1220 SWP_NOMOVE | SWP_NOSIZE); 1221 1222 SetWindowPos(window->win, 1223 HWND_TOP, 1224 0,0, 1225 0,0, 1226 SWP_NOMOVE | SWP_NOSIZE); 1227 #endif 1209 1228 1210 1229 /* Setting the redisplay bit on the first reshape is … … 1216 1235 workMask |= GLUT_REDISPLAY_WORK; 1217 1236 } 1237 1238 1218 1239 /* The code below is more involved than otherwise necessary 1219 1240 because it is paranoid about the overlay or entire window … … 1303 1324 finish and debug work there is. */ 1304 1325 1305 1306 1326 workMask |= window->workMask; 1307 1327 -
trunk/src/opengl/glut/glut_ext.c
r2595 r2689 1 1 /* $Id: glut_ext.c,v 1.2 2000-02-09 08:46:11 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997. */ 3 3 … … 12 12 13 13 /* CENTRY */ 14 int APIENTRY 14 int APIENTRY 15 15 glutExtensionSupported(const char *extension) 16 16 { -
trunk/src/opengl/glut/glut_fullscrn.c
r2595 r2689 1 1 /* $Id: glut_fullscrn.c,v 1.2 2000-02-09 08:46:11 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1995, 1998. */ 3 3 -
trunk/src/opengl/glut/glut_gamemode.c
r2595 r2689 1 1 /* $Id: glut_gamemode.c,v 1.2 2000-02-09 08:46:11 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1998. */ 3 3 -
trunk/src/opengl/glut/glut_get.c
r2595 r2689 1 1 /* $Id: glut_get.c,v 1.2 2000-02-09 08:46:12 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997, 1998. */ 3 3 -
trunk/src/opengl/glut/glut_hel10.c
r2595 r2689 1 1 /* $Id: glut_hel10.c,v 1.2 2000-02-09 08:46:12 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_hel12.c
r2595 r2689 1 1 /* $Id: glut_hel12.c,v 1.2 2000-02-09 08:46:12 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_hel18.c
r2595 r2689 1 1 /* $Id: glut_hel18.c,v 1.2 2000-02-09 08:46:12 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_init.c
r2595 r2689 1 1 /* $Id: glut_init.c,v 1.2 2000-02-09 08:46:13 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997. */ 3 3 … … 59 59 #if defined(_WIN32) || defined(__WIN32OS2__) 60 60 61 #if def __BORLANDC__61 #if defined(__BORLANDC__) || defined(__WIN32OS2__) 62 62 #include <float.h> /* For masking floating point exceptions. */ 63 63 #endif … … 79 79 return; 80 80 81 #if def __BORLANDC__81 #if defined(__BORLANDC__) || defined(__WIN32OS2__) 82 82 /* Under certain conditions (e.g. while rendering solid surfaces with 83 83 lighting enabled) Microsoft OpenGL libraries cause some illegal -
trunk/src/opengl/glut/glut_input.c
r2595 r2689 1 1 /* $Id: glut_input.c,v 1.2 2000-02-09 08:46:13 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997, 1998. */ 3 3 -
trunk/src/opengl/glut/glut_joy.c
r2595 r2689 1 1 /* $Id: glut_joy.c,v 1.2 2000-02-09 08:46:13 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1997, 1998. */ 3 3 -
trunk/src/opengl/glut/glut_key.c
r2595 r2689 1 1 /* $Id: glut_key.c,v 1.2 2000-02-09 08:46:13 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_keyctrl.c
r2595 r2689 1 1 /* $Id: glut_keyctrl.c,v 1.2 2000-02-09 08:46:13 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1996, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_keyup.c
r2595 r2689 1 1 /* $Id: glut_keyup.c,v 1.2 2000-02-09 08:46:14 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_mesa.c
r2595 r2689 1 1 /* $Id: glut_mesa.c,v 1.2 2000-02-09 08:46:14 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1996. */ 3 3 4 /* This program is freely distributable without licensing fees 5 and is provided without guarantee or warrantee expressed or 4 /* This program is freely distributable without licensing fees 5 and is provided without guarantee or warrantee expressed or 6 6 implied. This program is -not- in the public domain. */ 7 7 … … 29 29 static int doneAlready = 0; 30 30 char *env, *vendor, *renderer; 31 32 /*#ifdef __WIN32OS2__ 33 __glutMesaSwapHackSupport=1; 34 return; 35 #endif*/ 31 36 32 37 if (doneAlready) -
trunk/src/opengl/glut/glut_modifier.c
r2595 r2689 1 1 /* $Id: glut_modifier.c,v 1.2 2000-02-09 08:46:14 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 4 /* This program is freely distributable without licensing fees 5 and is provided without guarantee or warrantee expressed or 4 /* This program is freely distributable without licensing fees 5 and is provided without guarantee or warrantee expressed or 6 6 implied. This program is -not- in the public domain. */ 7 7 -
trunk/src/opengl/glut/glut_mroman.c
r2595 r2689 1 1 /* $Id: glut_mroman.c,v 1.2 2000-02-09 08:46:15 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_overlay.c
r2595 r2689 1 1 /* $Id: glut_overlay.c,v 1.2 2000-02-09 08:46:15 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1996, 1997. */ 3 3 … … 456 456 457 457 window->overlay = overlay; 458 glutUseLayer( GLUT_OVERLAY);458 glutUseLayer((GLenum)GLUT_OVERLAY); 459 459 460 460 if (overlay->treatAsSingle) { … … 475 475 /* If using overlay, switch to the normal layer. */ 476 476 if (window->renderWin == overlay->win) { 477 glutUseLayer( GLUT_NORMAL);477 glutUseLayer((GLenum)GLUT_NORMAL); 478 478 } 479 479 #if !defined(_WIN32) && !defined(__WIN32OS2__) -
trunk/src/opengl/glut/glut_roman.c
r2595 r2689 1 1 /* $Id: glut_roman.c,v 1.2 2000-02-09 08:46:16 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_shapes.c
r2595 r2689 1 1 /* $Id: glut_shapes.c,v 1.2 2000-02-09 08:46:16 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997. */ 3 3 … … 70 70 { 71 71 QUAD_OBJ_INIT(); 72 gluQuadricDrawStyle(quadObj, GLU_LINE);73 gluQuadricNormals(quadObj, GLU_SMOOTH);72 gluQuadricDrawStyle(quadObj, (GLenum)GLU_LINE); 73 gluQuadricNormals(quadObj, (GLenum)GLU_SMOOTH); 74 74 /* If we ever changed/used the texture or orientation state 75 75 of quadObj, we'd need to change it to the defaults here … … 82 82 { 83 83 QUAD_OBJ_INIT(); 84 gluQuadricDrawStyle(quadObj, GLU_FILL);85 gluQuadricNormals(quadObj, GLU_SMOOTH);84 gluQuadricDrawStyle(quadObj, (GLenum)GLU_FILL); 85 gluQuadricNormals(quadObj, (GLenum)GLU_SMOOTH); 86 86 /* If we ever changed/used the texture or orientation state 87 87 of quadObj, we'd need to change it to the defaults here … … 95 95 { 96 96 QUAD_OBJ_INIT(); 97 gluQuadricDrawStyle(quadObj, GLU_LINE);98 gluQuadricNormals(quadObj, GLU_SMOOTH);97 gluQuadricDrawStyle(quadObj, (GLenum)GLU_LINE); 98 gluQuadricNormals(quadObj, (GLenum)GLU_SMOOTH); 99 99 /* If we ever changed/used the texture or orientation state 100 100 of quadObj, we'd need to change it to the defaults here … … 108 108 { 109 109 QUAD_OBJ_INIT(); 110 gluQuadricDrawStyle(quadObj, GLU_FILL);111 gluQuadricNormals(quadObj, GLU_SMOOTH);110 gluQuadricDrawStyle(quadObj, (GLenum)GLU_FILL); 111 gluQuadricNormals(quadObj, (GLenum)GLU_SMOOTH); 112 112 /* If we ever changed/used the texture or orientation state 113 113 of quadObj, we'd need to change it to the defaults here -
trunk/src/opengl/glut/glut_space.c
r2595 r2689 1 1 /* $Id: glut_space.c,v 1.2 2000-02-09 08:46:16 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 … … 8 8 #include "glutint.h" 9 9 10 void APIENTRY 10 void APIENTRY 11 11 glutSpaceballMotionFunc(GLUTspaceMotionCB spaceMotionFunc) 12 12 { … … 17 17 } 18 18 19 void APIENTRY 19 void APIENTRY 20 20 glutSpaceballRotateFunc(GLUTspaceRotateCB spaceRotateFunc) 21 21 { … … 26 26 } 27 27 28 void APIENTRY 28 void APIENTRY 29 29 glutSpaceballButtonFunc(GLUTspaceButtonCB spaceButtonFunc) 30 30 { -
trunk/src/opengl/glut/glut_stroke.c
r2595 r2689 1 1 /* $Id: glut_stroke.c,v 1.2 2000-02-09 08:46:16 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 -
trunk/src/opengl/glut/glut_swap.c
r2595 r2689 1 1 /* $Id: glut_swap.c,v 1.2 2000-02-09 08:46:17 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_swidth.c
r2595 r2689 1 1 /* $Id: glut_swidth.c,v 1.2 2000-02-09 08:46:17 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1995. */ 3 3 -
trunk/src/opengl/glut/glut_tablet.c
r2595 r2689 1 1 /* $Id: glut_tablet.c,v 1.2 2000-02-09 08:46:17 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 … … 10 10 #include "glutint.h" 11 11 12 void APIENTRY 12 void APIENTRY 13 13 glutTabletMotionFunc(GLUTtabletMotionCB tabletMotionFunc) 14 14 { … … 24 24 } 25 25 26 void APIENTRY 26 void APIENTRY 27 27 glutTabletButtonFunc(GLUTtabletButtonCB tabletButtonFunc) 28 28 { -
trunk/src/opengl/glut/glut_teapot.c
r2595 r2689 1 1 /* $Id: glut_teapot.c,v 1.2 2000-02-09 08:46:17 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 … … 196 196 197 197 /* CENTRY */ 198 void APIENTRY 198 void APIENTRY 199 199 glutSolidTeapot(GLdouble scale) 200 200 { … … 202 202 } 203 203 204 void APIENTRY 204 void APIENTRY 205 205 glutWireTeapot(GLdouble scale) 206 206 { -
trunk/src/opengl/glut/glut_tr10.c
r2595 r2689 1 1 /* $Id: glut_tr10.c,v 1.2 2000-02-09 08:46:18 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_tr24.c
r2595 r2689 1 1 /* $Id: glut_tr24.c,v 1.2 2000-02-09 08:46:18 jeroen Exp $ */ 2 2 /* GENERATED FILE -- DO NOT MODIFY */ 3 3 -
trunk/src/opengl/glut/glut_util.c
r2595 r2689 1 1 /* $Id: glut_util.c,v 1.2 2000-02-09 08:46:19 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 … … 44 44 dprintf(("GLUT32: %s\n",errmsg)); 45 45 #endif 46 47 46 fprintf(stderr, "GLUT: Warning in %s: ", 48 47 __glutProgramName ? __glutProgramName : "(unamed)"); -
trunk/src/opengl/glut/glut_vidresize.c
r2595 r2689 1 1 /* $Id: glut_vidresize.c,v 1.2 2000-02-09 08:46:19 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1996. */ 3 3 -
trunk/src/opengl/glut/glut_warp.c
r2595 r2689 1 1 /* $Id: glut_warp.c,v 1.2 2000-02-09 08:46:19 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1996, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_win.c
r2595 r2689 1 1 /* $Id: glut_win.c,v 1.2 2000-02-09 08:46:19 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997. */ 3 3 -
trunk/src/opengl/glut/glut_winmisc.c
r2595 r2689 1 1 /* $Id: glut_winmisc.c,v 1.2 2000-02-09 08:46:19 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994. */ 3 3 -
trunk/src/opengl/glut/glutbitmap.h
r2595 r2689 1 /* $Id: glutbitmap.h,v 1.2 2000-02-09 08:46:19 jeroen Exp $ */ 1 2 #ifndef __glutbitmap_h__ 2 3 #define __glutbitmap_h__ -
trunk/src/opengl/glut/glutint.h
r2595 r2689 1 /* $Id: glutint.h,v 1.2 2000-02-09 08:46:19 jeroen Exp $ */ 1 2 #ifndef __glutint_h__ 2 3 #define __glutint_h__ -
trunk/src/opengl/glut/glutos2.h
r2595 r2689 1 /* $Id: glutos2.h,v 1.2 2000-02-09 08:46:20 jeroen Exp $ */ 1 2 #ifndef __glutos2_h__ 2 3 #define __glutos2_h__ -
trunk/src/opengl/glut/glutstroke.h
r2595 r2689 1 /* $Id: glutstroke.h,v 1.2 2000-02-09 08:46:20 jeroen Exp $ */ 1 2 #ifndef __glutstroke_h__ 2 3 #define __glutstroke_h__ -
trunk/src/opengl/glut/initterm.cpp
r2595 r2689 1 /* $Id: initterm.cpp,v 1. 1 2000-02-01 19:42:07 sandervlExp $ */1 /* $Id: initterm.cpp,v 1.2 2000-02-09 08:46:20 jeroen Exp $ */ 2 2 3 3 /* … … 41 41 } 42 42 43 BOOL WINAPI Glut32LibMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID ImpLoad); 44 43 45 /*-------------------------------------------------------------------*/ 44 46 /* A clean up routine registered with DosExitList must be used if */ … … 48 50 /*-------------------------------------------------------------------*/ 49 51 static void APIENTRY cleanup(ULONG reason); 50 51 52 52 53 /****************************************************************************/ … … 81 82 /*******************************************************************/ 82 83 83 if(RegisterLxDll(hModule, 0, 0) == FALSE)84 if(RegisterLxDll(hModule, Glut32LibMain, 0) == FALSE) 84 85 return 0UL; 85 86 86 rc = DosExitList(0x000 0F000|EXLST_ADD, cleanup);87 rc = DosExitList(0x000F0000|EXLST_ADD, cleanup); 87 88 if(rc) 88 89 return 0UL; -
trunk/src/opengl/glut/layerutil.c
r2595 r2689 1 1 /* $Id: layerutil.c,v 1.2 2000-02-09 08:46:20 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1993, 1994. */ 3 3 -
trunk/src/opengl/glut/layerutil.h
r2595 r2689 1 /* $Id: layerutil.h,v 1.2 2000-02-09 08:46:21 jeroen Exp $ */ 1 2 #ifndef __layerutil_h__ 2 3 #define __layerutil_h__ -
trunk/src/opengl/glut/os2_glx.h
r2595 r2689 1 /* $Id: os2_glx.h,v 1.2 2000-02-09 08:46:21 jeroen Exp $ */ 1 2 #ifndef __os2_glx_h__ 2 3 #define __os2_glx_h__ -
trunk/src/opengl/glut/os2_x11.h
r2595 r2689 1 /* $Id: os2_x11.h,v 1.2 2000-02-09 08:46:21 jeroen Exp $ */ 1 2 #ifndef __os2_x11_h__ 2 3 #define __os2_x11_h__ -
trunk/src/opengl/glut/pfddefs.h
r2595 r2689 1 /* $Id: pfddefs.h,v 1.2 2000-02-09 08:46:21 jeroen Exp $ */ 1 2 #define PFD_TYPE_RGBA 0 2 3 #define PFD_TYPE_COLORINDEX 1 -
trunk/src/opengl/glut/stroke.h
r2595 r2689 1 /* $Id: stroke.h,v 1.2 2000-02-09 08:46:21 jeroen Exp $ */ 1 2 /* $XConsortium: wfont.h,v 5.1 91/02/16 09:46:37 rws Exp $ */ 2 3 … … 6 7 All Rights Reserved 7 8 8 Permission to use, copy, modify, and distribute this software and its 9 documentation for any purpose and without fee is hereby granted, 9 Permission to use, copy, modify, and distribute this software and its 10 documentation for any purpose and without fee is hereby granted, 10 11 provided that the above copyright notice appear in all copies and that 11 both that copyright notice and this permission notice appear in 12 both that copyright notice and this permission notice appear in 12 13 supporting documentation, and that the names of Sun Microsystems, 13 the X Consortium, and MIT not be used in advertising or publicity 14 pertaining to distribution of the software without specific, written 15 prior permission. 14 the X Consortium, and MIT not be used in advertising or publicity 15 pertaining to distribution of the software without specific, written 16 prior permission. 16 17 17 SUN MICROSYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, 18 INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT 19 SHALL SUN MICROSYSTEMS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL 18 SUN MICROSYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, 19 INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT 20 SHALL SUN MICROSYSTEMS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL 20 21 DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 21 22 WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, … … 85 86 Path_pt_ptr pts; /* pointer to them */ 86 87 int closed; /* true if the subpath is closed */ 87 int dcmp_flag; /* flag for pgon dcmp, pgon type 88 int dcmp_flag; /* flag for pgon dcmp, pgon type 88 89 * and dcmped triangle type */ 89 90 } Path_subpath; -
trunk/src/opengl/glut/wgl.h
r2595 r2689 1 /* JvdH - define the wglXXX functions*/1 /* $Id: wgl.h,v 1.2 2000-02-09 08:46:22 jeroen Exp $ */ 2 2 3 3 typedef ULONG HGC; -
trunk/src/opengl/glut/win32_glx.c
r2595 r2689 1 1 /* $Id: win32_glx.c,v 1.2 2000-02-09 08:46:22 jeroen Exp $ */ 2 2 /* Copyright (c) Nate Robins, 1997. */ 3 3 -
trunk/src/opengl/glut/win32_menu.c
r2595 r2689 1 1 /* $Id: win32_menu.c,v 1.2 2000-02-09 08:46:22 jeroen Exp $ */ 2 2 /* Copyright (c) Mark J. Kilgard, 1994, 1997, 1998. */ 3 3 /* Copyright (c) Nate Robins, 1997. */ -
trunk/src/opengl/glut/win32_util.c
r2595 r2689 1 1 /* $Id: win32_util.c,v 1.2 2000-02-09 08:46:22 jeroen Exp $ */ 2 2 /* Copyright (c) Nate Robins, 1997. */ 3 3 -
trunk/src/opengl/glut/win32_winproc.c
r2595 r2689 1 1 /* $Id: win32_winproc.c,v 1.2 2000-02-09 08:46:23 jeroen Exp $ */ 2 2 /* Copyright (c) Nate Robins, 1997. */ 3 3 /* portions Copyright (c) Mark Kilgard, 1997, 1998. */ … … 10 10 #include "glutint.h" 11 11 #if defined(__WIN32OS2__) 12 #include "wgl.h" 12 13 #include <ctype.h> 13 14 #endif … … 59 60 LPMINMAXINFO minmax; /* Minimum/maximum info structure. */ 60 61 GLUTwindow* window; /* GLUT window associated with message. */ 61 GLUTmenu* menu; /* GLUT menu associated with message.*/62 GLUTmenu* menu; /* GLUT menu associated with message.*/ 62 63 int x, y, width, height, key; 63 64 int button = -1; 65 int fSendKeyStroke=1; 64 66 65 67 switch(msg) { … … 69 71 PostQuitMessage(0); 70 72 return 0; 71 #if 073 #if defined(__WIN32OS2__) 72 74 case WM_DESTROY: 73 75 /* XXX NVidia's NT OpenGL can have problems closing down … … 88 90 #endif 89 91 case WM_PAINT: 92 dprintf(("GLUT32: WM_PAINT processing...\n")); 90 93 window = __glutGetWindow(hwnd); 91 94 if (window) { 92 BeginPaint(hwnd, &ps); /* Must have this for some Win32 reason. */ 95 #ifndef __WIN32OS2__ 96 BeginPaint(hwnd, &ps); /* Must have this for some Win32 reason.*/ 93 97 EndPaint(hwnd, &ps); 98 #endif 94 99 if (window->win == hwnd) { 95 100 __glutPostRedisplay(window, GLUT_REPAIR_WORK); … … 211 216 __glutSetWindow(window); 212 217 __glutModifierMask = 0; 213 if (GetKeyState(VK_SHIFT) < 0) /* < 0 = high order bit is on*/218 if (GetKeyState(VK_SHIFT) < 0) /* < 0 = high order bit is on*/ 214 219 __glutModifierMask |= ShiftMask; 215 220 if (GetKeyState(VK_CONTROL) < 0) … … 293 298 __glutSetWindow(window); 294 299 __glutModifierMask = 0; 295 if (GetKeyState(VK_SHIFT) < 0) /* < 0 = high order bit is on*/300 if (GetKeyState(VK_SHIFT) < 0) /* < 0 = high order bit is on*/ 296 301 __glutModifierMask |= ShiftMask; 297 302 if (GetKeyState(VK_CONTROL) < 0) … … 304 309 /* Specially handle any keys that match ASCII values but 305 310 do not generate Windows WM_SYSCHAR or WM_CHAR messages. */ 311 306 312 switch (wParam) { 307 313 case VK_DELETE: 308 314 handleDelete: 309 315 /* Delete is an ASCII character. */ 310 GetCursorPos(&point); 311 ScreenToClient(window->win, &point); 312 __glutSetWindow(window); 313 __glutModifierMask = 0; 314 if (GetKeyState(VK_SHIFT) < 0) /* < 0 = high order bit is on */ 315 __glutModifierMask |= ShiftMask; 316 if (GetKeyState(VK_CONTROL) < 0) 317 __glutModifierMask |= ControlMask; 318 if (GetKeyState(VK_MENU) < 0) 319 __glutModifierMask |= Mod1Mask; 320 window->keyboard((unsigned char) 127, point.x, point.y); 321 __glutModifierMask = (unsigned int) ~0; 322 return 0; 316 dprintf(("VK_DELETE - wParam is %d\n",wParam)); 317 key=(unsigned char)127; 318 break; 319 320 #ifdef __WIN32OS2__ 321 /* For some reason Odin doesn't generate WM_CHARS for 'special' keys */ 322 /* at least - none that are received here. Create 'em here!! */ 323 case VK_F1: 324 case VK_F2: 325 case VK_F3: 326 case VK_F4: 327 case VK_F5: 328 case VK_F6: 329 case VK_F7: 330 case VK_F8: 331 case VK_F9: 332 case VK_F10: 333 case VK_F11: 334 case VK_F12: 335 case VK_LEFT: 336 case VK_UP: 337 case VK_RIGHT: 338 case VK_DOWN: 339 case VK_PRIOR: 340 case VK_NEXT: 341 case VK_HOME: 342 case VK_END: 343 case VK_INSERT: 344 case VK_ESCAPE: 345 key=wParam; 346 break; 347 #endif 348 323 349 default: 324 350 /* Let the following WM_SYSCHAR or WM_CHAR message generate 325 351 the keyboard callback. */ 352 fSendKeyStroke=0; 326 353 break; 327 354 } 355 356 if(fSendKeyStroke) 357 { 358 dprintf(("Sending keystroke %d...\n",key)); 359 360 GetCursorPos(&point); 361 ScreenToClient(window->win, &point); 362 __glutSetWindow(window); 363 __glutModifierMask = 0; 364 if (GetKeyState(VK_SHIFT) < 0) /* < 0 = high order bit is on*/ 365 __glutModifierMask |= ShiftMask; 366 if (GetKeyState(VK_CONTROL) < 0) 367 __glutModifierMask |= ControlMask; 368 if (GetKeyState(VK_MENU) < 0) 369 __glutModifierMask |= Mod1Mask; 370 window->keyboard(key, point.x, point.y); 371 __glutModifierMask = (unsigned int) ~0; 372 373 return 0; 374 } 328 375 } 329 376 return 0; … … 566 613 567 614 case WM_SIZE: 615 dprintf(("GLUT32: Handling WM_SIZE...")); 568 616 window = __glutGetWindow(hwnd); 569 617 if (window) { … … 586 634 /* A reshape should be considered like posting a 587 635 repair request. */ 636 dprintf(("GLUT32: WM_SIZE processing -> GLUT_REPAIR_WORK\n")); 588 637 __glutPostRedisplay(window, GLUT_REPAIR_WORK); 589 638 } 590 639 } 640 dprintf(("GLUT32: Handled WM_SIZE...")); 591 641 return 0; 592 642 -
trunk/src/opengl/glut/win32_x11.c
r2595 r2689 1 1 /* $Id: win32_x11.c,v 1.2 2000-02-09 08:46:23 jeroen Exp $ */ 2 2 /* Copyright (c) Nate Robins, 1997. */ 3 3 /* portions Copyright (c) Mark Kilgard, 1998. */ -
trunk/src/opengl/makefile
r2595 r2689 1 # /* $Id: makefile,v 1.2 2000-02-01 19:41:55 sandervl Exp $ */1 # $Id: makefile,v 1.3 2000-02-09 08:50:54 jeroen Exp $ 2 2 # 3 3 # PD-Win32 API … … 26 26 27 27 TARGET1 = opengl32 28 TARGET2 = glu 3228 TARGET2 = glu\glu32 29 29 TARGET3 = glut\glut32 30 30 31 31 OBJS1= opengl32.obj initterm.obj 32 OBJS2= glu32.obj glucb32.obj initterm.obj33 32 34 all: $(TARGET1).dll $(TARGET1).lib $(TARGET2).dll $(TARGET2).lib $(TARGET3).dll 33 all: $(TARGET1).dll $(TARGET1).lib \ 34 $(TARGET2).dll $(TARGET2).lib \ 35 $(TARGET3).dll $(TARGET3).lib 35 36 36 37 $(TARGET1).dll: $(OBJS1) $(TARGET1).def … … 49 50 $(IMPDEF) $** $@ 50 51 51 $(TARGET2).dll: $(OBJS2) $(TARGET2).def 52 $(LD) $(LDFLAGS) -Fm -Fe$@ $(OBJS2) $(TARGET2).def \ 53 $(PDWIN32_LIB)/pmwinx.lib $(PDWIN32_LIB)/kernel32.lib \ 54 $(PDWIN32_LIB)/user32.lib $(PDWIN32_LIB)/odincrt.lib \ 55 OS2386.LIB $(RTLLIB_O) 56 $(CP) $@ $(PDWIN32_BIN) 57 58 59 $(TARGET2).lib: $(TARGET2)exp.def 60 $(IMPLIB) $(IMPLIBFLAGS) $@ $(TARGET2)exp.def 61 $(CP) $@ $(PDWIN32_LIB) 62 63 $(TARGET2)exp.def: $(TARGET2).def 64 $(IMPDEF) $** $@ 65 52 $(TARGET2).dll: 53 cd glu 54 $(MAKE_CMD) 55 cd .. 66 56 67 57 $(TARGET3).dll: 68 58 cd glut 69 59 $(MAKE_CMD) 60 cd .. 70 61 71 62 opengl32.obj: opengl32.cpp pglos2.h glos2.h initterm.h 72 glu32.obj: glu32.cpp glos2.h gluos2.h initterm.h glucb32.h73 63 initterm.obj: initterm.cpp initterm.h 74 glucb32.obj: glucb32.cpp glucb32.h glos2.h gluos2.h75 64 76 65 clean: … … 78 67 $(RM) $(PDWIN32_BIN)\$(TARGET1).dll 79 68 $(RM) $(PDWIN32_LIB)\$(TARGET1).lib 80 $(RM) $(PDWIN32_BIN)\$(TARGET2).dll81 $(RM) $(PDWIN32_LIB)\$(TARGET2).lib82 69 cd glut 83 70 $(MAKE_CMD) clean 71 cd ..\glu 72 $(MAKE_CMD) clean 73 cd .. 84 74 -
trunk/src/opengl/opengl32.cpp
r2660 r2689 1 /* $Id: opengl32.cpp,v 1. 3 2000-02-05 15:54:53 sandervlExp $ */1 /* $Id: opengl32.cpp,v 1.4 2000-02-09 08:50:54 jeroen Exp $ */ 2 2 /*****************************************************************************/ 3 3 /* */ … … 6 6 /*****************************************************************************/ 7 7 #define INCL_BASE 8 #include <os2.h>9 8 #include <os2wrap.h> 10 9 #include <misc.h> 11 10 #include <malloc.h> 12 11 #include <memory.h> 12 #include <float.h> 13 13 14 14 #include "pglos2.h" 15 15 #include "initterm.h" 16 16 17 HWND WIN32API WindowFromDC(HDC hdc); 18 HWND Win32ToOS2Handle(HWND hwnd); 17 HWND WIN32API WindowFromDC(HDC hdc); 18 HWND Win32ToOS2Handle(HWND hwnd); 19 HWND OS2ToWin32Handle(HWND hwnd); 20 LRESULT WIN32API SendMessageA(HWND,ULONG,WPARAM,LPARAM); 19 21 20 22 #define PFD_TYPE_RGBA 0 … … 580 582 hWnd=Win32ToOS2Handle(WindowFromDC(hdc)); 581 583 582 if(h dc)584 if(hWnd) 583 585 OS2pglSwapBuffers(hdc,hWnd); 584 586 585 return h dc!=NULL;587 return hWnd!=NULL; 586 588 } 587 589 … … 760 762 HGC WIN32API wglGetCurrentContext(void) 761 763 { 762 /* FIXME: parameter '0'! */763 return OS2pglGetCurrentContext(0);764 }765 766 HDC WIN32API wglGetCurrentDC(void)767 {768 /* FIXME: parameter '0'! */769 764 HWND hwnd; 770 765 PFDINFO *pfdi; 771 766 772 hwnd=OS2pglGetCurrentWindow(0); 767 hwnd=OS2ToWin32Handle(OS2pglGetCurrentWindow(WinQueryAnchorBlock(HWND_DESKTOP))); 768 769 pfdi=query_pfdi_by_hwnd(hwnd); 770 771 if(pfdi) 772 return pfdi->hgc; 773 774 return 0; 775 } 776 777 HDC WIN32API wglGetCurrentDC(void) 778 { 779 HWND hwnd; 780 PFDINFO *pfdi; 781 782 hwnd=OS2ToWin32Handle(OS2pglGetCurrentWindow(WinQueryAnchorBlock(HWND_DESKTOP))); 773 783 774 784 pfdi=query_pfdi_by_hwnd(hwnd); … … 1346 1356 { 1347 1357 OS2glFlush(); 1358 1359 dprintf(("OPENGL32: glFlush() complete\n")); 1348 1360 } 1349 1361 … … 3028 3040 /*****************************************************************************/ 3029 3041 /* */ 3042 /* As of yet unsupported gl functions */ 3043 /* */ 3044 /*****************************************************************************/ 3045 3046 void WIN32API glTexImage3D(GLenum target, 3047 GLint level, 3048 GLint component, 3049 GLsizei width, 3050 GLsizei height, 3051 GLsizei depth, 3052 GLint border, 3053 GLenum format, 3054 GLenum type, 3055 const GLvoid *pixels) 3056 { 3057 dprintf(("OPENGL32: glTexImage3D - not implemented\n")); 3058 } 3059 3060 /*****************************************************************************/ 3061 /* */ 3030 3062 /* Module Internal init and cleanup - called by initterm */ 3031 3063 /* */ … … 3037 3069 /* store them. All indexes returned are based upon this list! */ 3038 3070 dprintf(("OPENGL32: INIT\n")); 3071 3072 _control87(EM_UNDERFLOW,EM_UNDERFLOW); 3073 _control87(EM_OVERFLOW,EM_OVERFLOW); 3039 3074 3040 3075 DosCreateMutexSem(NULL,&hmtxPfdInfo,0,0); … … 3061 3096 pfdi_destroy_all(); 3062 3097 3063 if(global_visual_config_list)3064 free(global_visual_config_list);3065 3066 3098 DosCloseMutexSem(hmtxPfdInfo); 3067 3099 3100 _control87(0,EM_UNDERFLOW); 3101 _control87(0,EM_OVERFLOW); 3102 3068 3103 dprintf(("OPENGL32 TERM\n")); 3069 3104 } -
trunk/src/opengl/opengl32.def
r2660 r2689 1 ;/* $Id: opengl32.def,v 1. 3 2000-02-05 15:54:54 sandervlExp $ */1 ;/* $Id: opengl32.def,v 1.4 2000-02-09 08:50:54 jeroen Exp $ */ 2 2 LIBRARY OPENGL32 INITINSTANCE 3 3 … … 685 685 glTexImage1D=_glTexImage1D@32 @309 686 686 glTexImage2D=_glTexImage2D@36 @310 687 glTexImage3D=_glTexImage3D@40 @400 687 688 glTexParameterf=_glTexParameterf@12 @311 688 689 glTexParameterfv=_glTexParameterfv@12 @312
Note:
See TracChangeset
for help on using the changeset viewer.