public NImageData Encode( NImageFormat imageFormat, NImageEncoderSettings settings, ENCodecPreference encoderPreference )
Parameters
- imageFormat
- Specifies the target image format. Cannot be null.
- settings
- An object that specifies format-specific settings for the image encoder. The target format and the settings type must match. For example in order to encode the image into PNG format you have to pass NImageFormat.Png as imageFormat and an instance of the NPngEncoderSettings type as settings. If this parameter is set to null, the default encoder settings will be used.
- encoderPreference
- Specifies preference for the image encoder.
Return Value
Returns an object containing the encoded image data.