VirtualBox

source: vbox/trunk/src/VBox/HostServices/SharedOpenGL/render/renderspu_cocoa_helper.h@ 34079

Last change on this file since 34079 was 30126, checked in by vboxsync, 15 years ago

OpenGL-OSX: use new VBoxCocoa.h include file

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.9 KB
Line 
1/** @file
2 *
3 * VirtualBox OpenGL Cocoa Window System Helper definition
4 */
5
6/*
7 * Copyright (C) 2009 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17
18#ifndef __renderspu_cocoa_helper_h
19#define __renderspu_cocoa_helper_h
20
21#include <VBox/VBoxCocoa.h>
22#include <iprt/cdefs.h>
23#include <OpenGL/OpenGL.h>
24
25RT_C_DECLS_BEGIN
26
27ADD_COCOA_NATIVE_REF(NSView);
28ADD_COCOA_NATIVE_REF(NSOpenGLContext);
29
30/* OpenGL context management */
31void cocoaGLCtxCreate(NativeNSOpenGLContextRef *ppCtx, GLbitfield fVisParams);
32void cocoaGLCtxDestroy(NativeNSOpenGLContextRef pCtx);
33
34/* View management */
35void cocoaViewCreate(NativeNSViewRef *ppView, NativeNSViewRef pParentView, GLbitfield fVisParams);
36void cocoaViewReparent(NativeNSViewRef pView, NativeNSViewRef pParentView);
37void cocoaViewDestroy(NativeNSViewRef pView);
38void cocoaViewDisplay(NativeNSViewRef pView);
39void cocoaViewShow(NativeNSViewRef pView, GLboolean fShowIt);
40void cocoaViewSetPosition(NativeNSViewRef pView, NativeNSViewRef pParentView, int x, int y);
41void cocoaViewSetSize(NativeNSViewRef pView, int w, int h);
42void cocoaViewGetGeometry(NativeNSViewRef pView, int *pX, int *pY, int *pW, int *pH);
43
44void cocoaViewMakeCurrentContext(NativeNSViewRef pView, NativeNSOpenGLContextRef pCtx);
45void cocoaViewSetVisibleRegion(NativeNSViewRef pView, GLint cRects, GLint* paRects);
46
47/* OpenGL wrapper */
48void cocoaFlush(void);
49void cocoaFinish(void);
50void cocoaBindFramebufferEXT(GLenum target, GLuint framebuffer);
51
52RT_C_DECLS_END
53
54#endif /* __renderspu_cocoa_helper_h */
55
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette