# OfficeDrawingImage

Positioned image element inside an OfficeDrawing canvas.

Class 

`OfficeIMO.Drawing`

**Namespace**

`OfficeIMO.Drawing`

**Assembly**

`OfficeIMO.Core`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[OfficeDrawingImage.cs:18](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L18)

**Base**

`OfficeDrawingElement`

**Modifiers**

sealed

Positioned image element inside an [OfficeDrawing](/api/core/officeimo-drawing-officedrawing/) canvas.

## Inheritance

- [OfficeDrawingElement](/api/core/officeimo-drawing-officedrawingelement/)
- OfficeDrawingImage

## 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.

### Returned or exposed by 2

- Property [OfficeDrawing.Images](/api/core/officeimo-drawing-officedrawing/#property-images)
- Method [OfficeDrawingImage.CreateWithInterpolation](/api/core/officeimo-drawing-officedrawingimage/#method-createwithinterpolation-byte-string-officeimo-drawing-officeimageprojection-boolean-string-double)

Filter members 

Show inherited

## Constructors

`public OfficeDrawingImage(byte[] bytes, string? contentType, OfficeImageProjection projection, string? alternativeText = null, double opacity = 1)` [#](#constructor-ctor-byte-string-officeimo-drawing-officeimageprojection-string-double)

[OfficeDrawingImage.cs:18](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L18)

Creates an image drawing element.

Parameters

**bytes byte[] required**

Embedded source image bytes.

**contentType string? required**

Optional MIME content type.

**projection OfficeIMO.Drawing.OfficeImageProjection required**

Destination placement, crop, rotation, and flip settings.

**alternativeText string? = null optional**

Optional semantic label used by adapters and diagnostics.

**opacity double = 1 optional**

Element opacity from 0 transparent to 1 opaque.

## Methods

`public static OfficeDrawingImage CreateWithInterpolation(byte[] bytes, string? contentType, OfficeImageProjection projection, bool interpolate, string? alternativeText = null, double opacity = 1)` [#](#method-createwithinterpolation-byte-string-officeimo-drawing-officeimageprojection-boolean-string-double)

[OfficeDrawingImage.cs:29](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L29)

Creates an image drawing element with explicit scaling interpolation behavior.

Parameters

**bytes byte[] required**

**contentType string? required**

**projection OfficeIMO.Drawing.OfficeImageProjection required**

**interpolate bool required**

**alternativeText string? = null optional**

**opacity double = 1 optional**

Returns

`OfficeDrawingImage`

## Inherited Methods

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

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

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

Inherited from object

Returns

`int`

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

Inherited from object

Returns

`Type`

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

Inherited from object

Returns

`string?`

## Properties

`public byte[] Bytes { get; }` [#](#property-bytes)

[OfficeDrawingImage.cs:53](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L53)

Embedded source image bytes.

`public string ContentType { get; }` [#](#property-contenttype)

[OfficeDrawingImage.cs:56](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L56)

Normalized MIME content type, when available.

`public OfficeImageProjection Projection { get; }` [#](#property-projection)

[OfficeDrawingImage.cs:59](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L59)

Destination placement, crop, rotation, and flip settings.

`public string? AlternativeText { get; }` [#](#property-alternativetext)

[OfficeDrawingImage.cs:62](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L62)

Optional semantic label used by adapters and diagnostics.

`public double Opacity { get; }` [#](#property-opacity)

[OfficeDrawingImage.cs:65](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L65)

Element opacity from 0 transparent to 1 opaque.

`public bool Interpolate { get; }` [#](#property-interpolate)

[OfficeDrawingImage.cs:68](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeDrawingImage.cs#L68)

Whether renderers may smooth pixels while scaling the image.

<!-- PowerForge markdown artifact sha256:23AA6171A0139738587FA8C33A50FE7B57955A4255ABCBD506136ED848EDC409 -->
