@woosh/meep-engine 2.34.32 → 2.34.33
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/engine/Engine.js +5 -0
- package/engine/development/performance/AbstractMetric.js +4 -0
- package/engine/development/performance/RingBufferMetric.js +4 -0
- package/engine/graphics/ecs/mesh-v2/ShadedGeometrySystem.js +3 -0
- package/engine/graphics/micron/build/fill_patch_geometry_data.js +7 -6
- package/package.json +1 -1
package/engine/Engine.js
CHANGED
|
@@ -130,30 +130,31 @@ const DataConverterType = {
|
|
|
130
130
|
* @returns {DataConverterType}
|
|
131
131
|
*/
|
|
132
132
|
function compute_attribute_data_converter(source, spec) {
|
|
133
|
-
|
|
133
|
+
const target_type = spec.type;
|
|
134
|
+
if (target_type === DataType.Float16) {
|
|
134
135
|
return DataConverterType.Number2HalfFloat;
|
|
135
136
|
} else if (spec.normalized && !source.normalized) {
|
|
136
137
|
// source data can be normalized but isn't
|
|
137
|
-
if (
|
|
138
|
+
if (target_type === DataType.Int8) {
|
|
138
139
|
return DataConverterType.Normalize2Int8;
|
|
139
140
|
} else {
|
|
140
|
-
throw new Error(`Unsupported normalized type '${
|
|
141
|
+
throw new Error(`Unsupported normalized type '${target_type}'`);
|
|
141
142
|
}
|
|
142
143
|
} else {
|
|
143
144
|
const source_array = source.array;
|
|
144
145
|
|
|
145
146
|
const source_type = typedArrayToDataType(source_array);
|
|
146
147
|
|
|
147
|
-
const target_byte_size = dataTypeByteSize(
|
|
148
|
+
const target_byte_size = dataTypeByteSize(target_type);
|
|
148
149
|
const source_byte_size = dataTypeByteSize(source_type)
|
|
149
150
|
|
|
150
151
|
if (target_byte_size !== source_byte_size) {
|
|
151
152
|
// wrong data size
|
|
152
153
|
|
|
153
|
-
if (
|
|
154
|
+
if (target_type === DataType.Uint8 && source_type === DataType.Uint16) {
|
|
154
155
|
return DataConverterType.ResampleNormalized_Uint16_to_Uint8;
|
|
155
156
|
} else {
|
|
156
|
-
throw new Error(`Unsupported conversion ${source_type} -> `);
|
|
157
|
+
throw new Error(`Unsupported conversion ${source_type} -> ${target_type}`);
|
|
157
158
|
}
|
|
158
159
|
|
|
159
160
|
} else {
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"productName": "Meep",
|
|
6
6
|
"description": "production-ready JavaScript game engine based on Entity Component System Architecture",
|
|
7
7
|
"author": "Alexander Goldring",
|
|
8
|
-
"version": "2.34.
|
|
8
|
+
"version": "2.34.33",
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"gl-matrix": "3.4.3",
|
|
11
11
|
"fast-levenshtein": "2.0.6",
|