Partager via


IImageEncoder::InitEncoder (Compact 2013)

3/26/2014

This feature is being deprecated for this release. Refer to this component: Windows Imaging Component.

This method initializes an image encoder object and associates it with an output stream.

Syntax

HRESULT InitEncoder(
  IStream* stream
);

Parameters

  • stream
    [in] A pointer to an IStream interface for the output stream.

    If the encoder requires a seekable stream and the stream is not seekable, the call to this method fails.

    You can verify whether the encoder requires a seekable stream by seeing whether the ImageCodecFlags enumeration value ImageCodecFlagsSeekableEncode is set.

Return Value

If successful, this method returns S_OK.

This method may return E_FAIL if it fails.

Remarks

Use the IImageEncoder::TerminateEncoder to break the association between the encoder and its output stream.

Requirements

Header

imaging.h

Library

Imaging.lib

See Also

Reference

IImageEncoder
IImageEncoder::TerminateEncoder