---
title: "RasterDEMSourceSpecification | JavaScript maps SDK"
description: "Documentation for MapTiler SDK"
---

> For AI agents: a documentation index is available at [/llms.txt](https://docs.maptiler.com/llms.txt). Markdown versions of all pages are available by appending .md to any URL.

# Type Alias RasterDEMSourceSpecification

type RasterDEMSourceSpecification \= {  
    [attribution](#attribution)?: string;  
    [baseShift](#baseshift)?: number;  
    [blueFactor](#bluefactor)?: number;  
    [bounds](#bounds)?: \[number, number, number, number\];  
    [encoding](#encoding)?: "terrarium" | "mapbox" | "custom";  
    [greenFactor](#greenfactor)?: number;  
    [maxzoom](#maxzoom)?: number;  
    [minzoom](#minzoom)?: number;  
    [redFactor](#redfactor)?: number;  
    [tiles](#tiles)?: string\[\];  
    [tileSize](#tilesize)?: number;  
    [type](#type): "raster-dem";  
    [url](#url)?: string;  
    [volatile](#volatile)?: boolean;  
}

##### Index

### Properties[](#properties)

[attribution?](#attribution) [baseShift?](#baseshift) [blueFactor?](#bluefactor) [bounds?](#bounds) [encoding?](#encoding) [greenFactor?](#greenfactor) [maxzoom?](#maxzoom) [minzoom?](#minzoom) [redFactor?](#redfactor) [tiles?](#tiles) [tileSize?](#tilesize) [type](#type) [url?](#url) [volatile?](#volatile)

## Properties[](#properties-1)

### `Optional`attribution[](#attribution)

attribution?: string

Contains an attribution to be displayed when the map is shown to a user.

### `Optional`baseShift[](#baseshift)

baseShift?: number

Value that will be added to the encoding mix when decoding. Only used on custom encodings.

### `Optional`blueFactor[](#bluefactor)

blueFactor?: number

Value that will be multiplied by the blue channel value when decoding. Only used on custom encodings.

#### Default[](#default)

```typescript
1
```

### `Optional`bounds[](#bounds)

bounds?: \[number, number, number, number\]

An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: `[sw.lng, sw.lat, ne.lng, ne.lat]`. When this property is included in a source, no tiles outside of the given bounds are requested by MapLibre.

#### Default[](#default-1)

```json
[-180, -85.051129, 180, 85.051129]
```

### `Optional`encoding[](#encoding)

encoding?: "terrarium" | "mapbox" | "custom"

The encoding used by this source. Mapbox Terrain RGB is used by default.

#### Default[](#default-2)

```typescript
"mapbox"
```

### `Optional`greenFactor[](#greenfactor)

greenFactor?: number

Value that will be multiplied by the green channel value when decoding. Only used on custom encodings.

#### Default[](#default-3)

```typescript
1
```

### `Optional`maxzoom[](#maxzoom)

maxzoom?: number

Maximum zoom level for which tiles are available, as in the TileJSON spec. Data from tiles at the maxzoom are used when displaying the map at higher zoom levels.

#### Default[](#default-4)

```typescript
22
```

### `Optional`minzoom[](#minzoom)

minzoom?: number

Minimum zoom level for which tiles are available, as in the TileJSON spec.

### `Optional`redFactor[](#redfactor)

redFactor?: number

Value that will be multiplied by the red channel value when decoding. Only used on custom encodings.

#### Default[](#default-5)

```typescript
1
```

### `Optional`tiles[](#tiles)

tiles?: string\[\]

An array of one or more tile source URLs, as in the TileJSON spec.

### `Optional`tileSize[](#tilesize)

tileSize?: number

The minimum visual size to display tiles for this layer. Only configurable for raster layers.

#### Default[](#default-6)

```typescript
512
```

### type[](#type)

type: "raster-dem"

The type of the source.

### `Optional`url[](#url)

url?: string

A URL to a TileJSON resource. Supported protocols are `http:` and `https:`.

### `Optional`volatile[](#volatile)

volatile?: boolean

A setting to determine whether a source's tiles are cached locally.
