This commit is contained in:
46
node_modules/lerc/CHANGELOG.md
generated
vendored
Normal file
46
node_modules/lerc/CHANGELOG.md
generated
vendored
Normal file
@@ -0,0 +1,46 @@
|
||||
# Change Log
|
||||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
The format is based on [Keep a Changelog](http://keepachangelog.com/)
|
||||
and this project adheres to [Semantic Versioning](http://semver.org/).
|
||||
|
||||
## [Unreleased][HEAD]
|
||||
|
||||
## [3.0.0] - 2021-07-30
|
||||
|
||||
The decoder is in sync with ArcMap 10.8.1 and ArcGIS Pro 2.8. LERC encoded binary blobs from any previous version of ArcMap or ArcGIS Pro can also be read / decoded.
|
||||
|
||||
### Added
|
||||
* Added an option to return decoded n-dim blob using pixel-interleaved layout
|
||||
|
||||
### Changed
|
||||
* Upgrade Lerc codec to new version Lerc 2.5.
|
||||
|
||||
## [2.0.0] - 2018-11-06
|
||||
|
||||
The decoder is in sync with ArcMap 10.7 and ArcGIS Pro 2.3. LERC encoded binary blobs from any previous version of ArcMap or ArcGIS Pro can also be read / decoded.
|
||||
|
||||
### Added
|
||||
* Extend from one value per pixel to nDim values per pixel.
|
||||
|
||||
### Changed
|
||||
* Upgrade Lerc codec to new version Lerc 2.4.
|
||||
|
||||
## 1.0.1 - 2017-02-18
|
||||
|
||||
### Fixed
|
||||
|
||||
* resolved a Huffman code table parsing issue [#31](https://github.com/Esri/lerc/pull/31)
|
||||
|
||||
## 1.0 - 2016-11-30
|
||||
|
||||
This LERC API JavaScript decoder is in sync with ArcMap 10.5 and ArcGIS Pro 1.4. LERC encoded binary blobs from any previous version of ArcMap or ArcGIS Pro can be read / decoded as well.
|
||||
|
||||
### What will trigger a major version change
|
||||
|
||||
- A change to this LERC API that is not backwards compatible and requires users to update / change their code in order to use an upgraded .dll or .so file.
|
||||
- A change to the LERC bitstream that is not backwards compatible and requires users to upgrade their LERC encoder and / or decoder.
|
||||
|
||||
[2.0.0]: https://github.com/Esri/lerc/compare/v1.0.1...v2.0 "v2.0"
|
||||
[HEAD]: https://github.com/Esri/lerc/compare/v2.0...HEAD "Unreleased Changes"
|
||||
2324
node_modules/lerc/LercDecode.js
generated
vendored
Normal file
2324
node_modules/lerc/LercDecode.js
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
2
node_modules/lerc/LercDecode.min.js
generated
vendored
Normal file
2
node_modules/lerc/LercDecode.min.js
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
60
node_modules/lerc/README.hbs
generated
vendored
Normal file
60
node_modules/lerc/README.hbs
generated
vendored
Normal file
@@ -0,0 +1,60 @@
|
||||
[![npm version][npm-img]][npm-url]
|
||||
|
||||
[npm-img]: https://img.shields.io/npm/v/lerc.svg?style=flat-square
|
||||
[npm-url]: https://www.npmjs.com/package/lerc
|
||||
|
||||
# Lerc JS
|
||||
|
||||
> Rapid decoding of Lerc compressed raster data for any standard pixel type, not just rgb or byte
|
||||
|
||||
## Browser
|
||||
|
||||
```html
|
||||
<script type="text/javascript" src="https://unpkg.com/lerc"></script>
|
||||
```
|
||||
```js
|
||||
Lerc.decode(xhrResponse, {
|
||||
inputOffset: 10, // start from the 10th byte (default is 0)
|
||||
pixelType: "U8", // only needed for lerc1 (default is F32)
|
||||
returnPixelInterleavedDims: false // only applicable to n-dim lerc2 blobs (default is false)
|
||||
});
|
||||
```
|
||||
|
||||
## Node
|
||||
|
||||
```js
|
||||
npm install lerc && npm install node-fetch
|
||||
```
|
||||
```js
|
||||
const fetch = require('node-fetch');
|
||||
const Lerc = require('lerc');
|
||||
|
||||
fetch('http://elevation3d.arcgis.com/arcgis/rest/services/WorldElevation3D/Terrain3D/ImageServer/tile/0/0/0')
|
||||
.then(response => response.arrayBuffer())
|
||||
.then(body => {
|
||||
const image = Lerc.decode(body);
|
||||
image.width // 257
|
||||
});
|
||||
```
|
||||
|
||||
## API Reference
|
||||
|
||||
{{>main}}
|
||||
* * *
|
||||
|
||||
## Licensing
|
||||
|
||||
Copyright © 2017-2021 Esri
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and limitations under the License.
|
||||
|
||||
A local copy of the license and additional notices are located with the source distribution at:
|
||||
|
||||
http://github.com/Esri/lerc/
|
||||
90
node_modules/lerc/README.md
generated
vendored
Normal file
90
node_modules/lerc/README.md
generated
vendored
Normal file
@@ -0,0 +1,90 @@
|
||||
[![npm version][npm-img]][npm-url]
|
||||
|
||||
[npm-img]: https://img.shields.io/npm/v/lerc.svg?style=flat-square
|
||||
[npm-url]: https://www.npmjs.com/package/lerc
|
||||
|
||||
# Lerc JS
|
||||
|
||||
> Rapid decoding of Lerc compressed raster data for any standard pixel type, not just rgb or byte
|
||||
|
||||
## Browser
|
||||
|
||||
```html
|
||||
<script type="text/javascript" src="https://unpkg.com/lerc"></script>
|
||||
```
|
||||
```js
|
||||
Lerc.decode(xhrResponse, {
|
||||
inputOffset: 10, // start from the 10th byte (default is 0)
|
||||
pixelType: "U8", // only needed for lerc1 (default is F32)
|
||||
returnPixelInterleavedDims: false // only applicable to n-dim lerc2 blobs (default is false)
|
||||
});
|
||||
```
|
||||
|
||||
## Node
|
||||
|
||||
```js
|
||||
npm install lerc && npm install node-fetch
|
||||
```
|
||||
```js
|
||||
const fetch = require('node-fetch');
|
||||
const Lerc = require('lerc');
|
||||
|
||||
fetch('http://elevation3d.arcgis.com/arcgis/rest/services/WorldElevation3D/Terrain3D/ImageServer/tile/0/0/0')
|
||||
.then(response => response.arrayBuffer())
|
||||
.then(body => {
|
||||
const image = Lerc.decode(body);
|
||||
image.width // 257
|
||||
});
|
||||
```
|
||||
|
||||
## API Reference
|
||||
|
||||
<a name="module_Lerc"></a>
|
||||
|
||||
## Lerc
|
||||
a module for decoding LERC blobs
|
||||
|
||||
<a name="exp_module_Lerc--decode"></a>
|
||||
|
||||
### decode(input, [options]) ⇒ <code>Object</code> ⏏
|
||||
A wrapper for decoding both LERC1 and LERC2 byte streams capable of handling multiband pixel blocks for various pixel types.
|
||||
|
||||
**Kind**: Exported function
|
||||
|
||||
| Param | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| input | <code>ArrayBuffer</code> | The LERC input byte stream |
|
||||
| [options] | <code>object</code> | The decoding options below are optional. |
|
||||
| [options.inputOffset] | <code>number</code> | The number of bytes to skip in the input byte stream. A valid Lerc file is expected at that position. |
|
||||
| [options.pixelType] | <code>string</code> | (LERC1 only) Default value is F32. Valid pixel types for input are U8/S8/S16/U16/S32/U32/F32. |
|
||||
| [options.noDataValue] | <code>number</code> | (LERC1 only). It is recommended to use the returned mask instead of setting this value. |
|
||||
|
||||
**Result Object Properties**
|
||||
|
||||
| Name | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| width | <code>number</code> | Width of decoded image. |
|
||||
| height | <code>number</code> | Height of decoded image. |
|
||||
| pixels | <code>array</code> | [band1, band2, …] Each band is a typed array of width*height. |
|
||||
| pixelType | <code>string</code> | The type of pixels represented in the output. |
|
||||
| mask | <code>mask</code> | Typed array with a size of width*height, or null if all pixels are valid. |
|
||||
| statistics | <code>array</code> | [statistics_band1, statistics_band2, …] Each element is a statistics object representing min and max values |
|
||||
|
||||
* * *
|
||||
|
||||
## Licensing
|
||||
|
||||
Copyright © 2017-2021 Esri
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and limitations under the License.
|
||||
|
||||
A local copy of the license and additional notices are located with the source distribution at:
|
||||
|
||||
http://github.com/Esri/lerc/
|
||||
39
node_modules/lerc/package.json
generated
vendored
Normal file
39
node_modules/lerc/package.json
generated
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
{
|
||||
"name": "lerc",
|
||||
"browser": "LercDecode.js",
|
||||
"bugs": {
|
||||
"url": "https://github.com/esri/lerc/issues"
|
||||
},
|
||||
"description": "Rapid decoding of Lerc compressed raster data for any standard pixel type.",
|
||||
"version": "3.0.0",
|
||||
"author": "Esri <dev_tools@esri.com> (http://developers.arcgis.com)",
|
||||
"contributors": [
|
||||
"Johannes Schmid",
|
||||
"Chayanika Khatua",
|
||||
"Wenxue Ju"
|
||||
],
|
||||
"devDependencies": {
|
||||
"gh-release": "^2.2.1",
|
||||
"jsdoc-to-markdown": "^2.0.1",
|
||||
"jshint": "^2.13.0",
|
||||
"uglify-js": "^3.14.0"
|
||||
},
|
||||
"files": [
|
||||
"LercDecode.js",
|
||||
"LercDecode.min.js"
|
||||
],
|
||||
"homepage": "https://github.com/Esri/lerc",
|
||||
"license": "Apache-2.0",
|
||||
"main": "LercDecode.js",
|
||||
"readmeFilename": "README.md",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Esri/lerc.git"
|
||||
},
|
||||
"scripts": {
|
||||
"lint": "jshint LercDecode.js",
|
||||
"build": "uglifyjs LercDecode.js -o LercDecode.min.js --comments",
|
||||
"docs": "jsdoc2md --template README.hbs --files LercDecode.js",
|
||||
"release": "./release.sh"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user