VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/Graphics/Display/Mirror/driver.h@ 29966

Last change on this file since 29966 was 28800, checked in by vboxsync, 15 years ago

Automated rebranding to Oracle copyright/license strings via filemuncher

  • Property svn:eol-style set to native
File size: 4.5 KB
Line 
1/******************************Module*Header*******************************\
2*
3 * Copyright (C) 2006-2007 Oracle Corporation
4 *
5 * This file is part of VirtualBox Open Source Edition (OSE), as
6 * available from http://www.virtualbox.org. This file is free software;
7 * you can redistribute it and/or modify it under the terms of the GNU
8 * General Public License (GPL) as published by the Free Software
9 * Foundation, in version 2 as it comes in the "COPYING" file of the
10 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
11 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
12*/
13/*
14* Based in part on Microsoft DDK sample code
15*
16* *******************
17* * GDI SAMPLE CODE *
18* *******************
19*
20* Module Name: driver.h
21*
22* contains prototypes for the frame buffer driver.
23*
24* Copyright (c) 1992-1998 Microsoft Corporation
25\**************************************************************************/
26
27#define DBG 1
28
29#include "stddef.h"
30
31#include <stdarg.h>
32
33#include "windef.h"
34#include "wingdi.h"
35#include "winddi.h"
36#include "devioctl.h"
37#include "ntddvdeo.h"
38#include "debug.h"
39
40typedef struct _PDEV
41{
42 HANDLE hDriver; // Handle to \Device\Screen
43 HDEV hdevEng; // Engine's handle to PDEV
44 HSURF hsurfEng; // Engine's handle to surface
45//@todo Make work without palette
46 HPALETTE hpalDefault; // Handle to the default palette for device.
47 PBYTE pjScreen; // This is pointer to base screen address
48 ULONG cxScreen; // Visible screen width
49 ULONG cyScreen; // Visible screen height
50 POINTL ptlOrg; // Where this display is anchored in
51 // the virtual desktop.
52 ULONG ulMode; // Mode the mini-port driver is in.
53 LONG lDeltaScreen; // Distance from one scan to the next.
54 ULONG cScreenSize; // size of video memory, including
55 // offscreen memory.
56 PVOID pOffscreenList; // linked list of DCI offscreen surfaces.
57 FLONG flRed; // For bitfields device, Red Mask
58 FLONG flGreen; // For bitfields device, Green Mask
59 FLONG flBlue; // For bitfields device, Blue Mask
60 ULONG cPaletteShift; // number of bits the 8-8-8 palette must
61 // be shifted by to fit in the hardware
62 // palette.
63 ULONG ulBitCount; // # of bits per pel 8,16,24,32 are only supported.
64 POINTL ptlHotSpot; // adjustment for pointer hot spot
65 VIDEO_POINTER_CAPABILITIES PointerCapabilities; // HW pointer abilities
66 PVIDEO_POINTER_ATTRIBUTES pPointerAttributes; // hardware pointer attributes
67 DWORD cjPointerAttributes; // Size of buffer allocated
68 BOOL fHwCursorActive; // Are we currently using the hw cursor
69 PALETTEENTRY *pPal; // If this is pal managed, this is the pal
70 BOOL bSupportDCI; // Does the miniport support DCI?
71
72//@todo Make work without allocation
73 PVOID pvTmpBuffer; // ptr to MIRRSURF bits for screen surface
74} PDEV, *PPDEV;
75
76typedef struct _MIRRSURF {
77 PPDEV *pdev;
78 ULONG cx;
79 ULONG cy;
80 ULONG lDelta;
81 ULONG ulBitCount;
82 BOOL bIsScreen;
83
84} MIRRSURF, *PMIRRSURF;
85
86DWORD getAvailableModes(HANDLE, PVIDEO_MODE_INFORMATION *, DWORD *);
87BOOL bInitPDEV(PPDEV, PDEVMODEW, GDIINFO *, DEVINFO *);
88BOOL bInitSURF(PPDEV, BOOL);
89BOOL bInitPaletteInfo(PPDEV, DEVINFO *);
90BOOL bInitPointer(PPDEV, DEVINFO *);
91BOOL bInit256ColorPalette(PPDEV);
92VOID vDisablePalette(PPDEV);
93VOID vDisableSURF(PPDEV);
94
95#define MAX_CLUT_SIZE (sizeof(VIDEO_CLUT) + (sizeof(ULONG) * 256))
96
97//
98// Determines the size of the DriverExtra information in the DEVMODE
99// structure passed to and from the display driver.
100//
101
102#define DRIVER_EXTRA_SIZE 0
103
104#define DLL_NAME L"vrdpdd" // Name of the DLL in UNICODE
105#define STANDARD_DEBUG_PREFIX "vrdpdd: " // All debug output is prefixed
106#define ALLOC_TAG 'rvDD' // Four byte tag (characters in
107 // reverse order) used for memory
108 // allocations
109
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