@playcanvas/splat-transform 0.1.3 → 0.2.0
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/README.md +38 -1
- package/dist/index.mjs +2934 -818
- package/dist/index.mjs.map +1 -1
- package/package.json +13 -11
package/README.md
CHANGED
|
@@ -1,7 +1,44 @@
|
|
|
1
1
|
# Splat Transform - 3D Gaussian Splat Converter
|
|
2
2
|
|
|
3
|
-
Splat Transform is an open source CLI tool for
|
|
3
|
+
Splat Transform is an open source CLI tool for reading gaussian splat PLY files and writing them to PLY, compressed.ply and SOGS format.
|
|
4
4
|
|
|
5
|
+
Multiple files may be combined and transformed before being written to the output.
|
|
6
|
+
|
|
7
|
+
## Installation
|
|
8
|
+
First install the package globally:
|
|
9
|
+
```
|
|
10
|
+
npm install -g @playcanvas/splat-transform
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Then invoke the CLI from anywhere as follows:
|
|
14
|
+
```bash
|
|
15
|
+
# combine input_a.ply and input_b.ply and write the result to compressed ply format
|
|
16
|
+
splat-transform input_a.ply input_b.ply output.compressed.ply
|
|
17
|
+
|
|
18
|
+
# read input_a.ply and input_b.ply and write the result in SOGS format
|
|
19
|
+
splat-transform input_a.ply input_b.ply output/meta.json
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
The input and output files can optionally be transformed. For example:
|
|
23
|
+
```
|
|
24
|
+
# load input.ply and translate it by (1, 0, 0) and write the result to output.ply
|
|
25
|
+
splat-transform input.ply --t 1,0,0 output.ply
|
|
26
|
+
|
|
27
|
+
# remove entries containing NaN and Inf and bands larger than 2
|
|
28
|
+
splat-transform input.ply output.ply --filterNaN --filterBands 2
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
The full list of possible actions are as follows:
|
|
32
|
+
```
|
|
33
|
+
-translate -t x,y,z Translate splats by (x, y, z)
|
|
34
|
+
-rotate -r x,y,z Rotate splats by euler angles (x, y, z) (in degrees)
|
|
35
|
+
-scale -s x Scale splats by x (uniform scaling)
|
|
36
|
+
-filterNaN -n Remove gaussians containing any NaN or Inf value
|
|
37
|
+
-filterByValue -c name,comparator,value Filter gaussians by a value. Specify the value name, comparator (lt, lte, gt, gte, eq, neq) and value
|
|
38
|
+
-filterBands -h 1 Filter spherical harmonic band data. Value must be 0, 1, 2 or 3.
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Note
|
|
5
42
|
This very first version supports the following:
|
|
6
43
|
- reading gaussian splat ply files containing only float32 data
|
|
7
44
|
- writing PlayCanvas' compressed.ply format
|