# OfficeJpegDecodeOptions

JPEG decoding options. Review signatures, members, parameters, type relationships, and available reference details in OfficeIMO.Core API Reference.

Struct 

`OfficeIMO.Drawing`

**Namespace**

`OfficeIMO.Drawing`

**Assembly**

`OfficeIMO.Core`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[OfficeJpegDecodeOptions.cs:30](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Jpeg/OfficeJpegDecodeOptions.cs#L30)

**Base**

`ValueType`

**Modifiers**

sealed

JPEG decoding options.

## Inheritance

- ValueType
- OfficeJpegDecodeOptions

## Usage

Explore 2 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Accepted by parameters 2

- Method [OfficeJpegCodec.Decode](/api/core/officeimo-drawing-officejpegcodec/#method-decode-byte-officeimo-drawing-officejpegdecodeoptions) parameter `options`
- Method [OfficeJpegCodec.TryDecode](/api/core/officeimo-drawing-officejpegcodec/#method-trydecode-byte-officeimo-drawing-officerasterimage-officeimo-drawing-officejpegdecodeoptions) parameter `options`

## Examples

```csharp
var options = new OfficeJpegDecodeOptions(highQualityChroma: true, allowTruncated: true);
OfficeRasterImage image = OfficeJpegCodec.Decode(data, options);
```

Filter members 

Show inherited

## Constructors

OfficeJpegDecodeOptions 2 overloads

`public OfficeJpegDecodeOptions(bool highQualityChroma = false, bool allowTruncated = false)` [#](#constructor-ctor-boolean-boolean)

[OfficeJpegDecodeOptions.cs:30](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Jpeg/OfficeJpegDecodeOptions.cs#L30)

Creates JPEG decode options.

Parameters

**highQualityChroma bool = false optional**

**allowTruncated bool = false optional**

`public OfficeJpegDecodeOptions(bool highQualityChroma, bool allowTruncated, bool ignoreExifOrientation)` [#](#constructor-ctor-boolean-boolean-boolean)

[OfficeJpegDecodeOptions.cs:35](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Jpeg/OfficeJpegDecodeOptions.cs#L35)

Creates JPEG decode options with an explicit EXIF orientation policy.

Parameters

**highQualityChroma bool required**

**allowTruncated bool required**

**ignoreExifOrientation bool required**

## Inherited Methods

`public override bool Equals(object? obj)` [#](#method-equals-object)

Inherited from ValueType

Parameters

**obj object? required**

Returns

`bool`

`public override int GetHashCode()` [#](#method-gethashcode)

Inherited from ValueType

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public override string? ToString()` [#](#method-tostring)

Inherited from ValueType

Returns

`string?`

## Properties

`public bool HighQualityChroma { get; }` [#](#property-highqualitychroma)

[OfficeJpegDecodeOptions.cs:16](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Jpeg/OfficeJpegDecodeOptions.cs#L16)

Enables higher-quality chroma upsampling when components are subsampled.

`public bool AllowTruncated { get; }` [#](#property-allowtruncated)

[OfficeJpegDecodeOptions.cs:21](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Jpeg/OfficeJpegDecodeOptions.cs#L21)

Allows truncated DCT-based scan data (best-effort decode). Lossless scans require complete entropy data.

`public bool IgnoreExifOrientation { get; }` [#](#property-ignoreexiforientation)

[OfficeJpegDecodeOptions.cs:24](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/Jpeg/OfficeJpegDecodeOptions.cs#L24)

Returns stored sample order without applying the JPEG's optional EXIF display orientation.

<!-- PowerForge markdown artifact sha256:0638793BAE7C7D4FE1C96E6E30543D082C33EBAC595167715C307417E62F4B75 -->
