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
02aa7ec4
Commit
02aa7ec4
authored
Feb 28, 2012
by
Vincent Povirk
Committed by
Alexandre Julliard
Jun 26, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
windowscodecs: Implement IWICImagingFactory::CreateEncoder.
parent
efab3932
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
58 additions
and
2 deletions
+58
-2
imgfactory.c
dlls/windowscodecs/imgfactory.c
+58
-2
No files found.
dlls/windowscodecs/imgfactory.c
View file @
02aa7ec4
...
...
@@ -335,9 +335,65 @@ static HRESULT WINAPI ComponentFactory_CreateEncoder(IWICComponentFactory *iface
REFGUID
guidContainerFormat
,
const
GUID
*
pguidVendor
,
IWICBitmapEncoder
**
ppIEncoder
)
{
FIXME
(
"(%p,%s,%s,%p): stub
\n
"
,
iface
,
debugstr_guid
(
guidContainerFormat
),
static
int
fixme
=
0
;
IEnumUnknown
*
enumencoders
;
IUnknown
*
unkencoderinfo
;
IWICBitmapEncoderInfo
*
encoderinfo
;
IWICBitmapEncoder
*
encoder
=
NULL
;
HRESULT
res
=
S_OK
;
ULONG
num_fetched
;
GUID
actual_containerformat
;
TRACE
(
"(%p,%s,%s,%p)
\n
"
,
iface
,
debugstr_guid
(
guidContainerFormat
),
debugstr_guid
(
pguidVendor
),
ppIEncoder
);
return
E_NOTIMPL
;
if
(
pguidVendor
&&
!
fixme
++
)
FIXME
(
"ignoring vendor GUID
\n
"
);
res
=
CreateComponentEnumerator
(
WICEncoder
,
WICComponentEnumerateDefault
,
&
enumencoders
);
if
(
FAILED
(
res
))
return
res
;
while
(
!
encoder
)
{
res
=
IEnumUnknown_Next
(
enumencoders
,
1
,
&
unkencoderinfo
,
&
num_fetched
);
if
(
res
==
S_OK
)
{
res
=
IUnknown_QueryInterface
(
unkencoderinfo
,
&
IID_IWICBitmapEncoderInfo
,
(
void
**
)
&
encoderinfo
);
if
(
SUCCEEDED
(
res
))
{
res
=
IWICBitmapEncoderInfo_GetContainerFormat
(
encoderinfo
,
&
actual_containerformat
);
if
(
SUCCEEDED
(
res
)
&&
IsEqualGUID
(
guidContainerFormat
,
&
actual_containerformat
))
{
res
=
IWICBitmapEncoderInfo_CreateInstance
(
encoderinfo
,
&
encoder
);
if
(
FAILED
(
res
))
encoder
=
NULL
;
}
IWICBitmapEncoderInfo_Release
(
encoderinfo
);
}
IUnknown_Release
(
unkencoderinfo
);
}
else
break
;
}
IEnumUnknown_Release
(
enumencoders
);
if
(
encoder
)
{
*
ppIEncoder
=
encoder
;
return
S_OK
;
}
else
{
WARN
(
"failed to create encoder
\n
"
);
*
ppIEncoder
=
NULL
;
return
WINCODEC_ERR_COMPONENTNOTFOUND
;
}
}
static
HRESULT
WINAPI
ComponentFactory_CreatePalette
(
IWICComponentFactory
*
iface
,
...
...
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