@geoinsight/react-components 1.0.5 → 1.0.6
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/.pnp.cjs +1745 -3344
- package/.yarn/install-state.gz +0 -0
- package/.yarn/unplugged/{@swc-core-linux-x64-gnu-npm-1.3.106-7bb327124d → @swc-core-linux-x64-gnu-npm-1.4.0-07735121da}/node_modules/@swc/core-linux-x64-gnu/package.json +1 -1
- package/.yarn/unplugged/{@swc-core-linux-x64-gnu-npm-1.3.106-7bb327124d → @swc-core-linux-x64-gnu-npm-1.4.0-07735121da}/node_modules/@swc/core-linux-x64-gnu/swc.linux-x64-gnu.node +0 -0
- package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/CHANGELOG.md +70 -85
- package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/package.json +11 -11
- package/dist/cjs/index.css +0 -164
- package/dist/cjs/index.d.ts +0 -3
- package/dist/cjs/index.js +46 -211
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.css +0 -164
- package/dist/esm/index.d.ts +0 -3
- package/dist/esm/index.js +48 -190
- package/dist/esm/index.js.map +1 -1
- package/package.json +1 -5
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/.ready +0 -0
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/LICENSE.txt +0 -116
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/README.md +0 -149
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/banner.ts +0 -4
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/check-bundle-size.js +0 -77
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/generate-debug-index-file.ts +0 -19
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/generate-query-test-fixtures.ts +0 -126
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/generate-shaders.ts +0 -35
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/generate-struct-arrays.ts +0 -437
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/generate-style-code.ts +0 -280
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/generate-style-spec.ts +0 -323
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/generate-typings.ts +0 -26
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/readme.md +0 -52
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/release-notes.js +0 -45
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/rollup_plugin_minify_style_spec.ts +0 -25
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/build/rollup_plugins.ts +0 -52
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl-csp-worker.js +0 -2
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl-csp-worker.js.map +0 -1
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl-csp.js +0 -2
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl-csp.js.map +0 -1
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl-dev.js +0 -51935
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl.css +0 -1
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl.d.ts +0 -11736
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl.js +0 -44
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/maplibre-gl.js.map +0 -1
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/package.json +0 -1
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/dist/style-spec/index.d.ts +0 -1768
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/package.json +0 -182
- package/.yarn/unplugged/maplibre-gl-npm-2.4.0-9fa603cf50/node_modules/maplibre-gl/postinstall.js +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/.editorconfig +0 -7
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/.ready +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/LICENSE +0 -21
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/README.md +0 -108
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/darwin/LICENSE-PVRTexToolCLI.txt +0 -52
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/darwin/LICENSE-astcenc.txt +0 -137
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/darwin/LICENSE-crunch.txt +0 -25
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/darwin/PVRTexToolCLI +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/darwin/astcenc +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/darwin/crunch +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/linux/LICENSE-PVRTexToolCLI.txt +0 -52
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/linux/LICENSE-astcenc.txt +0 -137
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/linux/LICENSE-crunch.txt +0 -25
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/linux/PVRTexToolCLI +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/linux/astcenc +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/linux/crunch +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/texture-compressor.js +0 -3
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/win32/LICENSE-PVRTexToolCLI.txt +0 -52
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/win32/LICENSE-astcenc.txt +0 -137
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/win32/LICENSE-crunch.txt +0 -25
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/win32/PVRTexToolCLI.exe +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/win32/astcenc.exe +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/bin/win32/crunch.exe +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/argsHandler.js +0 -101
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/argsHandler.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/compressWithCrunch.js +0 -48
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/compressWithCrunch.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/compressWithPVRTexTool.js +0 -51
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/compressWithPVRTexTool.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/spawnProcess.js +0 -45
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/spawnProcess.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/validateArgs.js +0 -36
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/compressors/validateArgs.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/constants.js +0 -85
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/constants.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/index.js +0 -33
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/index.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/utilities.js +0 -52
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/lib/utilities.js.map +0 -1
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/cli/package.json +0 -37
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/argsHandler.d.ts +0 -14
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/compressors/compressWithCrunch.d.ts +0 -5
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/compressors/compressWithPVRTexTool.d.ts +0 -5
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/compressors/spawnProcess.d.ts +0 -9
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/compressors/validateArgs.d.ts +0 -11
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/constants.d.ts +0 -45
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/index.d.ts +0 -5
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/dist/types/lib/utilities.d.ts +0 -43
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/RECOMMENDED_PARAMETERS.md +0 -17
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/SUPPORTED_DEVICES_TABLE.md +0 -47
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/SUPPORTED_PARAMETERS.md +0 -154
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/KTXLoader.js +0 -149
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-astc-4x4.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-astc-8x8.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-dxt1.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-dxt1A.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-dxt3.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-dxt5.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-etc1.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-etc2.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-etc2A.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-pvrtc2BPP.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-pvrtc2BPPA.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-pvrtc4BPP.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/flippedY-mipmaps/example-pvrtc4BPPA.ktx +0 -0
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/data/main.js +0 -195
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/docs/index.html +0 -37
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/argsHandler.ts +0 -135
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/compressors/compressWithCrunch.ts +0 -66
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/compressors/compressWithPVRTexTool.ts +0 -91
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/compressors/spawnProcess.ts +0 -57
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/compressors/validateArgs.ts +0 -53
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/constants.ts +0 -86
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/index.ts +0 -37
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/lib/utilities.ts +0 -57
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/package.json +0 -37
- package/.yarn/unplugged/texture-compressor-npm-1.0.2-c655a54095/node_modules/texture-compressor/tslint.json +0 -12
- /package/.yarn/unplugged/{@swc-core-linux-x64-gnu-npm-1.3.106-7bb327124d → @swc-core-linux-x64-gnu-npm-1.4.0-07735121da}/node_modules/@swc/core-linux-x64-gnu/.ready +0 -0
- /package/.yarn/unplugged/{@swc-core-linux-x64-gnu-npm-1.3.106-7bb327124d → @swc-core-linux-x64-gnu-npm-1.4.0-07735121da}/node_modules/@swc/core-linux-x64-gnu/README.md +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/.ready +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/LICENSE +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/README.md +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/Visitor.d.ts +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/Visitor.js +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/binding.d.ts +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/binding.js +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/bindings/README.md +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/bindings/binding_core_wasm/package.json +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/index.d.ts +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/index.js +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/postinstall.js +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/spack.d.ts +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/spack.js +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/util.d.ts +0 -0
- /package/.yarn/unplugged/{@swc-core-virtual-22cde85fc1 → @swc-core-virtual-a4869543ec}/node_modules/@swc/core/util.js +0 -0
|
@@ -1,154 +0,0 @@
|
|
|
1
|
-
# Supported parameters
|
|
2
|
-
|
|
3
|
-
## ASTC
|
|
4
|
-
|
|
5
|
-
- Compression tool: PVRTexTool (http://cdn.imgtec.com/sdk-documentation/PVRTexTool.User+Manual.pdf)
|
|
6
|
-
- Compression tool: ASTCenc (https://github.com/ARM-software/astc-encoder)
|
|
7
|
-
- WebGL extension: https://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_astc/
|
|
8
|
-
|
|
9
|
-
Supported input types:
|
|
10
|
-
|
|
11
|
-
```
|
|
12
|
-
.jpeg
|
|
13
|
-
.jpg
|
|
14
|
-
.png
|
|
15
|
-
.bmp
|
|
16
|
-
.gif
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
Supported compression types:
|
|
20
|
-
|
|
21
|
-
```
|
|
22
|
-
ASTC_4x4
|
|
23
|
-
ASTC_5x4
|
|
24
|
-
ASTC_5x5
|
|
25
|
-
ASTC_6x5
|
|
26
|
-
ASTC_6x6
|
|
27
|
-
ASTC_8x5
|
|
28
|
-
ASTC_8x6
|
|
29
|
-
ASTC_8x8
|
|
30
|
-
ASTC_10x5
|
|
31
|
-
ASTC_10x6
|
|
32
|
-
ASTC_10x8
|
|
33
|
-
ASTC_10x10
|
|
34
|
-
ASTC_12x10
|
|
35
|
-
ASTC_12x12
|
|
36
|
-
ASTC_3x3x3
|
|
37
|
-
ASTC_4x3x3
|
|
38
|
-
ASTC_4x4x3
|
|
39
|
-
ASTC_4x4x4
|
|
40
|
-
ASTC_5x4x4
|
|
41
|
-
ASTC_5x5x4
|
|
42
|
-
ASTC_5x5x5
|
|
43
|
-
ASTC_6x5x5
|
|
44
|
-
ASTC_6x6x5
|
|
45
|
-
ASTC_6x6x6
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
Supported quality types:
|
|
49
|
-
|
|
50
|
-
```
|
|
51
|
-
astcveryfast
|
|
52
|
-
astcfast
|
|
53
|
-
astcmedium
|
|
54
|
-
astcthorough
|
|
55
|
-
astcexhaustive
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
## ETC
|
|
59
|
-
|
|
60
|
-
- Compression tool: PVRTexTool (http://cdn.imgtec.com/sdk-documentation/PVRTexTool.User+Manual.pdf)
|
|
61
|
-
- WebGL extension: https://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_etc/
|
|
62
|
-
|
|
63
|
-
Supported input types:
|
|
64
|
-
|
|
65
|
-
```
|
|
66
|
-
.jpeg
|
|
67
|
-
.jpg
|
|
68
|
-
.png
|
|
69
|
-
.bmp
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
Supported compression types:
|
|
73
|
-
|
|
74
|
-
```
|
|
75
|
-
ETC1
|
|
76
|
-
ETC2_RGBA
|
|
77
|
-
ETC2_RGB
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
Supported quality types:
|
|
81
|
-
|
|
82
|
-
```
|
|
83
|
-
etcfast
|
|
84
|
-
etcslow
|
|
85
|
-
etcfastperceptual
|
|
86
|
-
etcslowperceptual
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
## PVRTC
|
|
90
|
-
|
|
91
|
-
- Compression tool: PVRTexTool (http://cdn.imgtec.com/sdk-documentation/PVRTexTool.User+Manual.pdf)
|
|
92
|
-
- WebGL extension: http://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_pvrtc/
|
|
93
|
-
|
|
94
|
-
Supported input types:
|
|
95
|
-
|
|
96
|
-
```
|
|
97
|
-
.jpeg
|
|
98
|
-
.jpg
|
|
99
|
-
.png
|
|
100
|
-
.bmp
|
|
101
|
-
```
|
|
102
|
-
|
|
103
|
-
Supported compression types:
|
|
104
|
-
|
|
105
|
-
```
|
|
106
|
-
PVRTC1_2
|
|
107
|
-
PVRTC1_4
|
|
108
|
-
PVRTC1_2_RGB
|
|
109
|
-
PVRTC1_4_RGB
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
Supported quality types:
|
|
113
|
-
|
|
114
|
-
```
|
|
115
|
-
pvrtcfastest
|
|
116
|
-
pvrtcfast
|
|
117
|
-
pvrtcnormal
|
|
118
|
-
pvrtchigh
|
|
119
|
-
pvrtcbest
|
|
120
|
-
```
|
|
121
|
-
|
|
122
|
-
## S3TC
|
|
123
|
-
|
|
124
|
-
- Compression tool: Crunch (https://github.com/BinomialLLC/crunch/blob/235946f7a1cf8b9c97e8bf0e8062d5439a51dec7/crunch/crunch.cpp#L70-L181)
|
|
125
|
-
- WebGL extension: http://www.khronos.org/registry/webgl/extensions/WEBGL_compressed_texture_s3tc/
|
|
126
|
-
|
|
127
|
-
Supported input types:
|
|
128
|
-
|
|
129
|
-
```
|
|
130
|
-
.jpeg
|
|
131
|
-
.jpg
|
|
132
|
-
.png
|
|
133
|
-
.bmp
|
|
134
|
-
.gif
|
|
135
|
-
```
|
|
136
|
-
|
|
137
|
-
Supported compression types:
|
|
138
|
-
|
|
139
|
-
```
|
|
140
|
-
DXT1
|
|
141
|
-
DXT1A
|
|
142
|
-
DXT3
|
|
143
|
-
DXT5
|
|
144
|
-
```
|
|
145
|
-
|
|
146
|
-
Supported quality types:
|
|
147
|
-
|
|
148
|
-
```
|
|
149
|
-
superfast
|
|
150
|
-
fast
|
|
151
|
-
normal
|
|
152
|
-
better
|
|
153
|
-
uber
|
|
154
|
-
```
|
|
@@ -1,149 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @author amakaseev / https://github.com/amakaseev
|
|
3
|
-
*
|
|
4
|
-
* for description see https://www.khronos.org/opengles/sdk/tools/KTX/
|
|
5
|
-
* for file layout see https://www.khronos.org/opengles/sdk/tools/KTX/file_format_spec/
|
|
6
|
-
*
|
|
7
|
-
* ported from https://github.com/BabylonJS/Babylon.js/blob/master/src/Tools/babylon.khronosTextureContainer.ts
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
THREE.KTXLoader = function(manager) {
|
|
11
|
-
THREE.CompressedTextureLoader.call(this, manager);
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
THREE.KTXLoader.prototype = Object.assign(Object.create(THREE.CompressedTextureLoader.prototype), {
|
|
15
|
-
constructor: THREE.KTXLoader,
|
|
16
|
-
|
|
17
|
-
parse: function(buffer, loadMipmaps) {
|
|
18
|
-
var ktx = new KhronosTextureContainer(buffer, 1);
|
|
19
|
-
|
|
20
|
-
return {
|
|
21
|
-
mipmaps: ktx.mipmaps(loadMipmaps),
|
|
22
|
-
width: ktx.pixelWidth,
|
|
23
|
-
height: ktx.pixelHeight,
|
|
24
|
-
format: ktx.glInternalFormat,
|
|
25
|
-
isCubemap: ktx.numberOfFaces === 6,
|
|
26
|
-
mipmapCount: ktx.numberOfMipmapLevels,
|
|
27
|
-
};
|
|
28
|
-
},
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
var KhronosTextureContainer = (function() {
|
|
32
|
-
/**
|
|
33
|
-
* @param {ArrayBuffer} arrayBuffer- contents of the KTX container file
|
|
34
|
-
* @param {number} facesExpected- should be either 1 or 6, based whether a cube texture or or
|
|
35
|
-
* @param {boolean} threeDExpected- provision for indicating that data should be a 3D texture, not implemented
|
|
36
|
-
* @param {boolean} textureArrayExpected- provision for indicating that data should be a texture array, not implemented
|
|
37
|
-
*/
|
|
38
|
-
function KhronosTextureContainer(
|
|
39
|
-
arrayBuffer,
|
|
40
|
-
facesExpected /*, threeDExpected, textureArrayExpected */
|
|
41
|
-
) {
|
|
42
|
-
this.arrayBuffer = arrayBuffer;
|
|
43
|
-
|
|
44
|
-
// Test that it is a ktx formatted file, based on the first 12 bytes, character representation is:
|
|
45
|
-
// '´', 'K', 'T', 'X', ' ', '1', '1', 'ª', '\r', '\n', '\x1A', '\n'
|
|
46
|
-
// 0xAB, 0x4B, 0x54, 0x58, 0x20, 0x31, 0x31, 0xBB, 0x0D, 0x0A, 0x1A, 0x0A
|
|
47
|
-
var identifier = new Uint8Array(this.arrayBuffer, 0, 12);
|
|
48
|
-
if (
|
|
49
|
-
identifier[0] !== 0xab ||
|
|
50
|
-
identifier[1] !== 0x4b ||
|
|
51
|
-
identifier[2] !== 0x54 ||
|
|
52
|
-
identifier[3] !== 0x58 ||
|
|
53
|
-
identifier[4] !== 0x20 ||
|
|
54
|
-
identifier[5] !== 0x31 ||
|
|
55
|
-
identifier[6] !== 0x31 ||
|
|
56
|
-
identifier[7] !== 0xbb ||
|
|
57
|
-
identifier[8] !== 0x0d ||
|
|
58
|
-
identifier[9] !== 0x0a ||
|
|
59
|
-
identifier[10] !== 0x1a ||
|
|
60
|
-
identifier[11] !== 0x0a
|
|
61
|
-
) {
|
|
62
|
-
console.error('texture missing KTX identifier');
|
|
63
|
-
return;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
// load the reset of the header in native 32 bit uint
|
|
67
|
-
var dataSize = Uint32Array.BYTES_PER_ELEMENT;
|
|
68
|
-
var headerDataView = new DataView(this.arrayBuffer, 12, 13 * dataSize);
|
|
69
|
-
var endianness = headerDataView.getUint32(0, true);
|
|
70
|
-
var littleEndian = endianness === 0x04030201;
|
|
71
|
-
|
|
72
|
-
this.glType = headerDataView.getUint32(1 * dataSize, littleEndian); // must be 0 for compressed textures
|
|
73
|
-
this.glTypeSize = headerDataView.getUint32(2 * dataSize, littleEndian); // must be 1 for compressed textures
|
|
74
|
-
this.glFormat = headerDataView.getUint32(3 * dataSize, littleEndian); // must be 0 for compressed textures
|
|
75
|
-
this.glInternalFormat = headerDataView.getUint32(4 * dataSize, littleEndian); // the value of arg passed to gl.compressedTexImage2D(,,x,,,,)
|
|
76
|
-
this.glBaseInternalFormat = headerDataView.getUint32(5 * dataSize, littleEndian); // specify GL_RGB, GL_RGBA, GL_ALPHA, etc (un-compressed only)
|
|
77
|
-
this.pixelWidth = headerDataView.getUint32(6 * dataSize, littleEndian); // level 0 value of arg passed to gl.compressedTexImage2D(,,,x,,,)
|
|
78
|
-
this.pixelHeight = headerDataView.getUint32(7 * dataSize, littleEndian); // level 0 value of arg passed to gl.compressedTexImage2D(,,,,x,,)
|
|
79
|
-
this.pixelDepth = headerDataView.getUint32(8 * dataSize, littleEndian); // level 0 value of arg passed to gl.compressedTexImage3D(,,,,,x,,)
|
|
80
|
-
this.numberOfArrayElements = headerDataView.getUint32(9 * dataSize, littleEndian); // used for texture arrays
|
|
81
|
-
this.numberOfFaces = headerDataView.getUint32(10 * dataSize, littleEndian); // used for cubemap textures, should either be 1 or 6
|
|
82
|
-
this.numberOfMipmapLevels = headerDataView.getUint32(11 * dataSize, littleEndian); // number of levels; disregard possibility of 0 for compressed textures
|
|
83
|
-
this.bytesOfKeyValueData = headerDataView.getUint32(12 * dataSize, littleEndian); // the amount of space after the header for meta-data
|
|
84
|
-
|
|
85
|
-
// Make sure we have a compressed type. Not only reduces work, but probably better to let dev know they are not compressing.
|
|
86
|
-
if (this.glType !== 0) {
|
|
87
|
-
console.warn('only compressed formats currently supported');
|
|
88
|
-
return;
|
|
89
|
-
} else {
|
|
90
|
-
// value of zero is an indication to generate mipmaps @ runtime. Not usually allowed for compressed, so disregard.
|
|
91
|
-
this.numberOfMipmapLevels = Math.max(1, this.numberOfMipmapLevels);
|
|
92
|
-
}
|
|
93
|
-
if (this.pixelHeight === 0 || this.pixelDepth !== 0) {
|
|
94
|
-
console.warn('only 2D textures currently supported');
|
|
95
|
-
return;
|
|
96
|
-
}
|
|
97
|
-
if (this.numberOfArrayElements !== 0) {
|
|
98
|
-
console.warn('texture arrays not currently supported');
|
|
99
|
-
return;
|
|
100
|
-
}
|
|
101
|
-
if (this.numberOfFaces !== facesExpected) {
|
|
102
|
-
console.warn(
|
|
103
|
-
'number of faces expected' + facesExpected + ', but found ' + this.numberOfFaces
|
|
104
|
-
);
|
|
105
|
-
return;
|
|
106
|
-
}
|
|
107
|
-
// we now have a completely validated file, so could use existence of loadType as success
|
|
108
|
-
// would need to make this more elaborate & adjust checks above to support more than one load type
|
|
109
|
-
this.loadType = KhronosTextureContainer.COMPRESSED_2D;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
// return mipmaps for THREE.js
|
|
113
|
-
KhronosTextureContainer.prototype.mipmaps = function(loadMipmaps) {
|
|
114
|
-
var mipmaps = [];
|
|
115
|
-
|
|
116
|
-
// initialize width & height for level 1
|
|
117
|
-
var dataOffset = KhronosTextureContainer.HEADER_LEN + this.bytesOfKeyValueData;
|
|
118
|
-
var width = this.pixelWidth;
|
|
119
|
-
var height = this.pixelHeight;
|
|
120
|
-
var mipmapCount = loadMipmaps ? this.numberOfMipmapLevels : 1;
|
|
121
|
-
|
|
122
|
-
for (var level = 0; level < mipmapCount; level++) {
|
|
123
|
-
var imageSize = new Int32Array(this.arrayBuffer, dataOffset, 1)[0]; // size per face, since not supporting array cubemaps
|
|
124
|
-
dataOffset += 4; // size of the image + 4 for the imageSize field
|
|
125
|
-
|
|
126
|
-
for (var face = 0; face < this.numberOfFaces; face++) {
|
|
127
|
-
var byteArray = new Uint8Array(this.arrayBuffer, dataOffset, imageSize);
|
|
128
|
-
|
|
129
|
-
mipmaps.push({ data: byteArray, width: width, height: height });
|
|
130
|
-
|
|
131
|
-
dataOffset += imageSize;
|
|
132
|
-
dataOffset += 3 - ((imageSize + 3) % 4); // add padding for odd sized image
|
|
133
|
-
}
|
|
134
|
-
width = Math.max(1.0, width * 0.5);
|
|
135
|
-
height = Math.max(1.0, height * 0.5);
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
return mipmaps;
|
|
139
|
-
};
|
|
140
|
-
|
|
141
|
-
KhronosTextureContainer.HEADER_LEN = 12 + 13 * 4; // identifier + header elements (not including key value meta-data pairs)
|
|
142
|
-
// load types
|
|
143
|
-
KhronosTextureContainer.COMPRESSED_2D = 0; // uses a gl.compressedTexImage2D()
|
|
144
|
-
KhronosTextureContainer.COMPRESSED_3D = 1; // uses a gl.compressedTexImage3D()
|
|
145
|
-
KhronosTextureContainer.TEX_2D = 2; // uses a gl.texImage2D()
|
|
146
|
-
KhronosTextureContainer.TEX_3D = 3; // uses a gl.texImage3D()
|
|
147
|
-
|
|
148
|
-
return KhronosTextureContainer;
|
|
149
|
-
})();
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,195 +0,0 @@
|
|
|
1
|
-
var camera, scene, renderer;
|
|
2
|
-
var meshes = [];
|
|
3
|
-
|
|
4
|
-
init();
|
|
5
|
-
animate();
|
|
6
|
-
|
|
7
|
-
function init() {
|
|
8
|
-
var appElement = document.getElementById('app');
|
|
9
|
-
|
|
10
|
-
renderer = new THREE.WebGLRenderer({ antialias: true });
|
|
11
|
-
renderer.setClearColor(0x000000, 1);
|
|
12
|
-
renderer.setPixelRatio(window.devicePixelRatio);
|
|
13
|
-
renderer.setSize(window.innerWidth, window.innerHeight);
|
|
14
|
-
document.body.appendChild(renderer.domElement);
|
|
15
|
-
|
|
16
|
-
var formats = {
|
|
17
|
-
astc: renderer.extensions.get('WEBGL_compressed_texture_astc'),
|
|
18
|
-
etc1: renderer.extensions.get('WEBGL_compressed_texture_etc1'),
|
|
19
|
-
etc2: renderer.extensions.get('WEBGL_compressed_texture_etc'),
|
|
20
|
-
s3tc: renderer.extensions.get('WEBGL_compressed_texture_s3tc'),
|
|
21
|
-
pvrtc: renderer.extensions.get('WEBGL_compressed_texture_pvrtc'),
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
camera = new THREE.PerspectiveCamera(50, window.innerWidth / window.innerHeight, 1, 2000);
|
|
25
|
-
camera.position.z = 1000;
|
|
26
|
-
|
|
27
|
-
scene = new THREE.Scene();
|
|
28
|
-
|
|
29
|
-
var geometry = new THREE.PlaneGeometry(200, 200, 200);
|
|
30
|
-
var material1, material2, material3, material4;
|
|
31
|
-
|
|
32
|
-
var loader = new THREE.KTXLoader();
|
|
33
|
-
|
|
34
|
-
if (formats.astc) {
|
|
35
|
-
material1 = new THREE.MeshBasicMaterial({
|
|
36
|
-
map: loader.load('./data/' + type + '/example-astc-4x4.ktx', function(texture) {
|
|
37
|
-
texture.magFilter = THREE.LinearFilter;
|
|
38
|
-
texture.minFilter =
|
|
39
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
40
|
-
}),
|
|
41
|
-
});
|
|
42
|
-
appElement.appendChild(document.createTextNode(' ASTC-4x4 '));
|
|
43
|
-
meshes.push(new THREE.Mesh(geometry, material1));
|
|
44
|
-
|
|
45
|
-
material2 = new THREE.MeshBasicMaterial({
|
|
46
|
-
map: loader.load('./data/' + type + '/example-astc-8x8.ktx', function(texture) {
|
|
47
|
-
texture.magFilter = THREE.LinearFilter;
|
|
48
|
-
texture.minFilter =
|
|
49
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
50
|
-
}),
|
|
51
|
-
});
|
|
52
|
-
appElement.appendChild(document.createTextNode(' ASTC-8x8 '));
|
|
53
|
-
meshes.push(new THREE.Mesh(geometry, material2));
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
if (formats.etc1) {
|
|
57
|
-
material1 = new THREE.MeshBasicMaterial({
|
|
58
|
-
map: loader.load('./data/' + type + '/example-etc1.ktx', function(texture) {
|
|
59
|
-
texture.magFilter = THREE.LinearFilter;
|
|
60
|
-
texture.minFilter =
|
|
61
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
62
|
-
}),
|
|
63
|
-
});
|
|
64
|
-
appElement.appendChild(document.createTextNode(' ETC1 '));
|
|
65
|
-
meshes.push(new THREE.Mesh(geometry, material1));
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
if (formats.etc2) {
|
|
69
|
-
material1 = new THREE.MeshBasicMaterial({
|
|
70
|
-
map: loader.load('./data/' + type + '/example-etc2.ktx', function(texture) {
|
|
71
|
-
texture.magFilter = THREE.LinearFilter;
|
|
72
|
-
texture.minFilter =
|
|
73
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
74
|
-
}),
|
|
75
|
-
});
|
|
76
|
-
appElement.appendChild(document.createTextNode(' ETC2 '));
|
|
77
|
-
meshes.push(new THREE.Mesh(geometry, material1));
|
|
78
|
-
|
|
79
|
-
material2 = new THREE.MeshBasicMaterial({
|
|
80
|
-
map: loader.load('./data/' + type + '/example-etc2A.ktx', function(texture) {
|
|
81
|
-
texture.magFilter = THREE.LinearFilter;
|
|
82
|
-
texture.minFilter =
|
|
83
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
84
|
-
}),
|
|
85
|
-
});
|
|
86
|
-
appElement.appendChild(document.createTextNode(' ETC2A '));
|
|
87
|
-
meshes.push(new THREE.Mesh(geometry, material2));
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
if (formats.pvrtc) {
|
|
91
|
-
material1 = new THREE.MeshBasicMaterial({
|
|
92
|
-
map: loader.load('./data/' + type + '/example-pvrtc2BPP.ktx', function(texture) {
|
|
93
|
-
texture.magFilter = THREE.LinearFilter;
|
|
94
|
-
texture.minFilter =
|
|
95
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
96
|
-
}),
|
|
97
|
-
});
|
|
98
|
-
appElement.appendChild(document.createTextNode(' PVRTC-2BPP '));
|
|
99
|
-
meshes.push(new THREE.Mesh(geometry, material1));
|
|
100
|
-
|
|
101
|
-
material2 = new THREE.MeshBasicMaterial({
|
|
102
|
-
map: loader.load('./data/' + type + '/example-pvrtc2BPPA.ktx', function(texture) {
|
|
103
|
-
texture.magFilter = THREE.LinearFilter;
|
|
104
|
-
texture.minFilter =
|
|
105
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
106
|
-
}),
|
|
107
|
-
});
|
|
108
|
-
appElement.appendChild(document.createTextNode(' PVRTC-2BPPA '));
|
|
109
|
-
meshes.push(new THREE.Mesh(geometry, material2));
|
|
110
|
-
|
|
111
|
-
material3 = new THREE.MeshBasicMaterial({
|
|
112
|
-
map: loader.load('./data/' + type + '/example-pvrtc4BPP.ktx', function(texture) {
|
|
113
|
-
texture.magFilter = THREE.LinearFilter;
|
|
114
|
-
texture.minFilter =
|
|
115
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
116
|
-
}),
|
|
117
|
-
});
|
|
118
|
-
appElement.appendChild(document.createTextNode(' PVRTC-4BPP '));
|
|
119
|
-
meshes.push(new THREE.Mesh(geometry, material3));
|
|
120
|
-
|
|
121
|
-
material4 = new THREE.MeshBasicMaterial({
|
|
122
|
-
map: loader.load('./data/' + type + '/example-pvrtc4BPPA.ktx', function(texture) {
|
|
123
|
-
texture.magFilter = THREE.LinearFilter;
|
|
124
|
-
texture.minFilter =
|
|
125
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
126
|
-
}),
|
|
127
|
-
});
|
|
128
|
-
appElement.appendChild(document.createTextNode(' PVRTC-4BPPA '));
|
|
129
|
-
meshes.push(new THREE.Mesh(geometry, material4));
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
if (formats.s3tc) {
|
|
133
|
-
material1 = new THREE.MeshBasicMaterial({
|
|
134
|
-
map: loader.load('./data/' + type + '/example-dxt1.ktx', function(texture) {
|
|
135
|
-
texture.magFilter = THREE.LinearFilter;
|
|
136
|
-
texture.minFilter =
|
|
137
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
138
|
-
}),
|
|
139
|
-
});
|
|
140
|
-
appElement.appendChild(document.createTextNode(' DXT1 '));
|
|
141
|
-
meshes.push(new THREE.Mesh(geometry, material1));
|
|
142
|
-
|
|
143
|
-
material2 = new THREE.MeshBasicMaterial({
|
|
144
|
-
map: loader.load('./data/' + type + '/example-dxt1A.ktx', function(texture) {
|
|
145
|
-
texture.magFilter = THREE.LinearFilter;
|
|
146
|
-
texture.minFilter =
|
|
147
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
148
|
-
}),
|
|
149
|
-
});
|
|
150
|
-
appElement.appendChild(document.createTextNode(' DXT1A '));
|
|
151
|
-
meshes.push(new THREE.Mesh(geometry, material2));
|
|
152
|
-
|
|
153
|
-
material3 = new THREE.MeshBasicMaterial({
|
|
154
|
-
map: loader.load('./data/' + type + '/example-dxt3.ktx', function(texture) {
|
|
155
|
-
texture.magFilter = THREE.LinearFilter;
|
|
156
|
-
texture.minFilter =
|
|
157
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
158
|
-
}),
|
|
159
|
-
});
|
|
160
|
-
appElement.appendChild(document.createTextNode(' DXT3 '));
|
|
161
|
-
meshes.push(new THREE.Mesh(geometry, material3));
|
|
162
|
-
|
|
163
|
-
material4 = new THREE.MeshBasicMaterial({
|
|
164
|
-
map: loader.load('./data/' + type + '/example-dxt5.ktx', function(texture) {
|
|
165
|
-
texture.magFilter = THREE.LinearFilter;
|
|
166
|
-
texture.minFilter =
|
|
167
|
-
type === 'flippedY-mipmaps' ? THREE.LinearMipMapLinearFilter : THREE.LinearFilter;
|
|
168
|
-
}),
|
|
169
|
-
});
|
|
170
|
-
appElement.appendChild(document.createTextNode(' DXT5 '));
|
|
171
|
-
meshes.push(new THREE.Mesh(geometry, material4));
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
var x = (-meshes.length / 2) * 225;
|
|
175
|
-
for (var i = 0; i < meshes.length; ++i, x += 300) {
|
|
176
|
-
var mesh = meshes[i];
|
|
177
|
-
mesh.position.x = x;
|
|
178
|
-
mesh.position.y = 0;
|
|
179
|
-
scene.add(mesh);
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
window.addEventListener('resize', onWindowResize, false);
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
function onWindowResize() {
|
|
186
|
-
camera.aspect = window.innerWidth / window.innerHeight;
|
|
187
|
-
camera.updateProjectionMatrix();
|
|
188
|
-
|
|
189
|
-
renderer.setSize(window.innerWidth, window.innerHeight);
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
function animate() {
|
|
193
|
-
requestAnimationFrame(animate);
|
|
194
|
-
renderer.render(scene, camera);
|
|
195
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="UTF-8" />
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
-
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
|
|
7
|
-
<title>Texture compressor</title>
|
|
8
|
-
<style>
|
|
9
|
-
body,
|
|
10
|
-
html {
|
|
11
|
-
font-family: Arial, Helvetica, sans-serif;
|
|
12
|
-
margin: 0;
|
|
13
|
-
padding: 0;
|
|
14
|
-
width: 100%;
|
|
15
|
-
height: 100%;
|
|
16
|
-
background: #fefefe;
|
|
17
|
-
overflow: hidden;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
#app {
|
|
21
|
-
padding-left: 20px;
|
|
22
|
-
}
|
|
23
|
-
</style>
|
|
24
|
-
</head>
|
|
25
|
-
|
|
26
|
-
<body>
|
|
27
|
-
<pre id="app"></pre>
|
|
28
|
-
|
|
29
|
-
<script>
|
|
30
|
-
var type = 'flippedY-mipmaps';
|
|
31
|
-
</script>
|
|
32
|
-
|
|
33
|
-
<script src="https://rawgit.com/mrdoob/three.js/dev/build/three.min.js"></script>
|
|
34
|
-
<script src="./data/KTXLoader.js"></script>
|
|
35
|
-
<script src="./data/main.js"></script>
|
|
36
|
-
</body>
|
|
37
|
-
</html>
|