DevVGA-SVGA3d-cocoa.h revision 07557d07616212d7ba6e7ab3059e85cb14633775
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync/** @file
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * VirtualBox OpenGL Cocoa Window System Helper Implementation.
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync */
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
2f0d866e126dd288169fed591c259c1c6b4016e5vboxsync/*
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * Copyright (C) 2014 Oracle Corporation
b2bc8de1367ae24e1b27b53921d0b32ee3df7acdvboxsync *
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * available from http://www.virtualbox.org. This file is free software;
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * you can redistribute it and/or modify it under the terms of the GNU
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * General Public License (GPL) as published by the Free Software
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync */
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
2f0d866e126dd288169fed591c259c1c6b4016e5vboxsync#ifndef __DevVGA_SVGA3d_cocoa_h
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync#define __DevVGA_SVGA3d_cocoa_h
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync#include <iprt/cdefs.h>
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync#include <VBox/VBoxCocoa.h>
43747b1f0bc8302a238fb35e55857a5e9aa1933dvboxsync#include <OpenGL/OpenGL.h>
43747b1f0bc8302a238fb35e55857a5e9aa1933dvboxsync
b2bc8de1367ae24e1b27b53921d0b32ee3df7acdvboxsyncRT_C_DECLS_BEGIN
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
2f0d866e126dd288169fed591c259c1c6b4016e5vboxsync#ifndef ___renderspu_cocoa_helper_h
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncADD_COCOA_NATIVE_REF(NSView);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncADD_COCOA_NATIVE_REF(NSOpenGLContext);
f5e53763b0a581b0299e98028c6c52192eb06785vboxsync#endif
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync#ifdef IN_VMSVGA3D
2f0d866e126dd288169fed591c259c1c6b4016e5vboxsync# define VMSVGA3D_DECL(type) DECLEXPORT(type)
2f0d866e126dd288169fed591c259c1c6b4016e5vboxsync#else
2f0d866e126dd288169fed591c259c1c6b4016e5vboxsync# define VMSVGA3D_DECL(type) DECLIMPORT(type)
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync#endif
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaCreateContext(NativeNSOpenGLContextRef *ppCtx, NativeNSOpenGLContextRef pSharedCtx,
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync bool fOtherProfile);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaDestroyContext(NativeNSOpenGLContextRef pCtx);
9b7ab382b3f9667e8847020e1e58f7143c4d2334vboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaCreateView(NativeNSViewRef *ppView, NativeNSViewRef pParentView);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaDestroyView(NativeNSViewRef pView);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaViewSetPosition(NativeNSViewRef pView, NativeNSViewRef pParentView, int x, int y);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaViewSetSize(NativeNSViewRef pView, int w, int h);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaViewMakeCurrentContext(NativeNSViewRef pView, NativeNSOpenGLContextRef pCtx);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncVMSVGA3D_DECL(void) vmsvga3dCocoaSwapBuffers(NativeNSViewRef pView, NativeNSOpenGLContextRef pCtx);
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsyncRT_C_DECLS_END
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync#endif /* !__DevVGA_SVGA3d_cocoa_h */
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync
016096e367cd20c3d3c3fd9a6650b55935c2e31dvboxsync