VBoxCrOpenGLSvc.h revision 0c0e78bbdcbeec81f856e8aa1097a9504c16bb1c
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync/** @file
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * OpenGL:
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * Common header for host service and guest clients.
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync */
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync/*
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * Copyright (C) 2006-2007 Oracle Corporation
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync *
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * available from http://www.virtualbox.org. This file is free software;
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * you can redistribute it and/or modify it under the terms of the GNU
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * General Public License (GPL) as published by the Free Software
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync *
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * The contents of this file may alternatively be used under the terms
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * of the Common Development and Distribution License Version 1.0
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * VirtualBox OSE distribution, in which case the provisions of the
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * CDDL are applicable instead of those of the GPL.
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync *
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * You may elect to license modified versions of this file under the
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync * terms and conditions of either the GPL or the CDDL or both.
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync */
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#ifndef ___VBox_HostService_VBoxCrOpenGLSvc_h
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define ___VBox_HostService_VBoxCrOpenGLSvc_h
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#include <VBox/types.h>
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#include <VBox/VMMDev.h>
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#include <VBox/VBoxGuest2.h>
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#include <VBox/hgcmsvc.h>
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync/* crOpenGL host functions */
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_HOST_FN_SET_CONSOLE (1)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_HOST_FN_SET_VISIBLE_REGION (5)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_HOST_FN_SET_VM (7)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_HOST_FN_SCREEN_CHANGED (8)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync/* crOpenGL guest functions */
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_GUEST_FN_WRITE (2)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_GUEST_FN_READ (3)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_GUEST_FN_WRITE_READ (4)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_GUEST_FN_SET_VERSION (6)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_GUEST_FN_INJECT (9)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync/* Parameters count */
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_CPARMS_SET_CONSOLE (1)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_CPARMS_SET_VM (1)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_CPARMS_SET_VISIBLE_REGION (2)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_CPARMS_WRITE (1)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_CPARMS_READ (2)
ae3b356f74cf4942fdd85f8b0544af62f8161656vboxsync#define SHCRGL_CPARMS_WRITE_READ (3)
#define SHCRGL_CPARMS_SET_VERSION (2)
#define SHCRGL_CPARMS_SCREEN_CHANGED (1)
#define SHCRGL_CPARMS_INJECT (2)
/**
* SHCRGL_GUEST_FN_WRITE
*/
/** GUEST_FN_WRITE Parameters structure. */
typedef struct
{
VBoxGuestHGCMCallInfo hdr;
/** pointer, in
* Data buffer
*/
HGCMFunctionParameter pBuffer;
} CRVBOXHGCMWRITE;
/** GUEST_FN_READ Parameters structure. */
typedef struct
{
VBoxGuestHGCMCallInfo hdr;
/** pointer, in/out
* Data buffer
*/
HGCMFunctionParameter pBuffer;
/** 32bit, out
* Count of bytes written to buffer
*/
HGCMFunctionParameter cbBuffer;
} CRVBOXHGCMREAD;
/** GUEST_FN_WRITE_READ Parameters structure. */
typedef struct
{
VBoxGuestHGCMCallInfo hdr;
/** pointer, in
* Data buffer
*/
HGCMFunctionParameter pBuffer;
/** pointer, out
* Writeback buffer
*/
HGCMFunctionParameter pWriteback;
/** 32bit, out
* Count of bytes written to writeback buffer
*/
HGCMFunctionParameter cbWriteback;
} CRVBOXHGCMWRITEREAD;
/** GUEST_FN_SET_VERSION Parameters structure. */
typedef struct
{
VBoxGuestHGCMCallInfo hdr;
/** 32bit, in
* Major version
*/
HGCMFunctionParameter vMajor;
/** 32bit, in
* Minor version
*/
HGCMFunctionParameter vMinor;
} CRVBOXHGCMSETVERSION;
/** GUEST_FN_INJECT Parameters structure. */
typedef struct
{
VBoxGuestHGCMCallInfo hdr;
/** 32bit, in
* ClientID to inject commands buffer for
*/
HGCMFunctionParameter u32ClientID;
/** pointer, in
* Data buffer
*/
HGCMFunctionParameter pBuffer;
} CRVBOXHGCMINJECT;
#endif