mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-01-28 22:04:43 -08:00
Rebase against ab7756619c1b16c761618a68d1b6a06ad437cbe8.
This commit is contained in:
parent
6260ab9bce
commit
01adefa75c
@ -1,119 +0,0 @@
|
||||
From 9508597f0940703a95edd8fde9584ef11a9a1e1a Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sun, 3 Apr 2016 18:22:29 +0200
|
||||
Subject: [PATCH] iccvid: Fix calculation of stride and size.
|
||||
|
||||
---
|
||||
dlls/iccvid/iccvid.c | 10 ++++++---
|
||||
dlls/msvfw32/tests/msvfw.c | 45 ++++++++++++++++++++++++++++++++++++++
|
||||
2 files changed, 52 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/dlls/iccvid/iccvid.c b/dlls/iccvid/iccvid.c
|
||||
index 89d282ba78..3977d95a41 100644
|
||||
--- a/dlls/iccvid/iccvid.c
|
||||
+++ b/dlls/iccvid/iccvid.c
|
||||
@@ -169,6 +169,10 @@ int x, y;
|
||||
}
|
||||
}
|
||||
|
||||
+static inline int get_stride(int width, int depth)
|
||||
+{
|
||||
+ return ((depth * width + 31) >> 3) & ~3;
|
||||
+}
|
||||
|
||||
/* ------------------------------------------------------------------------ */
|
||||
static void cvid_v4_32(unsigned char *frm, unsigned char *limit, int stride, BOOL inverted,
|
||||
@@ -450,7 +454,7 @@ static void decode_cinepak(cinepak_info *cvinfo, unsigned char *buf, int size,
|
||||
break;
|
||||
}
|
||||
|
||||
- frm_stride = out_width * bpp;
|
||||
+ frm_stride = get_stride(out_width, bpp * 8);
|
||||
frm_ptr = output;
|
||||
|
||||
if(frame.length != size)
|
||||
@@ -835,9 +839,9 @@ static LRESULT ICCVID_DecompressGetFormat( ICCVID_Info *info, LPBITMAPINFO in, L
|
||||
if( out )
|
||||
{
|
||||
memcpy( out, in, size );
|
||||
+ out->bmiHeader.biBitCount = 24;
|
||||
out->bmiHeader.biCompression = BI_RGB;
|
||||
- out->bmiHeader.biSizeImage = in->bmiHeader.biHeight
|
||||
- * in->bmiHeader.biWidth *4;
|
||||
+ out->bmiHeader.biSizeImage = get_stride(in->bmiHeader.biWidth, 24) * in->bmiHeader.biHeight;
|
||||
return ICERR_OK;
|
||||
}
|
||||
return size;
|
||||
diff --git a/dlls/msvfw32/tests/msvfw.c b/dlls/msvfw32/tests/msvfw.c
|
||||
index 406a35b8f1..42f148230e 100644
|
||||
--- a/dlls/msvfw32/tests/msvfw.c
|
||||
+++ b/dlls/msvfw32/tests/msvfw.c
|
||||
@@ -25,6 +25,11 @@
|
||||
|
||||
#include "wine/test.h"
|
||||
|
||||
+static inline int get_stride(int width, int depth)
|
||||
+{
|
||||
+ return ((depth * width + 31) >> 3) & ~3;
|
||||
+}
|
||||
+
|
||||
static void test_OpenCase(void)
|
||||
{
|
||||
HIC h;
|
||||
@@ -88,6 +93,7 @@ static void test_Locate(void)
|
||||
{
|
||||
static BITMAPINFOHEADER bi = {sizeof(BITMAPINFOHEADER),32,8, 1,8, BI_RLE8, 0,100000,100000, 0,0};
|
||||
static BITMAPINFOHEADER bo = {sizeof(BITMAPINFOHEADER),32,8, 1,8, BI_RGB, 0,100000,100000, 0,0};
|
||||
+ BITMAPINFOHEADER tmp = {sizeof(BITMAPINFOHEADER)};
|
||||
HIC h;
|
||||
DWORD err;
|
||||
|
||||
@@ -123,6 +129,45 @@ static void test_Locate(void)
|
||||
ok(err == ICERR_OK, "Query cvid->RGB32 height<0: %d\n", err);
|
||||
bo.biHeight = -bo.biHeight;
|
||||
|
||||
+ bi.biWidth = 17;
|
||||
+
|
||||
+ bi.biBitCount = 8;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query cvid output format: %d\n", err);
|
||||
+ ok(tmp.biBitCount == 24, "Expected 24 bit, got %d bit\n", tmp.biBitCount);
|
||||
+ ok(tmp.biSizeImage == get_stride(17, 24) * 8, "Expected size %d, got %d\n",
|
||||
+ get_stride(17, 24) * 8, tmp.biSizeImage);
|
||||
+
|
||||
+ bi.biBitCount = 15;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query cvid output format: %d\n", err);
|
||||
+ ok(tmp.biBitCount == 24, "Expected 24 bit, got %d bit\n", tmp.biBitCount);
|
||||
+ ok(tmp.biSizeImage == get_stride(17, 24) * 8, "Expected size %d, got %d\n",
|
||||
+ get_stride(17, 24) * 8, tmp.biSizeImage);
|
||||
+
|
||||
+ bi.biBitCount = 16;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query cvid output format: %d\n", err);
|
||||
+ ok(tmp.biBitCount == 24, "Expected 24 bit, got %d bit\n", tmp.biBitCount);
|
||||
+ ok(tmp.biSizeImage == get_stride(17, 24) * 8, "Expected size %d, got %d\n",
|
||||
+ get_stride(17, 24) * 8, tmp.biSizeImage);
|
||||
+
|
||||
+ bi.biBitCount = 24;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query cvid output format: %d\n", err);
|
||||
+ ok(tmp.biBitCount == 24, "Expected 24 bit, got %d bit\n", tmp.biBitCount);
|
||||
+ ok(tmp.biSizeImage == get_stride(17, 24) * 8, "Expected size %d, got %d\n",
|
||||
+ get_stride(17, 24) * 8, tmp.biSizeImage);
|
||||
+
|
||||
+ bi.biBitCount = 32;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query cvid output format: %d\n", err);
|
||||
+ ok(tmp.biBitCount == 24, "Expected 24 bit, got %d bit\n", tmp.biBitCount);
|
||||
+ ok(tmp.biSizeImage == get_stride(17, 24) * 8, "Expected size %d, got %d\n",
|
||||
+ get_stride(17, 24) * 8, tmp.biSizeImage);
|
||||
+
|
||||
+ bi.biWidth = 32;
|
||||
+
|
||||
ok(ICClose(h) == ICERR_OK,"ICClose failed\n");
|
||||
|
||||
bo.biBitCount = bi.biBitCount = 8;
|
||||
--
|
||||
2.18.0
|
||||
|
@ -1,190 +0,0 @@
|
||||
From ef25f64580a12fba30413f34c1a9c72e31089e29 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sat, 2 Apr 2016 22:15:37 +0200
|
||||
Subject: msvidc32: Add support for converting 16 bit depth to 24 bit.
|
||||
|
||||
---
|
||||
dlls/msvfw32/tests/msvfw.c | 5 +++
|
||||
dlls/msvidc32/msvideo1.c | 91 ++++++++++++++++++++++++++++++++++++++++------
|
||||
2 files changed, 84 insertions(+), 12 deletions(-)
|
||||
|
||||
diff --git a/dlls/msvfw32/tests/msvfw.c b/dlls/msvfw32/tests/msvfw.c
|
||||
index 125cac5..66956aa 100644
|
||||
--- a/dlls/msvfw32/tests/msvfw.c
|
||||
+++ b/dlls/msvfw32/tests/msvfw.c
|
||||
@@ -202,6 +202,11 @@ static void test_Locate(void)
|
||||
todo_wine ok(err == ICERR_OK, "Query MSVC->RGB16 height<0: %d\n", err);
|
||||
bo.biHeight = -bo.biHeight;
|
||||
|
||||
+ bo.biBitCount = 24;
|
||||
+ err = ICDecompressQuery(h, &bi, &bo);
|
||||
+ ok(err == ICERR_OK, "Query MSVC 16->24: %d\n", err);
|
||||
+ bo.biBitCount = 16;
|
||||
+
|
||||
bi.biCompression = mmioFOURCC('m','s','v','c');
|
||||
err = ICDecompressQuery(h, &bi, &bo);
|
||||
ok(err == ICERR_BADFORMAT, "Query msvc->RGB16: %d\n", err);
|
||||
diff --git a/dlls/msvidc32/msvideo1.c b/dlls/msvidc32/msvideo1.c
|
||||
index b3faaf6..ab7cc3e 100644
|
||||
--- a/dlls/msvidc32/msvideo1.c
|
||||
+++ b/dlls/msvidc32/msvideo1.c
|
||||
@@ -67,7 +67,7 @@ typedef BYTE uint8_t;
|
||||
|
||||
typedef struct Msvideo1Context {
|
||||
DWORD dwMagic;
|
||||
- BOOL mode_8bit; /* if it's not 8-bit, it's 16-bit */
|
||||
+ int depth;
|
||||
} Msvideo1Context;
|
||||
|
||||
static void
|
||||
@@ -327,8 +327,15 @@ CRAM_DecompressQuery( Msvideo1Context *info, LPBITMAPINFO in, LPBITMAPINFO out )
|
||||
TRACE("out->bpp = %d\n", out->bmiHeader.biBitCount );
|
||||
TRACE("out->height = %d\n", out->bmiHeader.biHeight );
|
||||
TRACE("out->width = %d\n", out->bmiHeader.biWidth );
|
||||
- if(( in->bmiHeader.biBitCount != out->bmiHeader.biBitCount ) ||
|
||||
- ( in->bmiHeader.biPlanes != out->bmiHeader.biPlanes ) ||
|
||||
+
|
||||
+ if ((in->bmiHeader.biBitCount != out->bmiHeader.biBitCount) &&
|
||||
+ (in->bmiHeader.biBitCount != 16 || out->bmiHeader.biBitCount != 24))
|
||||
+ {
|
||||
+ TRACE("incompatible depth requested\n");
|
||||
+ return ICERR_BADFORMAT;
|
||||
+ }
|
||||
+
|
||||
+ if(( in->bmiHeader.biPlanes != out->bmiHeader.biPlanes ) ||
|
||||
( in->bmiHeader.biHeight != out->bmiHeader.biHeight ) ||
|
||||
( in->bmiHeader.biWidth != out->bmiHeader.biWidth ))
|
||||
{
|
||||
@@ -376,21 +383,52 @@ static LRESULT CRAM_DecompressBegin( Msvideo1Context *info, LPBITMAPINFO in, LPB
|
||||
|
||||
TRACE("bitmap is %d bpp\n", in->bmiHeader.biBitCount);
|
||||
if( in->bmiHeader.biBitCount == 8 )
|
||||
- info->mode_8bit = TRUE;
|
||||
+ info->depth = 8;
|
||||
else if( in->bmiHeader.biBitCount == 16 )
|
||||
- info->mode_8bit = FALSE;
|
||||
+ info->depth = 16;
|
||||
else
|
||||
{
|
||||
- info->mode_8bit = FALSE;
|
||||
+ info->depth = 0;
|
||||
FIXME("Unsupported output format %i\n", in->bmiHeader.biBitCount);
|
||||
}
|
||||
|
||||
return ICERR_OK;
|
||||
}
|
||||
|
||||
+static void convert_depth(char *input, int depth_in, char *output, BITMAPINFOHEADER *out_hdr)
|
||||
+{
|
||||
+ int x, y;
|
||||
+
|
||||
+ if (depth_in == 16 && out_hdr->biBitCount == 24)
|
||||
+ {
|
||||
+ static const unsigned char convert_5to8[] =
|
||||
+ {
|
||||
+ 0x00, 0x08, 0x10, 0x19, 0x21, 0x29, 0x31, 0x3a,
|
||||
+ 0x42, 0x4a, 0x52, 0x5a, 0x63, 0x6b, 0x73, 0x7b,
|
||||
+ 0x84, 0x8c, 0x94, 0x9c, 0xa5, 0xad, 0xb5, 0xbd,
|
||||
+ 0xc5, 0xce, 0xd6, 0xde, 0xe6, 0xef, 0xf7, 0xff,
|
||||
+ };
|
||||
+
|
||||
+ WORD *src = (WORD *)input;
|
||||
+ for (y = 0; y < out_hdr->biHeight; y++)
|
||||
+ {
|
||||
+ for (x = 0; x < out_hdr->biWidth; x++)
|
||||
+ {
|
||||
+ WORD pixel = *src++;
|
||||
+ *output++ = convert_5to8[(pixel & 0x7c00u) >> 10];
|
||||
+ *output++ = convert_5to8[(pixel & 0x03e0u) >> 5];
|
||||
+ *output++ = convert_5to8[(pixel & 0x001fu)];
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+ else
|
||||
+ FIXME("Conversion from %d to %d bit unimplemented\n", depth_in, out_hdr->biBitCount);
|
||||
+}
|
||||
+
|
||||
static LRESULT CRAM_Decompress( Msvideo1Context *info, ICDECOMPRESS *icd, DWORD size )
|
||||
{
|
||||
LONG width, height, stride, sz;
|
||||
+ void *output;
|
||||
|
||||
TRACE("ICM_DECOMPRESS %p %p %d\n", info, icd, size);
|
||||
|
||||
@@ -404,15 +442,29 @@ static LRESULT CRAM_Decompress( Msvideo1Context *info, ICDECOMPRESS *icd, DWORD
|
||||
stride = width; /* in bytes or 16bit words */
|
||||
sz = icd->lpbiInput->biSizeImage;
|
||||
|
||||
- if (info->mode_8bit)
|
||||
+ output = icd->lpOutput;
|
||||
+
|
||||
+ if (icd->lpbiOutput->biBitCount != info->depth)
|
||||
+ {
|
||||
+ output = HeapAlloc(GetProcessHeap(), 0, icd->lpbiOutput->biWidth * icd->lpbiOutput->biHeight * info->depth / 8);
|
||||
+ if (!output) return ICERR_MEMORY;
|
||||
+ }
|
||||
+
|
||||
+ if (info->depth == 8)
|
||||
{
|
||||
msvideo1_decode_8bit( width, height, icd->lpInput, sz,
|
||||
- icd->lpOutput, stride);
|
||||
+ output, stride );
|
||||
}
|
||||
else
|
||||
{
|
||||
msvideo1_decode_16bit( width, height, icd->lpInput, sz,
|
||||
- icd->lpOutput, stride);
|
||||
+ output, stride );
|
||||
+ }
|
||||
+
|
||||
+ if (icd->lpbiOutput->biBitCount != info->depth)
|
||||
+ {
|
||||
+ convert_depth(output, info->depth, icd->lpOutput, icd->lpbiOutput);
|
||||
+ HeapFree(GetProcessHeap(), 0, output);
|
||||
}
|
||||
|
||||
return ICERR_OK;
|
||||
@@ -421,6 +473,7 @@ static LRESULT CRAM_Decompress( Msvideo1Context *info, ICDECOMPRESS *icd, DWORD
|
||||
static LRESULT CRAM_DecompressEx( Msvideo1Context *info, ICDECOMPRESSEX *icd, DWORD size )
|
||||
{
|
||||
LONG width, height, stride, sz;
|
||||
+ void *output;
|
||||
|
||||
TRACE("ICM_DECOMPRESSEX %p %p %d\n", info, icd, size);
|
||||
|
||||
@@ -434,15 +487,29 @@ static LRESULT CRAM_DecompressEx( Msvideo1Context *info, ICDECOMPRESSEX *icd, DW
|
||||
stride = width;
|
||||
sz = icd->lpbiSrc->biSizeImage;
|
||||
|
||||
- if (info->mode_8bit)
|
||||
+ output = icd->lpDst;
|
||||
+
|
||||
+ if (icd->lpbiDst->biBitCount != info->depth)
|
||||
+ {
|
||||
+ output = HeapAlloc(GetProcessHeap(), 0, icd->lpbiDst->biWidth * icd->lpbiDst->biHeight * info->depth / 8);
|
||||
+ if (!output) return ICERR_MEMORY;
|
||||
+ }
|
||||
+
|
||||
+ if (info->depth == 8)
|
||||
{
|
||||
msvideo1_decode_8bit( width, height, icd->lpSrc, sz,
|
||||
- icd->lpDst, stride);
|
||||
+ output, stride );
|
||||
}
|
||||
else
|
||||
{
|
||||
msvideo1_decode_16bit( width, height, icd->lpSrc, sz,
|
||||
- icd->lpDst, stride);
|
||||
+ output, stride );
|
||||
+ }
|
||||
+
|
||||
+ if (icd->lpbiDst->biBitCount != info->depth)
|
||||
+ {
|
||||
+ convert_depth(output, info->depth, icd->lpDst, icd->lpbiDst);
|
||||
+ HeapFree(GetProcessHeap(), 0, output);
|
||||
}
|
||||
|
||||
return ICERR_OK;
|
||||
--
|
||||
2.7.1
|
||||
|
@ -1,175 +0,0 @@
|
||||
From 5d4bb7073d6674407a0a677732805e4d24988f24 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Sun, 3 Apr 2016 19:10:42 +0200
|
||||
Subject: msvidc32: Fix calculation of stride and size.
|
||||
|
||||
---
|
||||
dlls/msvfw32/tests/msvfw.c | 39 +++++++++++++++++++++++++++++++++++++++
|
||||
dlls/msvidc32/msvideo1.c | 34 +++++++++++++++++++++++++---------
|
||||
2 files changed, 64 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/dlls/msvfw32/tests/msvfw.c b/dlls/msvfw32/tests/msvfw.c
|
||||
index b546150..03ebaa7 100644
|
||||
--- a/dlls/msvfw32/tests/msvfw.c
|
||||
+++ b/dlls/msvfw32/tests/msvfw.c
|
||||
@@ -252,6 +252,45 @@ static void test_Locate(void)
|
||||
ok(err == ICERR_OK, "Query MSVC 16->24: %d\n", err);
|
||||
bo.biBitCount = 16;
|
||||
|
||||
+ bi.biWidth = 553;
|
||||
+
|
||||
+ bi.biBitCount = 8;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query MSVC output format: %d\n", err);
|
||||
+ ok(tmp.biBitCount == 8, "Expected 8 bit, got %d bit\n", tmp.biBitCount);
|
||||
+ ok(tmp.biWidth == 552, "Expected width 552, got %d\n", tmp.biWidth);
|
||||
+ ok(tmp.biSizeImage == get_stride(552, 8) * 8, "Expected size %d, got %d\n",
|
||||
+ get_stride(552, 8) * 8, tmp.biSizeImage);
|
||||
+
|
||||
+ bi.biBitCount = 15;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_BADFORMAT, "Query MSVC output format: %d\n", err);
|
||||
+
|
||||
+ bi.biBitCount = 16;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query MSVC output format: %d\n", err);
|
||||
+ ok(tmp.biBitCount == 16, "Expected 16 bit, got %d bit\n", tmp.biBitCount);
|
||||
+ ok(tmp.biWidth == 552, "Expected width 552, got %d\n", tmp.biWidth);
|
||||
+ ok(tmp.biSizeImage == get_stride(552, 16) * 8, "Expected size %d, got %d\n",
|
||||
+ get_stride(552, 16) * 8, tmp.biSizeImage);
|
||||
+
|
||||
+ bi.biBitCount = 24;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_BADFORMAT, "Query MSVC output format: %d\n", err);
|
||||
+
|
||||
+ bi.biBitCount = 32;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_BADFORMAT, "Query MSVC output format: %d\n", err);
|
||||
+
|
||||
+ bi.biHeight = 17;
|
||||
+ bi.biBitCount = 8;
|
||||
+ err = ICDecompressGetFormat(h, &bi, &tmp);
|
||||
+ ok(err == ICERR_OK, "Query MSVC output format: %d\n", err);
|
||||
+ ok(tmp.biHeight == 16, "Expected height 16, got %d\n", tmp.biHeight);
|
||||
+ bi.biHeight = 8;
|
||||
+
|
||||
+ bi.biWidth = 32;
|
||||
+
|
||||
bi.biCompression = mmioFOURCC('m','s','v','c');
|
||||
err = ICDecompressQuery(h, &bi, &bo);
|
||||
ok(err == ICERR_BADFORMAT, "Query msvc->RGB16: %d\n", err);
|
||||
diff --git a/dlls/msvidc32/msvideo1.c b/dlls/msvidc32/msvideo1.c
|
||||
index ab7cc3e..b999b52 100644
|
||||
--- a/dlls/msvidc32/msvideo1.c
|
||||
+++ b/dlls/msvidc32/msvideo1.c
|
||||
@@ -70,6 +70,11 @@ typedef struct Msvideo1Context {
|
||||
int depth;
|
||||
} Msvideo1Context;
|
||||
|
||||
+static inline int get_stride(int width, int depth)
|
||||
+{
|
||||
+ return ((depth * width + 31) >> 3) & ~3;
|
||||
+}
|
||||
+
|
||||
static void
|
||||
msvideo1_decode_8bit( int width, int height, const unsigned char *buf, int buf_size,
|
||||
unsigned char *pixels, int stride)
|
||||
@@ -362,12 +367,17 @@ CRAM_DecompressGetFormat( Msvideo1Context *info, LPBITMAPINFO in, LPBITMAPINFO o
|
||||
if (in->bmiHeader.biBitCount <= 8)
|
||||
size += in->bmiHeader.biClrUsed * sizeof(RGBQUAD);
|
||||
|
||||
+ if (in->bmiHeader.biBitCount != 8 && in->bmiHeader.biBitCount != 16)
|
||||
+ return ICERR_BADFORMAT;
|
||||
+
|
||||
if( out )
|
||||
{
|
||||
memcpy( out, in, size );
|
||||
+ out->bmiHeader.biWidth = in->bmiHeader.biWidth & ~1;
|
||||
+ out->bmiHeader.biHeight = in->bmiHeader.biHeight & ~1;
|
||||
out->bmiHeader.biCompression = BI_RGB;
|
||||
- out->bmiHeader.biSizeImage = in->bmiHeader.biHeight
|
||||
- * in->bmiHeader.biWidth *4;
|
||||
+ out->bmiHeader.biSizeImage = in->bmiHeader.biHeight *
|
||||
+ get_stride(out->bmiHeader.biWidth, out->bmiHeader.biBitCount);
|
||||
return ICERR_OK;
|
||||
}
|
||||
|
||||
@@ -398,6 +408,8 @@ static LRESULT CRAM_DecompressBegin( Msvideo1Context *info, LPBITMAPINFO in, LPB
|
||||
static void convert_depth(char *input, int depth_in, char *output, BITMAPINFOHEADER *out_hdr)
|
||||
{
|
||||
int x, y;
|
||||
+ int stride_in = get_stride(out_hdr->biWidth, depth_in);
|
||||
+ int stride_out = get_stride(out_hdr->biWidth, out_hdr->biBitCount);
|
||||
|
||||
if (depth_in == 16 && out_hdr->biBitCount == 24)
|
||||
{
|
||||
@@ -409,15 +421,17 @@ static void convert_depth(char *input, int depth_in, char *output, BITMAPINFOHEA
|
||||
0xc5, 0xce, 0xd6, 0xde, 0xe6, 0xef, 0xf7, 0xff,
|
||||
};
|
||||
|
||||
- WORD *src = (WORD *)input;
|
||||
for (y = 0; y < out_hdr->biHeight; y++)
|
||||
{
|
||||
+ WORD *src_row = (WORD *)(input + y * stride_in);
|
||||
+ char *out_row = output + y * stride_out;
|
||||
+
|
||||
for (x = 0; x < out_hdr->biWidth; x++)
|
||||
{
|
||||
- WORD pixel = *src++;
|
||||
- *output++ = convert_5to8[(pixel & 0x7c00u) >> 10];
|
||||
- *output++ = convert_5to8[(pixel & 0x03e0u) >> 5];
|
||||
- *output++ = convert_5to8[(pixel & 0x001fu)];
|
||||
+ WORD pixel = *src_row++;
|
||||
+ *out_row++ = convert_5to8[(pixel & 0x7c00u) >> 10];
|
||||
+ *out_row++ = convert_5to8[(pixel & 0x03e0u) >> 5];
|
||||
+ *out_row++ = convert_5to8[(pixel & 0x001fu)];
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -439,7 +453,6 @@ static LRESULT CRAM_Decompress( Msvideo1Context *info, ICDECOMPRESS *icd, DWORD
|
||||
|
||||
width = icd->lpbiInput->biWidth;
|
||||
height = icd->lpbiInput->biHeight;
|
||||
- stride = width; /* in bytes or 16bit words */
|
||||
sz = icd->lpbiInput->biSizeImage;
|
||||
|
||||
output = icd->lpOutput;
|
||||
@@ -452,11 +465,13 @@ static LRESULT CRAM_Decompress( Msvideo1Context *info, ICDECOMPRESS *icd, DWORD
|
||||
|
||||
if (info->depth == 8)
|
||||
{
|
||||
+ stride = get_stride(width, 8);
|
||||
msvideo1_decode_8bit( width, height, icd->lpInput, sz,
|
||||
output, stride );
|
||||
}
|
||||
else
|
||||
{
|
||||
+ stride = get_stride(width, 16) / 2;
|
||||
msvideo1_decode_16bit( width, height, icd->lpInput, sz,
|
||||
output, stride );
|
||||
}
|
||||
@@ -484,7 +499,6 @@ static LRESULT CRAM_DecompressEx( Msvideo1Context *info, ICDECOMPRESSEX *icd, DW
|
||||
|
||||
width = icd->lpbiSrc->biWidth;
|
||||
height = icd->lpbiSrc->biHeight;
|
||||
- stride = width;
|
||||
sz = icd->lpbiSrc->biSizeImage;
|
||||
|
||||
output = icd->lpDst;
|
||||
@@ -497,11 +511,13 @@ static LRESULT CRAM_DecompressEx( Msvideo1Context *info, ICDECOMPRESSEX *icd, DW
|
||||
|
||||
if (info->depth == 8)
|
||||
{
|
||||
+ stride = get_stride(width, 8);
|
||||
msvideo1_decode_8bit( width, height, icd->lpSrc, sz,
|
||||
output, stride );
|
||||
}
|
||||
else
|
||||
{
|
||||
+ stride = get_stride(width, 16) / 2;
|
||||
msvideo1_decode_16bit( width, height, icd->lpSrc, sz,
|
||||
output, stride );
|
||||
}
|
||||
--
|
||||
2.7.1
|
||||
|
@ -1,3 +0,0 @@
|
||||
Fixes: [23175] Fix implementation of ICGetDisplayFormat
|
||||
Fixes: [25180] Fix rendering of Clonk Endeavour's intro video
|
||||
Fixes: [14695] Implement support for converting 16 bit depth to 24 bit in msvidc32
|
@ -1,4 +1,4 @@
|
||||
From 2afc731dcc7e4b8963ddc2792cce17e1ff7c40dc Mon Sep 17 00:00:00 2001
|
||||
From 7e49bdcb1622494a4ca5e5b36f05482189cf151f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Mon, 3 Apr 2017 01:06:26 +0200
|
||||
Subject: [PATCH] ntdll: Add dummy apiset to PEB.
|
||||
@ -6,13 +6,13 @@ Subject: [PATCH] ntdll: Add dummy apiset to PEB.
|
||||
---
|
||||
dlls/ntdll/thread.c | 2 ++
|
||||
include/Makefile.in | 1 +
|
||||
include/apiset.h | 38 ++++++++++++++++++++++++++++++++++++++
|
||||
include/apiset.h | 37 +++++++++++++++++++++++++++++++++++++
|
||||
include/winternl.h | 3 ++-
|
||||
4 files changed, 43 insertions(+), 1 deletion(-)
|
||||
4 files changed, 42 insertions(+), 1 deletion(-)
|
||||
create mode 100644 include/apiset.h
|
||||
|
||||
diff --git a/dlls/ntdll/thread.c b/dlls/ntdll/thread.c
|
||||
index 0f90291..c36337a6 100644
|
||||
index 0f90291e2..c36337a64 100644
|
||||
--- a/dlls/ntdll/thread.c
|
||||
+++ b/dlls/ntdll/thread.c
|
||||
@@ -72,6 +72,7 @@ static PEB_LDR_DATA ldr;
|
||||
@ -32,11 +32,11 @@ index 0f90291..c36337a6 100644
|
||||
peb->TlsExpansionBitmap = &tls_expansion_bitmap;
|
||||
peb->FlsBitmap = &fls_bitmap;
|
||||
diff --git a/include/Makefile.in b/include/Makefile.in
|
||||
index 5485084..72e6e5d 100644
|
||||
index 2817c10d1..8a4759d17 100644
|
||||
--- a/include/Makefile.in
|
||||
+++ b/include/Makefile.in
|
||||
@@ -13,6 +13,7 @@ SOURCES = \
|
||||
amaudio.h \
|
||||
@@ -14,6 +14,7 @@ SOURCES = \
|
||||
amsi.idl \
|
||||
amstream.idl \
|
||||
amvideo.idl \
|
||||
+ apiset.h \
|
||||
@ -45,10 +45,10 @@ index 5485084..72e6e5d 100644
|
||||
appmodel.h \
|
||||
diff --git a/include/apiset.h b/include/apiset.h
|
||||
new file mode 100644
|
||||
index 0000000..f55f804
|
||||
index 000000000..6801cd5f5
|
||||
--- /dev/null
|
||||
+++ b/include/apiset.h
|
||||
@@ -0,0 +1,38 @@
|
||||
@@ -0,0 +1,37 @@
|
||||
+/*
|
||||
+ * Copyright (C) 2017 Michael Müller
|
||||
+ *
|
||||
@ -86,9 +86,8 @@ index 0000000..f55f804
|
||||
+} API_SET_NAMESPACE_ARRAY, *PAPI_SET_NAMESPACE_ARRAY;
|
||||
+
|
||||
+#endif
|
||||
+
|
||||
diff --git a/include/winternl.h b/include/winternl.h
|
||||
index 064444d..a9c6cab 100644
|
||||
index 46dac7e48..352d9f64d 100644
|
||||
--- a/include/winternl.h
|
||||
+++ b/include/winternl.h
|
||||
@@ -23,6 +23,7 @@
|
||||
@ -109,5 +108,5 @@ index 064444d..a9c6cab 100644
|
||||
PRTL_BITMAP TlsBitmap; /* 040/078 */
|
||||
ULONG TlsBitmapBits[2]; /* 044/080 */
|
||||
--
|
||||
1.9.1
|
||||
2.20.1
|
||||
|
||||
|
@ -52,7 +52,7 @@ usage()
|
||||
# Get the upstream commit sha
|
||||
upstream_commit()
|
||||
{
|
||||
echo "56f34c7489cb463981e987a59aee9f8780fef7cd"
|
||||
echo "ab7756619c1b16c761618a68d1b6a06ad437cbe8"
|
||||
}
|
||||
|
||||
# Show version information
|
||||
@ -186,7 +186,6 @@ patch_enable_all ()
|
||||
enable_msi_msi_vcl_get_cost="$1"
|
||||
enable_msidb_Implementation="$1"
|
||||
enable_msvcrt_Math_Precision="$1"
|
||||
enable_msvfw32_ICGetDisplayFormat="$1"
|
||||
enable_ntdll_APC_Performance="$1"
|
||||
enable_ntdll_Activation_Context="$1"
|
||||
enable_ntdll_ApiSetMap="$1"
|
||||
@ -272,13 +271,11 @@ patch_enable_all ()
|
||||
enable_server_Stored_ACLs="$1"
|
||||
enable_server_Timestamp_Compat="$1"
|
||||
enable_server_device_manager_destroy="$1"
|
||||
enable_setupapi_CM_Request_Device_Eject="$1"
|
||||
enable_setupapi_DiskSpaceList="$1"
|
||||
enable_setupapi_Display_Device="$1"
|
||||
enable_setupapi_HSPFILEQ_Check_Type="$1"
|
||||
enable_setupapi_SPFILENOTIFY_FILEINCABINET="$1"
|
||||
enable_setupapi_SP_COPY_IN_USE_NEEDS_REBOOT="$1"
|
||||
enable_setupapi_SetupDiGetDeviceInterfaceDetail="$1"
|
||||
enable_setupapi_SetupPromptForDisk="$1"
|
||||
enable_shdocvw_ParseURLFromOutsideSource_Tests="$1"
|
||||
enable_shell32_ACE_Viewer="$1"
|
||||
@ -711,9 +708,6 @@ patch_enable ()
|
||||
msvcrt-Math_Precision)
|
||||
enable_msvcrt_Math_Precision="$2"
|
||||
;;
|
||||
msvfw32-ICGetDisplayFormat)
|
||||
enable_msvfw32_ICGetDisplayFormat="$2"
|
||||
;;
|
||||
ntdll-APC_Performance)
|
||||
enable_ntdll_APC_Performance="$2"
|
||||
;;
|
||||
@ -969,9 +963,6 @@ patch_enable ()
|
||||
server-device_manager_destroy)
|
||||
enable_server_device_manager_destroy="$2"
|
||||
;;
|
||||
setupapi-CM_Request_Device_Eject)
|
||||
enable_setupapi_CM_Request_Device_Eject="$2"
|
||||
;;
|
||||
setupapi-DiskSpaceList)
|
||||
enable_setupapi_DiskSpaceList="$2"
|
||||
;;
|
||||
@ -987,9 +978,6 @@ patch_enable ()
|
||||
setupapi-SP_COPY_IN_USE_NEEDS_REBOOT)
|
||||
enable_setupapi_SP_COPY_IN_USE_NEEDS_REBOOT="$2"
|
||||
;;
|
||||
setupapi-SetupDiGetDeviceInterfaceDetail)
|
||||
enable_setupapi_SetupDiGetDeviceInterfaceDetail="$2"
|
||||
;;
|
||||
setupapi-SetupPromptForDisk)
|
||||
enable_setupapi_SetupPromptForDisk="$2"
|
||||
;;
|
||||
@ -4235,27 +4223,6 @@ if test "$enable_msvcrt_Math_Precision" -eq 1; then
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset msvfw32-ICGetDisplayFormat
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
# | * [#23175] Fix implementation of ICGetDisplayFormat
|
||||
# | * [#25180] Fix rendering of Clonk Endeavour's intro video
|
||||
# | * [#14695] Implement support for converting 16 bit depth to 24 bit in msvidc32
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * dlls/iccvid/iccvid.c, dlls/msvfw32/tests/msvfw.c, dlls/msvidc32/msvideo1.c
|
||||
# |
|
||||
if test "$enable_msvfw32_ICGetDisplayFormat" -eq 1; then
|
||||
patch_apply msvfw32-ICGetDisplayFormat/0005-iccvid-Fix-calculation-of-stride-and-size.patch
|
||||
patch_apply msvfw32-ICGetDisplayFormat/0006-msvidc32-Add-support-for-converting-16-bit-depth-to-.patch
|
||||
patch_apply msvfw32-ICGetDisplayFormat/0007-msvidc32-Fix-calculation-of-stride-and-size.patch
|
||||
(
|
||||
printf '%s\n' '+ { "Michael Müller", "iccvid: Fix calculation of stride and size.", 1 },';
|
||||
printf '%s\n' '+ { "Michael Müller", "msvidc32: Add support for converting 16 bit depth to 24 bit.", 1 },';
|
||||
printf '%s\n' '+ { "Michael Müller", "msvidc32: Fix calculation of stride and size.", 1 },';
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset ntdll-APC_Performance
|
||||
# |
|
||||
# | Modified files:
|
||||
@ -5691,21 +5658,6 @@ if test "$enable_server_device_manager_destroy" -eq 1; then
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset setupapi-CM_Request_Device_Eject
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
# | * [#45879] Added CM_Request_Device_EjectA/W stub
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * dlls/setupapi/setupapi.spec, dlls/setupapi/stubs.c, include/cfgmgr32.h
|
||||
# |
|
||||
if test "$enable_setupapi_CM_Request_Device_Eject" -eq 1; then
|
||||
patch_apply setupapi-CM_Request_Device_Eject/0001-setupapi-Added-CM_Request_Device_EjectA-W-stub.patch
|
||||
(
|
||||
printf '%s\n' '+ { "Alistair Leslie-Hughes", "setupapi: Added CM_Request_Device_EjectA/W stub.", 1 },';
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset setupapi-DiskSpaceList
|
||||
# |
|
||||
# | Modified files:
|
||||
@ -5799,23 +5751,6 @@ if test "$enable_setupapi_SP_COPY_IN_USE_NEEDS_REBOOT" -eq 1; then
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset setupapi-SetupDiGetDeviceInterfaceDetail
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
# | * [#45963] - Add SetupDiInstallDeviceInterfaces/SetupDiRegisterCoDeviceInstallers stubs
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * dlls/setupapi/devinst.c, dlls/setupapi/setupapi.spec
|
||||
# |
|
||||
if test "$enable_setupapi_SetupDiGetDeviceInterfaceDetail" -eq 1; then
|
||||
patch_apply setupapi-SetupDiGetDeviceInterfaceDetail/0001-setupapi-Add-SetupDiInstallDeviceInterfaces.patch
|
||||
patch_apply setupapi-SetupDiGetDeviceInterfaceDetail/0002-setupapi-Add-SetupDiRegisterCoDeviceInstallers-stub.patch
|
||||
(
|
||||
printf '%s\n' '+ { "Alistair Leslie-Hughes", "setupapi: Add SetupDiInstallDeviceInterfaces.", 1 },';
|
||||
printf '%s\n' '+ { "Alistair Leslie-Hughes", "setupapi: Add SetupDiRegisterCoDeviceInstallers stub.", 1 },';
|
||||
) >> "$patchlist"
|
||||
fi
|
||||
|
||||
# Patchset setupapi-SetupPromptForDisk
|
||||
# |
|
||||
# | This patchset fixes the following Wine bugs:
|
||||
@ -6923,9 +6858,10 @@ fi
|
||||
# | * [#8051] Sims 2 demo exits prematurely
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * dlls/d3d9/d3d9_private.h, dlls/d3d9/device.c, dlls/d3d9/directx.c, dlls/d3d9/tests/device.c, dlls/d3d9/tests/visual.c,
|
||||
# | dlls/wined3d/adapter_gl.c, dlls/wined3d/device.c, dlls/wined3d/glsl_shader.c, dlls/wined3d/shader.c,
|
||||
# | dlls/wined3d/shader_sm1.c, dlls/wined3d/stateblock.c, dlls/wined3d/utils.c, dlls/wined3d/wined3d_private.h
|
||||
# | * dlls/d3d8/directx.c, dlls/d3d9/d3d9_private.h, dlls/d3d9/device.c, dlls/d3d9/directx.c, dlls/d3d9/tests/device.c,
|
||||
# | dlls/d3d9/tests/visual.c, dlls/wined3d/adapter_gl.c, dlls/wined3d/device.c, dlls/wined3d/glsl_shader.c,
|
||||
# | dlls/wined3d/shader.c, dlls/wined3d/shader_sm1.c, dlls/wined3d/state.c, dlls/wined3d/stateblock.c,
|
||||
# | dlls/wined3d/wined3d_private.h, include/wine/wined3d.h
|
||||
# |
|
||||
if test "$enable_wined3d_SWVP_shaders" -eq 1; then
|
||||
patch_apply wined3d-SWVP-shaders/0001-wined3d-Use-UBO-for-vertex-shader-float-constants-if.patch
|
||||
|
@ -1,95 +0,0 @@
|
||||
From 4c2371beddfffe95d91404cea8e5bcc911f67e78 Mon Sep 17 00:00:00 2001
|
||||
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
Date: Thu, 4 Oct 2018 14:06:21 +1000
|
||||
Subject: [PATCH] setupapi: Added CM_Request_Device_EjectA/W stub
|
||||
|
||||
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=45879
|
||||
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
---
|
||||
dlls/setupapi/setupapi.spec | 4 ++--
|
||||
dlls/setupapi/stubs.c | 18 ++++++++++++++++++
|
||||
include/cfgmgr32.h | 20 ++++++++++++++++++++
|
||||
3 files changed, 40 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dlls/setupapi/setupapi.spec b/dlls/setupapi/setupapi.spec
|
||||
index 99509e1..64af966 100644
|
||||
--- a/dlls/setupapi/setupapi.spec
|
||||
+++ b/dlls/setupapi/setupapi.spec
|
||||
@@ -168,8 +168,8 @@
|
||||
@ stub CM_Remove_SubTree_Ex
|
||||
@ stub CM_Remove_Unmarked_Children
|
||||
@ stub CM_Remove_Unmarked_Children_Ex
|
||||
-@ stub CM_Request_Device_EjectA
|
||||
-@ stub CM_Request_Device_EjectW
|
||||
+@ stdcall CM_Request_Device_EjectA(ptr ptr ptr long long)
|
||||
+@ stdcall CM_Request_Device_EjectW(ptr ptr ptr long long)
|
||||
@ stub CM_Request_Eject_PC
|
||||
@ stub CM_Reset_Children_Marks
|
||||
@ stub CM_Reset_Children_Marks_Ex
|
||||
diff --git a/dlls/setupapi/stubs.c b/dlls/setupapi/stubs.c
|
||||
index 7c3413a..16224bf 100644
|
||||
--- a/dlls/setupapi/stubs.c
|
||||
+++ b/dlls/setupapi/stubs.c
|
||||
@@ -698,3 +698,21 @@ BOOL WINAPI SetupDiEnumDriverInfoW(HDEVINFO DeviceInfoSet, PSP_DEVINFO_DATA Devi
|
||||
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
||||
return FALSE;
|
||||
}
|
||||
+
|
||||
+/***********************************************************************
|
||||
+ * CM_Request_Device_EjectA (SETUPAPI.@)
|
||||
+ */
|
||||
+CONFIGRET WINAPI CM_Request_Device_EjectA(DEVINST dev, PPNP_VETO_TYPE type, LPSTR name, ULONG length, ULONG flags)
|
||||
+{
|
||||
+ FIXME("(0x%08x, %p, %p, %u, 0x%08x) stub\n", dev, type, name, length, flags);
|
||||
+ return CR_SUCCESS;
|
||||
+}
|
||||
+
|
||||
+/***********************************************************************
|
||||
+ * CM_Request_Device_EjectW (SETUPAPI.@)
|
||||
+ */
|
||||
+CONFIGRET WINAPI CM_Request_Device_EjectW(DEVINST dev, PPNP_VETO_TYPE type, LPWSTR name, ULONG length, ULONG flags)
|
||||
+{
|
||||
+ FIXME("(0x%08x, %p, %p, %u, 0x%08x) stub\n", dev, type, name, length, flags);
|
||||
+ return CR_SUCCESS;
|
||||
+}
|
||||
diff --git a/include/cfgmgr32.h b/include/cfgmgr32.h
|
||||
index b8def60..97564a0 100644
|
||||
--- a/include/cfgmgr32.h
|
||||
+++ b/include/cfgmgr32.h
|
||||
@@ -175,6 +175,23 @@ typedef CHAR *DEVNODEID_A, *DEVINSTID_A;
|
||||
typedef WCHAR *DEVNODEID_W, *DEVINSTID_W;
|
||||
typedef ULONG REGDISPOSITION;
|
||||
|
||||
+typedef enum _PNP_VETO_TYPE
|
||||
+{
|
||||
+ PNP_VetoTypeUnknown,
|
||||
+ PNP_VetoLegacyDevice,
|
||||
+ PNP_VetoPendingClose,
|
||||
+ PNP_VetoWindowsApp,
|
||||
+ PNP_VetoWindowsService,
|
||||
+ PNP_VetoOutstandingOpen,
|
||||
+ PNP_VetoDevice,
|
||||
+ PNP_VetoDriver,
|
||||
+ PNP_VetoIllegalDeviceRequest,
|
||||
+ PNP_VetoInsufficientPower,
|
||||
+ PNP_VetoNonDisableable,
|
||||
+ PNP_VetoLegacyDriver,
|
||||
+ PNP_VetoInsufficientRights
|
||||
+} PNP_VETO_TYPE, *PPNP_VETO_TYPE;
|
||||
+
|
||||
DECL_WINELIB_CFGMGR32_TYPE_AW(DEVNODEID)
|
||||
DECL_WINELIB_CFGMGR32_TYPE_AW(DEVINSTID)
|
||||
|
||||
@@ -212,6 +229,9 @@ CMAPI CONFIGRET WINAPI CM_Locate_DevNodeW(PDEVINST,DEVINSTID_W,ULONG);
|
||||
#define CM_Locate_DevNode WINELIB_NAME_AW(CM_Locate_DevNode)
|
||||
CMAPI CONFIGRET WINAPI CM_Open_DevNode_Key(DEVINST dnDevInst, REGSAM access, ULONG ulHardwareProfile,
|
||||
REGDISPOSITION disposition, PHKEY phkDevice, ULONG ulFlags);
|
||||
+CMAPI CONFIGRET WINAPI CM_Request_Device_EjectA(DEVINST dev, PPNP_VETO_TYPE type, LPSTR name, ULONG length, ULONG flags);
|
||||
+CMAPI CONFIGRET WINAPI CM_Request_Device_EjectW(DEVINST dev, PPNP_VETO_TYPE type, LPWSTR name, ULONG length, ULONG flags);
|
||||
+#define CM_Request_Device_Eject WINELIB_NAME_AW(CM_Get_Device_ID_List_Ex)
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
--
|
||||
1.9.1
|
||||
|
@ -1 +0,0 @@
|
||||
Fixes: [45879] Added CM_Request_Device_EjectA/W stub
|
@ -1,47 +0,0 @@
|
||||
From dd19f26a49f288dec1d287ebaaeb7a2dd2e7f0cd Mon Sep 17 00:00:00 2001
|
||||
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
Date: Mon, 15 Oct 2018 12:05:41 +1100
|
||||
Subject: [PATCH] setupapi: Add SetupDiInstallDeviceInterfaces
|
||||
|
||||
Wine-bug: https://bugs.winehq.org/show_bug.cgi?id=45963
|
||||
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
---
|
||||
dlls/setupapi/devinst.c | 12 ++++++++++++
|
||||
dlls/setupapi/setupapi.spec | 1 +
|
||||
2 files changed, 13 insertions(+)
|
||||
|
||||
diff --git a/dlls/setupapi/devinst.c b/dlls/setupapi/devinst.c
|
||||
index 632d704c9bd..129b7384162 100644
|
||||
--- a/dlls/setupapi/devinst.c
|
||||
+++ b/dlls/setupapi/devinst.c
|
||||
@@ -4002,3 +4002,15 @@ BOOL WINAPI SetupDiGetDevicePropertyW(HDEVINFO devinfo, PSP_DEVINFO_DATA device_
|
||||
SetLastError(ls);
|
||||
return !ls;
|
||||
}
|
||||
+
|
||||
+/***********************************************************************
|
||||
+ * SetupDiInstallDeviceInterfaces (SETUPAPI.@)
|
||||
+ */
|
||||
+BOOL WINAPI SetupDiInstallDeviceInterfaces(HDEVINFO dev, PSP_DEVINFO_DATA info_data)
|
||||
+{
|
||||
+ FIXME("%p, %p stub\n", dev, info_data);
|
||||
+
|
||||
+ SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
||||
+ return FALSE;
|
||||
+}
|
||||
+
|
||||
diff --git a/dlls/setupapi/setupapi.spec b/dlls/setupapi/setupapi.spec
|
||||
index 3cd5663a01e..984f2218f02 100644
|
||||
--- a/dlls/setupapi/setupapi.spec
|
||||
+++ b/dlls/setupapi/setupapi.spec
|
||||
@@ -367,6 +367,7 @@
|
||||
@ stub SetupDiInstallClassExW
|
||||
@ stdcall SetupDiInstallClassW(long wstr long ptr)
|
||||
@ stub SetupDiInstallDevice
|
||||
+@ stdcall SetupDiInstallDeviceInterfaces(ptr ptr)
|
||||
@ stub SetupDiInstallDriverFiles
|
||||
@ stdcall SetupDiLoadClassIcon(ptr ptr ptr)
|
||||
@ stub SetupDiMoveDuplicateDevice
|
||||
--
|
||||
2.20.1
|
||||
|
@ -1,44 +0,0 @@
|
||||
From 8cba6e456b2eaac13fac4190ee77218e9a3f4f95 Mon Sep 17 00:00:00 2001
|
||||
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
Date: Mon, 15 Oct 2018 12:09:40 +1100
|
||||
Subject: [PATCH] setupapi: Add SetupDiRegisterCoDeviceInstallers stub
|
||||
|
||||
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
|
||||
---
|
||||
dlls/setupapi/devinst.c | 10 ++++++++++
|
||||
dlls/setupapi/setupapi.spec | 1 +
|
||||
2 files changed, 11 insertions(+)
|
||||
|
||||
diff --git a/dlls/setupapi/devinst.c b/dlls/setupapi/devinst.c
|
||||
index b15e580..3f8949e 100644
|
||||
--- a/dlls/setupapi/devinst.c
|
||||
+++ b/dlls/setupapi/devinst.c
|
||||
@@ -4032,3 +4032,13 @@ BOOL WINAPI SetupDiInstallDeviceInterfaces(HDEVINFO dev, PSP_DEVINFO_DATA info_d
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
+/***********************************************************************
|
||||
+ * SetupDiRegisterCoDeviceInstallers (SETUPAPI.@)
|
||||
+ */
|
||||
+BOOL WINAPI SetupDiRegisterCoDeviceInstallers(HDEVINFO dev, PSP_DEVINFO_DATA info_data)
|
||||
+{
|
||||
+ FIXME("%p, %p stub\n", dev, info_data);
|
||||
+
|
||||
+ SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
||||
+ return FALSE;
|
||||
+}
|
||||
diff --git a/dlls/setupapi/setupapi.spec b/dlls/setupapi/setupapi.spec
|
||||
index 3f906ed..125b205 100644
|
||||
--- a/dlls/setupapi/setupapi.spec
|
||||
+++ b/dlls/setupapi/setupapi.spec
|
||||
@@ -380,6 +380,7 @@
|
||||
@ stdcall SetupDiOpenDeviceInterfaceA(ptr str long ptr)
|
||||
@ stub SetupDiOpenDeviceInterfaceRegKey
|
||||
@ stdcall SetupDiOpenDeviceInterfaceW(ptr wstr long ptr)
|
||||
+@ stdcall SetupDiRegisterCoDeviceInstallers(ptr ptr)
|
||||
@ stdcall SetupDiRegisterDeviceInfo(ptr ptr long ptr ptr ptr)
|
||||
@ stdcall SetupDiRemoveDevice(ptr ptr)
|
||||
@ stdcall SetupDiRemoveDeviceInterface(ptr ptr)
|
||||
--
|
||||
1.9.1
|
||||
|
@ -1,2 +0,0 @@
|
||||
Fixes: [45963] - Add SetupDiInstallDeviceInterfaces/SetupDiRegisterCoDeviceInstallers stubs
|
||||
Fixes: Fill out DeviceInfoData in SetupDiGetDeviceInterfaceDetail even if interface buffer is too small
|
Loading…
x
Reference in New Issue
Block a user