[VGA_NEW] Add CMakeLists.txt and fix build
authorTimo Kreuzer <timo.kreuzer@reactos.org>
Sun, 1 Oct 2017 10:17:30 +0000 (10:17 +0000)
committerTimo Kreuzer <timo.kreuzer@reactos.org>
Sun, 1 Oct 2017 10:17:30 +0000 (10:17 +0000)
svn path=/trunk/; revision=76014

reactos/win32ss/drivers/displays/vga_new/CMakeLists.txt [new file with mode: 0644]
reactos/win32ss/drivers/displays/vga_new/enable.c
reactos/win32ss/drivers/displays/vga_new/palette.c
reactos/win32ss/drivers/displays/vga_new/screen.c

diff --git a/reactos/win32ss/drivers/displays/vga_new/CMakeLists.txt b/reactos/win32ss/drivers/displays/vga_new/CMakeLists.txt
new file mode 100644 (file)
index 0000000..3055f28
--- /dev/null
@@ -0,0 +1,18 @@
+
+list(APPEND SOURCE
+    enable.c
+    debug.c
+    enable.c
+    palette.c
+    screen.c)
+
+add_library(vgaddi SHARED
+    ${SOURCE}
+    vga_new.rc)
+
+set_module_type(vgaddi kerneldll ENTRYPOINT DrvEnableDriver 12)
+
+add_importlibs(vgaddi win32k)
+target_link_libraries(vgaddi libcntpr)
+add_dependencies(vgaddi psdk)
+add_cd_file(TARGET vgaddi DESTINATION reactos/system32 FOR all)
index 7c7c460..08a8d14 100644 (file)
@@ -48,7 +48,7 @@ static DRVFN gadrvfn[] =
 *
 \**************************************************************************/
 
-BOOL DrvEnableDriver(
+BOOL APIENTRY DrvEnableDriver(
 ULONG iEngineVersion,
 ULONG cj,
 PDRVENABLEDATA pded)
@@ -88,7 +88,7 @@ PDRVENABLEDATA pded)
 *
 \**************************************************************************/
 
-DHPDEV DrvEnablePDEV(
+DHPDEV APIENTRY DrvEnablePDEV(
 DEVMODEW   *pDevmode,       // Pointer to DEVMODE
 PWSTR       pwszLogAddress, // Logical address
 ULONG       cPatterns,      // number of patterns
@@ -176,7 +176,7 @@ error_free:
 *
 \**************************************************************************/
 
-VOID DrvCompletePDEV(
+VOID APIENTRY DrvCompletePDEV(
 DHPDEV dhpdev,
 HDEV  hdev)
 {
@@ -191,7 +191,7 @@ HDEV  hdev)
 *
 \**************************************************************************/
 
-VOID DrvDisablePDEV(
+VOID APIENTRY DrvDisablePDEV(
 DHPDEV dhpdev)
 {
     vDisablePalette((PPDEV) dhpdev);
@@ -207,14 +207,17 @@ DHPDEV dhpdev)
 *
 \**************************************************************************/
 
-HSURF DrvEnableSurface(
+HSURF APIENTRY DrvEnableSurface(
 DHPDEV dhpdev)
 {
     PPDEV ppdev;
     HSURF hsurf;
     SIZEL sizl;
     ULONG ulBitmapType;
+#if 0
     FLONG flHooks;
+#endif
+    HSURF hSurfBitmap;
 
     // Create engine bitmap around frame buffer.
 
@@ -290,7 +293,6 @@ DHPDEV dhpdev)
 // eVb: 1.5 [END]
     ppdev->hsurfEng = hsurf;
 // eVb: 1.4 [VGARISC Change] - Allocate 4BPP DIB that will store GDI drawing
-    HSURF hSurfBitmap;
     hSurfBitmap = (HSURF)EngCreateBitmap(sizl, 0, ulBitmapType, 0, NULL);
     if (hSurfBitmap == (HSURF) 0)
     {
@@ -328,7 +330,7 @@ DHPDEV dhpdev)
 *
 \**************************************************************************/
 
-VOID DrvDisableSurface(
+VOID APIENTRY DrvDisableSurface(
 DHPDEV dhpdev)
 {
     EngDeleteSurface(((PPDEV) dhpdev)->hsurfEng);
@@ -343,7 +345,7 @@ DHPDEV dhpdev)
 *
 \**************************************************************************/
 
-BOOL DrvAssertMode(
+BOOL APIENTRY DrvAssertMode(
 DHPDEV dhpdev,
 BOOL bEnable)
 {
@@ -415,7 +417,7 @@ BOOL bEnable)
 *
 \**************************************************************************/
 
-ULONG DrvGetModes(
+ULONG APIENTRY DrvGetModes(
 HANDLE hDriver,
 ULONG cjSize,
 DEVMODEW *pdm)
index d73499e..27499a6 100644 (file)
@@ -288,7 +288,7 @@ BOOL bInit256ColorPalette(PPDEV ppdev)
 *
 \**************************************************************************/
 
-BOOL DrvSetPalette(
+BOOL APIENTRY DrvSetPalette(
 DHPDEV  dhpdev,
 PALOBJ* ppalo,
 FLONG   fl,
index 5702319..e69317a 100644 (file)
@@ -114,7 +114,7 @@ GDIINFO gaulCap = {
 \**************************************************************************/
 
 // Values for the internal, EGA-compatible palette.
-
+#if 0
 static WORD PaletteBuffer[] = {
 
         16, // 16 entries
@@ -156,6 +156,7 @@ static BYTE ColorBuffer[] = {
                 0x00, 0x3F, 0x3F, 0x00, // bright ScanLinesan
                 0x3F, 0x3F, 0x3F, 0x00  // bright white
 };
+#endif
 // eVb: 2.3 [END]
 /******************************Public*Routine******************************\
 * bInitSURF
@@ -330,8 +331,10 @@ DEVINFO *pDevInfo)
 {
     ULONG cModes;
     PVIDEO_MODE_INFORMATION pVideoBuffer, pVideoModeSelected, pVideoTemp;
+#if 0
     VIDEO_COLOR_CAPABILITIES colorCapabilities;
     ULONG ulTemp;
+#endif
     BOOL bSelectDefault;
     ULONG cbModeSize;