diff options
author | Araq <rumpf_a@web.de> | 2012-09-29 08:06:43 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2012-09-29 08:06:43 +0200 |
commit | 3bcf9f4e53c8672b3763951274543e7cff6c35e5 (patch) | |
tree | c153c731f1874beabd2e8518662e32704e4707a5 /lib/wrappers/opengl/opengl.nim | |
parent | 95cf849954d44b1440d0bb0da0c3bed378e4f1ad (diff) | |
download | Nim-3bcf9f4e53c8672b3763951274543e7cff6c35e5.tar.gz |
opengl wrapper compiles under windows
Diffstat (limited to 'lib/wrappers/opengl/opengl.nim')
-rw-r--r-- | lib/wrappers/opengl/opengl.nim | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/wrappers/opengl/opengl.nim b/lib/wrappers/opengl/opengl.nim index 444f23fc1..dacdbd02c 100644 --- a/lib/wrappers/opengl/opengl.nim +++ b/lib/wrappers/opengl/opengl.nim @@ -9093,8 +9093,9 @@ proc glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN*(rc: GLuint, proc glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN*(rc: PGLuint, tc: PGLfloat, c: PGLfloat, n: PGLfloat, v: PGLfloat){.stdcall, importc, ogl.} # window support functions -when defined(windows): - proc wglGetProcAddress*(ProcName: cstring): Pointer{.stdcall, importc, wgl.} +when defined(windows): + when not defined(wglGetProcAddress): + proc wglGetProcAddress*(ProcName: cstring): Pointer{.stdcall, importc, wgl.} proc wglCopyContext*(p1: HGLRC, p2: HGLRC, p3: int): BOOL{.stdcall, importc, wgl.} proc wglCreateContext*(DC: HDC): HGLRC{.stdcall, importc, wgl.} proc wglCreateLayerContext*(p1: HDC, p2: int): HGLRC{.stdcall, importc, wgl.} @@ -9597,7 +9598,7 @@ when defined(windows): dwVisibleMask: DWORD dwDamageMask: DWORD - proc GetObjectType(h: int32): DWORD{.stdcall, dynlib: "gdi32", + proc GetObjectType(h: HDC): DWORD{.stdcall, dynlib: "gdi32", importc: "GetObjectType".} proc ChoosePixelFormat(para1: HDC, para2: ptr TPIXELFORMATDESCRIPTOR): int32{. stdcall, dynlib: "gdi32", importc: "ChoosePixelFormat".} @@ -9626,7 +9627,7 @@ when defined(windows): PFD_UNDERLAY_PLANE = int32(- 1) var PFDescriptor: TPixelFormatDescriptor - PixelFormat: int + PixelFormat: int32 AType: int32 PFDescriptor.nSize = SizeOf(PFDescriptor).int16 PFDescriptor.nVersion = 1'i16 |