itowns icon indicating copy to clipboard operation
itowns copied to clipboard

feat(TextureSize): Add parameter to define the textureSize

Open AnthonyGlt opened this issue 2 years ago • 2 comments

Related issue:

https://github.com/iTowns/itowns/issues/2292 https://github.com/iTowns/itowns/issues/2312 https://github.com/iTowns/itowns/issues/2309

Replace the const use for subdivision and texture conversion with a customizable parameter sizeTextureTile

Example: For MVT layer

 const mvtSource = new itowns.VectorTilesSource({
              style: 'https://data.geopf.fr/annexes/ressources/vectorTiles/styles/PLAN.IGN/standard.json',
              crs: 'EPSG:3857',

          });

  const mvtLayer = new itowns.ColorLayer('mvtLayer',{
      source: mvtSource,
      sizeTextureTile:512,
      addLabelLayer: true,

  });

For the globe:

const view = new itowns.GlobeView(viewerDiv, placement, {sizeTextureTile:512});

AnthonyGlt avatar Mar 18 '24 08:03 AnthonyGlt

We'll keep it in the layer because we have access to the globe layer from there and then we can affect the tile size for the subdivision. (TODO put a comment in the code)

AnthonyGlt avatar May 02 '24 08:05 AnthonyGlt

I agree, the name should be changed. subdivisionThreshold is more appropriate but there is sseSubdivisionThreshold already existing.

AnthonyGlt avatar May 23 '24 09:05 AnthonyGlt