@loaders.gl/tile-converter 3.1.0-beta.1 → 3.1.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.js +2 -13
- package/dist/converter.min.js +292 -0
- package/dist/es5/i3s-converter/helpers/geometry-converter.js +2 -18
- package/dist/es5/i3s-converter/helpers/geometry-converter.js.map +1 -1
- package/dist/es5/pgm-loader.js +1 -1
- package/dist/esm/i3s-converter/helpers/geometry-converter.js +2 -18
- package/dist/esm/i3s-converter/helpers/geometry-converter.js.map +1 -1
- package/dist/esm/pgm-loader.js +1 -1
- package/package.json +14 -14
- package/src/i3s-converter/helpers/geometry-converter.js +5 -13
package/dist/bundle.js
CHANGED
|
@@ -82009,19 +82009,6 @@ function convertAttributes(tileContent) {
|
|
|
82009
82009
|
attributesMap.delete(attrKey);
|
|
82010
82010
|
continue;
|
|
82011
82011
|
}
|
|
82012
|
-
const vertexCount = attributes.positions.length / VALUES_PER_VERTEX2;
|
|
82013
|
-
if (!attributes.colors.length) {
|
|
82014
|
-
attributes.colors = new Uint8Array(vertexCount * VALUES_PER_COLOR_ELEMENT);
|
|
82015
|
-
for (let index = 0; index < attributes.colors.length; index += 4) {
|
|
82016
|
-
attributes.colors.set([255, 255, 255, 255], index);
|
|
82017
|
-
}
|
|
82018
|
-
}
|
|
82019
|
-
if (!attributes.texCoords.length) {
|
|
82020
|
-
attributes.texCoords = new Float32Array(vertexCount * VALUES_PER_TEX_COORD);
|
|
82021
|
-
for (let index = 0; index < attributes.texCoords.length; index += 2) {
|
|
82022
|
-
attributes.texCoords.set([1, 1], index);
|
|
82023
|
-
}
|
|
82024
|
-
}
|
|
82025
82012
|
attributes.featureIndices = attributes.featureIndices.reduce((acc, value) => acc.concat(value));
|
|
82026
82013
|
}
|
|
82027
82014
|
return attributesMap;
|
|
@@ -82111,6 +82098,7 @@ function transformVertexNormals(vertexVector, calleeArgs) {
|
|
|
82111
82098
|
function flattenTexCoords(texCoords, indices) {
|
|
82112
82099
|
const newTexCoords = new Float32Array(indices.length * VALUES_PER_TEX_COORD);
|
|
82113
82100
|
if (!texCoords) {
|
|
82101
|
+
newTexCoords.fill(1);
|
|
82114
82102
|
return newTexCoords;
|
|
82115
82103
|
}
|
|
82116
82104
|
for (let i = 0; i < indices.length; i++) {
|
|
@@ -82125,6 +82113,7 @@ function flattenColors(colorsAttribute, indices) {
|
|
|
82125
82113
|
const components = colorsAttribute?.components || VALUES_PER_COLOR_ELEMENT;
|
|
82126
82114
|
const newColors = new Uint8Array(indices.length * components);
|
|
82127
82115
|
if (!colorsAttribute) {
|
|
82116
|
+
newColors.fill(255);
|
|
82128
82117
|
return newColors;
|
|
82129
82118
|
}
|
|
82130
82119
|
const colors = colorsAttribute.value;
|