Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
0529c8bf
Commit
0529c8bf
authored
Jan 03, 2001
by
Andreas Mohr
Committed by
Alexandre Julliard
Jan 03, 2001
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed bitmap size handling.
parent
c90fb25c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
14 deletions
+17
-14
drawdib.c
dlls/msvideo/drawdib.c
+17
-14
No files found.
dlls/msvideo/drawdib.c
View file @
0529c8bf
...
...
@@ -147,6 +147,7 @@ BOOL VFWAPI DrawDibBegin(HDRAWDIB hdd,
TRACE
(
"(%d,0x%lx,%d,%d,%p,%d,%d,0x%08lx)
\n
"
,
hdd
,(
DWORD
)
hdc
,
dxDst
,
dyDst
,
lpbi
,
dxSrc
,
dySrc
,(
DWORD
)
wFlags
);
TRACE
(
"lpbi: %ld,%ld/%ld,%d,%d,%ld,%ld,%ld,%ld,%ld,%ld
\n
"
,
lpbi
->
biSize
,
lpbi
->
biWidth
,
lpbi
->
biHeight
,
lpbi
->
biPlanes
,
lpbi
->
biBitCount
,
lpbi
->
biCompression
,
lpbi
->
biSizeImage
,
lpbi
->
biXPelsPerMeter
,
lpbi
->
biYPelsPerMeter
,
lpbi
->
biClrUsed
,
lpbi
->
biClrImportant
);
if
(
wFlags
)
FIXME
(
"wFlags == 0x%08lx not handled
\n
"
,(
DWORD
)
wFlags
);
...
...
@@ -190,10 +191,12 @@ BOOL VFWAPI DrawDibBegin(HDRAWDIB hdd,
TRACE
(
"biBitCount == %d
\n
"
,
whdd
->
lpbiOut
->
biBitCount
);
}
}
else
{
DWORD
dwSize
;
/* No compression */
TRACE
(
"Not compressed!
\n
"
);
whdd
->
lpbiOut
=
HeapAlloc
(
GetProcessHeap
(),
0
,
lpbi
->
biSize
);
memcpy
(
whdd
->
lpbiOut
,
lpbi
,
lpbi
->
biSize
);
dwSize
=
lpbi
->
biSize
+
lpbi
->
biClrUsed
*
sizeof
(
RGBQUAD
);
whdd
->
lpbiOut
=
HeapAlloc
(
GetProcessHeap
(),
0
,
dwSize
);
memcpy
(
whdd
->
lpbiOut
,
lpbi
,
dwSize
);
}
if
(
ret
)
{
...
...
@@ -250,19 +253,13 @@ BOOL16 VFWAPI DrawDibBegin16(HDRAWDIB16 hdd,
/**********************************************************************
* DrawDibDraw [MSVFW32.6]
*/
BOOL
VFWAPI
DrawDibDraw
(
HDRAWDIB
hdd
,
HDC
hdc
,
INT
xDst
,
INT
yDst
,
INT
dxDst
,
INT
dyDst
,
BOOL
VFWAPI
DrawDibDraw
(
HDRAWDIB
hdd
,
HDC
hdc
,
INT
xDst
,
INT
yDst
,
INT
dxDst
,
INT
dyDst
,
LPBITMAPINFOHEADER
lpbi
,
LPVOID
lpBits
,
INT
xSrc
,
INT
ySrc
,
INT
dxSrc
,
INT
dySrc
,
UINT
wFlags
)
{
INT
xSrc
,
INT
ySrc
,
INT
dxSrc
,
INT
dySrc
,
UINT
wFlags
)
{
WINE_HDD
*
whdd
;
BOOL
ret
=
TRUE
;
...
...
@@ -295,6 +292,10 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd,
dyDst
=
dySrc
;
}
/* biSizeImage may be set to 0 for BI_RGB (uncompressed) bitmaps */
if
((
lpbi
->
biCompression
==
BI_RGB
)
&&
(
lpbi
->
biSizeImage
==
0
))
lpbi
->
biSizeImage
=
((
lpbi
->
biWidth
*
lpbi
->
biBitCount
+
31
)
/
32
)
*
4
*
lpbi
->
biHeight
;
if
(
lpbi
->
biCompression
)
{
DWORD
flags
=
0
;
...
...
@@ -308,9 +309,11 @@ BOOL VFWAPI DrawDibDraw(HDRAWDIB hdd,
memcpy
(
whdd
->
lpvbits
,
lpBits
,
lpbi
->
biSizeImage
);
}
if
(
whdd
->
hpal
)
SelectPalette
(
hdc
,
whdd
->
hpal
,
FALSE
);
StretchBlt
(
whdd
->
hdc
,
xDst
,
yDst
,
dxDst
,
dyDst
,
whdd
->
hMemDC
,
xSrc
,
ySrc
,
dxSrc
,
dySrc
,
SRCCOPY
);
if
(
!
(
StretchBlt
(
whdd
->
hdc
,
xDst
,
yDst
,
dxDst
,
dyDst
,
whdd
->
hMemDC
,
xSrc
,
ySrc
,
dxSrc
,
dySrc
,
SRCCOPY
)))
ret
=
FALSE
;
GlobalUnlock16
(
hdd
);
return
ret
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment