Mercurial > projects > dstep
comparison dstep/opengl/OpenGL.d @ 16:19885b43130e
Huge update, the bridge actually works now
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Sun, 03 Jan 2010 22:06:11 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
15:7ff919f595d5 | 16:19885b43130e |
---|---|
1 /** | |
2 * Copyright: Copyright (c) 2009 Jacob Carlborg. | |
3 * Authors: Jacob Carlborg | |
4 * Version: Initial created: Sep 24, 2009 | |
5 * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost Software License 1.0) | |
6 */ | |
7 module dstep.opengl.OpenGL; | |
8 | |
9 public: | |
10 | |
11 //import dstep.AvailabilityMacros; | |
12 import dstep.opengl.CGLCurrent; | |
13 import dstep.opengl.CGLTypes; | |
14 import dstep.opengl.gl; | |
15 | |
16 extern (C) | |
17 { | |
18 int CGLChoosePixelFormat (CGLPixelFormatAttribute* attribs, CGLPixelFormatObj* pix, GLint* npix); | |
19 int CGLDestroyPixelFormat (CGLPixelFormatObj pix); | |
20 int CGLDescribePixelFormat (CGLPixelFormatObj pix, int pix_num, int attrib, GLint* value); | |
21 void CGLReleasePixelFormat (CGLPixelFormatObj pix); | |
22 CGLPixelFormatObj CGLRetainPixelFormat (CGLPixelFormatObj pix); | |
23 uint CGLGetPixelFormatRetainCount (CGLPixelFormatObj pix); | |
24 int CGLQueryRendererInfo (uint display_mask, CGLRendererInfoObj* rend, GLint* nrend); | |
25 int CGLDestroyRendererInfo (CGLRendererInfoObj rend); | |
26 int CGLDescribeRenderer (CGLRendererInfoObj rend, int rend_num, int prop, GLint* value); | |
27 int CGLCreateContext (CGLPixelFormatObj pix, CGLContextObj share, CGLContextObj* ctx); | |
28 int CGLDestroyContext (CGLContextObj ctx); | |
29 int CGLCopyContext (CGLContextObj src, CGLContextObj dst, uint mask); | |
30 CGLContextObj CGLRetainContext (CGLContextObj ctx); | |
31 void CGLReleaseContext (CGLContextObj ctx); | |
32 uint CGLGetContextRetainCount (CGLContextObj ctx); | |
33 CGLPixelFormatObj CGLGetPixelFormat (CGLContextObj ctx); | |
34 int CGLCreatePBuffer (int width, int height, uint target, uint internalFormat, int max_level, CGLPBufferObj* pbuffer); | |
35 int CGLDestroyPBuffer (CGLPBufferObj pbuffer); | |
36 int CGLDescribePBuffer (CGLPBufferObj obj, GLsizei* width, GLsizei* height, GLenum* target, GLenum* internalFormat, GLint* mipmap); | |
37 int CGLTexImagePBuffer (CGLContextObj ctx, CGLPBufferObj pbuffer, uint source); | |
38 CGLPBufferObj CGLRetainPBuffer (CGLPBufferObj pbuffer); | |
39 void CGLReleasePBuffer (CGLPBufferObj pbuffer); | |
40 uint CGLGetPBufferRetainCount (CGLPBufferObj pbuffer); | |
41 int CGLSetOffScreen (CGLContextObj ctx, int width, int height, int rowbytes, void* baseaddr); | |
42 int CGLGetOffScreen (CGLContextObj ctx, GLsizei* width, GLsizei* height, GLint* rowbytes, void** baseaddr); | |
43 int CGLSetFullScreen (CGLContextObj ctx); | |
44 int CGLSetPBuffer (CGLContextObj ctx, CGLPBufferObj pbuffer, uint face, int level, int screen); | |
45 int CGLGetPBuffer (CGLContextObj ctx, CGLPBufferObj* pbuffer, GLenum* face, GLint* level, GLint* screen); | |
46 int CGLClearDrawable (CGLContextObj ctx); | |
47 int CGLFlushDrawable (CGLContextObj ctx); | |
48 int CGLEnable (CGLContextObj ctx, int pname); | |
49 int CGLDisable (CGLContextObj ctx, int pname); | |
50 int CGLIsEnabled (CGLContextObj ctx, int pname, GLint* enable); | |
51 int CGLSetParameter (CGLContextObj ctx, int pname, GLint* params); | |
52 int CGLGetParameter (CGLContextObj ctx, int pname, GLint* params); | |
53 int CGLSetVirtualScreen (CGLContextObj ctx, int screen); | |
54 int CGLGetVirtualScreen (CGLContextObj ctx, GLint* screen); | |
55 int CGLSetOption (int pname, int param); | |
56 int CGLGetOption (int pname, GLint* param); | |
57 int CGLLockContext (CGLContextObj ctx); | |
58 int CGLUnlockContext (CGLContextObj ctx); | |
59 void CGLGetVersion (GLint* majorvers, GLint* minorvers); | |
60 char* CGLErrorString (int error); | |
61 } |