From 5ec4b95cb080de0385f65ef3c416e815c7f5969a Mon Sep 17 00:00:00 2001 From: Phil Varner Date: Mon, 24 Jul 2023 14:35:43 -0400 Subject: [PATCH] Revert "fix titiler parameters for 0.11.x api" This reverts commit 124f799096effc9001193a20af48ac96021e6bb5. --- CHANGELOG.md | 10 ---------- README.md | 16 ---------------- src/utils/mapHelper.js | 7 +++++-- 3 files changed, 5 insertions(+), 28 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6b0838d8..70b65cb2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,16 +5,6 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). -## Unreleased - -## Fixed - -- Parameters used by scene tiling updated for TiTiler 0.11.x. Previously, parameters - were for TiTiler 0.6.0. The `bidx` - parameter was named `asset_bidx` and the `assets` parameter was to be passed once for - each value instead of with a comma-separated list of values. It is unknown when these - parameters changed, but it is recommended that TiTiler >= 0.11.x is used. - ## 2.1.0 ### Changed diff --git a/README.md b/README.md index 95202445..1cd4f24e 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,6 @@ - [Summary](#summary) - [Screenshots](#screenshots) - [Running](#running) - - [TiTiler](#titiler) - [Environment Files](#environment-files) - [Links](#links) - [Scripts](#scripts) @@ -54,21 +53,6 @@ Sentinel-2 L2A Mosaic View ## Running -### TiTiler - -The scene and mosaic views require instances of TiTiler be deployed and configured. - -The configuration `SCENE_TILER_URL` must be pointed at a TiTiler deployment. At -least 0.11.x is recommended, but this may work with other versions 0.7.x and greater. - -The configuration `MOSAIC_TILER_URL` must be pointed at a deployment of the -[Element 84 TiTiler MosaicJSON fork](https://github.com/Element84/titiler-mosaicjson) -of the [NASA IMPACT Titiler fork](https://github.com/NASA-IMPACT/titiler). This -adds support for creating mosaics from STAC API searches to Titiler. - -If the Mosiac TiTiler is deployed, it can be used for both the scene and mosaic tiler URL -configurations. - ### Environment Files For local development, you should create an `.env` & `./src/assets/config.js` file with appropriate variables outlined in the table below. diff --git a/src/utils/mapHelper.js b/src/utils/mapHelper.js index 744be6a8..7f43bb2a 100644 --- a/src/utils/mapHelper.js +++ b/src/utils/mapHelper.js @@ -410,7 +410,10 @@ const constructSceneAssetsParam = (collection, tilerParams) => { console.log(`Assets not defined for ${collection}`) return [null, ''] } - return [assets[0], `assets=${assets.join(',')}`] + // titiler accepts multiple `assets` parameters for compositing + // multiple files, so add extra params here if there's more than + // one asset specified + return [assets[0], `assets=${assets.join('&assets=')}`] } const parameters = { @@ -435,7 +438,7 @@ const parameters = { // for scene tiler if (asset) { const assetBidx = asset && value ? `${asset}|${value}` : null - return assetBidx && `bidx=${assetBidx}` + return assetBidx && `asset_bidx=${assetBidx}` } else { return value && `bidx=${value}` }