Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
31682b3d
Commit
31682b3d
authored
Nov 08, 2010
by
Vincent Povirk
Committed by
Alexandre Julliard
Nov 09, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9_36: Don't check the image format in D3DXLoadSurfaceFromFileInMemory.
If the format is not supported, D3DXGetImageInfoFromFileInMemory will fail.
parent
384b9553
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
23 deletions
+9
-23
surface.c
dlls/d3dx9_36/surface.c
+9
-23
No files found.
dlls/d3dx9_36/surface.c
View file @
31682b3d
...
...
@@ -314,6 +314,15 @@ HRESULT WINAPI D3DXLoadSurfaceFromFileInMemory(LPDIRECT3DSURFACE9 pDestSurface,
D3DXIMAGE_INFO
imginfo
;
HRESULT
hr
;
IWICImagingFactory
*
factory
;
IWICBitmapDecoder
*
decoder
;
IWICBitmapFrameDecode
*
bitmapframe
;
IWICStream
*
stream
;
const
PixelFormatDesc
*
formatdesc
;
WICRect
wicrect
;
RECT
rect
;
TRACE
(
"(%p, %p, %p, %p, %d, %p, %d, %x, %p)
\n
"
,
pDestSurface
,
pDestPalette
,
pDestRect
,
pSrcData
,
SrcDataSize
,
pSrcRect
,
dwFilter
,
Colorkey
,
pSrcInfo
);
...
...
@@ -325,21 +334,6 @@ HRESULT WINAPI D3DXLoadSurfaceFromFileInMemory(LPDIRECT3DSURFACE9 pDestSurface,
if
(
FAILED
(
hr
))
return
hr
;
switch
(
imginfo
.
ImageFileFormat
)
{
case
D3DXIFF_BMP
:
case
D3DXIFF_PNG
:
case
D3DXIFF_JPG
:
{
IWICImagingFactory
*
factory
;
IWICBitmapDecoder
*
decoder
;
IWICBitmapFrameDecode
*
bitmapframe
;
IWICStream
*
stream
;
const
PixelFormatDesc
*
formatdesc
;
WICRect
wicrect
;
RECT
rect
;
CoInitializeEx
(
NULL
,
COINIT_APARTMENTTHREADED
);
if
(
FAILED
(
CoCreateInstance
(
&
CLSID_WICImagingFactory
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IWICImagingFactory
,
(
void
**
)
&
factory
)))
...
...
@@ -421,14 +415,6 @@ cleanup_err:
if
(
FAILED
(
hr
))
return
D3DXERR_INVALIDDATA
;
break
;
}
default:
FIXME
(
"Unsupported image file format
\n
"
);
return
E_NOTIMPL
;
}
if
(
pSrcInfo
)
*
pSrcInfo
=
imginfo
;
...
...
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