Skip to content

Latest commit

 

History

History
105 lines (72 loc) · 4.94 KB

nf-wincodec-iwicbitmapframeencode-writesource.md

File metadata and controls

105 lines (72 loc) · 4.94 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:wincodec.IWICBitmapFrameEncode.WriteSource
IWICBitmapFrameEncode::WriteSource (wincodec.h)
Encodes a bitmap source.
IWICBitmapFrameEncode interface [Windows Imaging Component]
WriteSource method
IWICBitmapFrameEncode.WriteSource
IWICBitmapFrameEncode::WriteSource
WriteSource
WriteSource method [Windows Imaging Component]
WriteSource method [Windows Imaging Component]
IWICBitmapFrameEncode interface
_wic_codec_iwicbitmapframeencode_writesource
wic._wic_codec_iwicbitmapframeencode_writesource
wincodec/IWICBitmapFrameEncode::WriteSource
wic\_wic_codec_iwicbitmapframeencode_writesource.htm
wic
bc748982-6dc8-41cc-a23b-9d127dc22a1f
12/05/2018
IWICBitmapFrameEncode interface [Windows Imaging Component],WriteSource method, IWICBitmapFrameEncode.WriteSource, IWICBitmapFrameEncode::WriteSource, WriteSource, WriteSource method [Windows Imaging Component], WriteSource method [Windows Imaging Component],IWICBitmapFrameEncode interface, _wic_codec_iwicbitmapframeencode_writesource, wic._wic_codec_iwicbitmapframeencode_writesource, wincodec/IWICBitmapFrameEncode::WriteSource
wincodec.h
Windows
Windows XP with SP2, Windows Vista [desktop apps \| UWP apps]
Windows Server 2008 [desktop apps \| UWP apps]
Wincodec.idl
Windowscodecs.lib
Windowscodecs.dll
Windows
19H1
IWICBitmapFrameEncode::WriteSource
wincodec/IWICBitmapFrameEncode::WriteSource
c++
APIRef
kbSyntax
COM
Windowscodecs.dll
IWICBitmapFrameEncode.WriteSource

IWICBitmapFrameEncode::WriteSource

-description

Encodes a bitmap source.

-parameters

-param pIBitmapSource [in]

Type: IWICBitmapSource*

The bitmap source to encode.

-param prc [in]

Type: WICRect*

The size rectangle of the bitmap source.

-returns

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

-remarks

If SetSize is not called prior to calling WriteSource, the size given in prc is used if not NULL. Otherwise, the size of the IWICBitmapSource given in pIBitmapSource is used.

If SetPixelFormat is not called prior to calling WriteSource, the pixel format of the IWICBitmapSource given in pIBitmapSource is used.

If SetResolution is not called prior to calling WriteSource, the pixel format of pIBitmapSource is used.

If SetPalette is not called prior to calling WriteSource, the target pixel format is indexed, and the pixel format of pIBitmapSource matches the encoder frame's pixel format, then the pIBitmapSource pixel format is used.

When encoding a GIF image, if the global palette is set and the frame level palette is not set directly by the user or by a custom independent software vendor (ISV) GIF codec, WriteSource will use the global palette to encode the frame even when pIBitmapSource has a frame level palette.

Starting with Windows Vista, repeated WriteSource calls can be made as long as the total accumulated source rect height is the same as set through SetSize.

Starting with Windows 8.1, the source rect must be at least the dimensions set through SetSize. If the source rect width exceeds the SetSize width, extra pixels on the right side are ignored. If the source rect height exceeds the remaining unfilled height, extra scan lines on the bottom are ignored.

-see-also

Conceptual

How to Write a WIC-Enabled CODEC

IWICBitmapFrameEncode

Windows Imaging Component Overview