Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: webgl2, formats, materials, and queries #56

Merged
merged 35 commits into from
Jan 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
f3021f7
feat: scaffold lighting, material, query
mosure Dec 18, 2023
ba9f95d
feat: draw all, selected, highlight selected modes
mosure Dec 18, 2023
2a8345b
feat: selection, inverting, draw modes, live output
mosure Dec 19, 2023
04fe30b
fix: disable sparse select on startup
mosure Dec 19, 2023
33d83c5
feat: cpu SH noise material
mosure Dec 19, 2023
7144ff3
remove unused
mosure Dec 19, 2023
9b254cd
fix: unused import warning
mosure Dec 20, 2023
98e65df
more credits
mosure Dec 20, 2023
bda7e3f
fix: allow degree 0 SH
mosure Dec 21, 2023
06ab74d
chore: clean default features
mosure Dec 21, 2023
af5a9a0
refactor: feature-driven gaussian cloud format
mosure Dec 22, 2023
eb397aa
refactor: render pipeline packed vs. planar separation
mosure Dec 27, 2023
98b881b
feat: packed and planar f32
mosure Dec 28, 2023
d071f6d
fix: wgsl struct packing differences
mosure Dec 28, 2023
166a7dc
checkin
mosure Dec 28, 2023
c4707d7
remove unused
mosure Dec 28, 2023
2ef074b
fix: f16 build errors
mosure Dec 29, 2023
5804349
chore: web feature bundle
mosure Dec 29, 2023
e20ab16
chore: more static asserts and features for input buffers
mosure Dec 29, 2023
d97a337
fix: planar has bugs
mosure Dec 29, 2023
2b4b987
docs: credit
mosure Dec 29, 2023
72578e9
feat: f16 support
mosure Dec 29, 2023
c80ebc0
feat: buffer texture f16
mosure Dec 31, 2023
49606d5
fix: unpacking
mosure Dec 31, 2023
7acb01a
fix: sh0 padding
mosure Dec 31, 2023
1f70b9f
fix: web build
mosure Dec 31, 2023
fee1d95
fix: web dependency issue
mosure Dec 31, 2023
24b0abe
fix: storage texture -> texture
mosure Dec 31, 2023
02ff96b
fix: sorted texture binding
mosure Jan 2, 2024
ca123dc
fix: webgl2 GL_ANGLE_multi_draw isn't default
mosure Jan 2, 2024
6f57b78
fix: improve cpu sort throttling and webgl2 SH
mosure Jan 2, 2024
b8f2b30
fix: prioritize storage buffers and disable rayon sort camera debounce
mosure Jan 2, 2024
86d062d
fix: planar f32 build
mosure Jan 2, 2024
1e090bc
Merge branch 'main' into feat/filtering
mosure Jan 2, 2024
8529605
fix: lint
mosure Jan 2, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,12 @@ jobs:
- name: lint
run: cargo clippy

- name: test
- name: test (default)
run: cargo test

- name: test (web)
run: cargo test --no-default-features --features="web io_ply tooling"

# - name: gaussian render test
# run: cargo run --bin test_gaussian

Expand Down
5 changes: 5 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"rust-analyzer.linkedProjects": [
"./Cargo.toml"
]
}
72 changes: 60 additions & 12 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "bevy_gaussian_splatting"
description = "bevy gaussian splatting render pipeline plugin"
version = "1.0.0"
version = "2.0.0"
edition = "2021"
authors = ["mosure <mitchell@mosure.me>"]
license = "MIT"
Expand Down Expand Up @@ -36,10 +36,23 @@ default-run = "viewer"
default = [
"io_flexbuffers",
"io_ply",
"morph_particles",

# "packed",
"planar",

"buffer_storage",
# "buffer_texture",

# "f32",
"f16",

"query_select",
"query_sparse",

"sort_radix",
"sort_rayon",
"sort_std",

"tooling",
"viewer",
]
Expand All @@ -50,37 +63,69 @@ io_bincode2 = ["bincode2", "flate2"]
io_flexbuffers = ["flexbuffers"]
io_ply = ["ply-rs"]

material_noise = ["noise", "dep:noise"]

morph_particles = []

noise = []

f32 = []
f16 = ["half"]

packed = []
planar = []

buffer_storage = []
buffer_texture = []

query_raycast = []
query_select = []
query_sparse = ["kd-tree", "query_select"]

sort_radix = []
sort_rayon = [
"rayon",
]
sort_rayon = ["rayon"]
sort_std = []

tooling = [
"byte-unit",
]
tooling = ["byte-unit"]

viewer = [
"bevy-inspector-egui",
"bevy_panorbit_camera",
# "bevy_transform_gizmo",
]

web = [
"buffer_texture",
"f16",
"io_flexbuffers",
"planar",
"sort_std",
"viewer",
"webgl2",
]

webgl2 = ["bevy/webgl2"]


[dependencies]
bevy-inspector-egui = { version = "0.21", optional = true }
bevy_panorbit_camera = { version = "0.9", optional = true }
bevy-inspector-egui = { version = "0.22", optional = true }
bevy_mod_picking = { version = "0.17", optional = true }
bevy_panorbit_camera = { version = "0.10", optional = true }
bevy_transform_gizmo = { version = "0.9", optional = true }
bincode2 = { version = "2.0", optional = true }
byte-unit = { version = "5.0", optional = true }
bytemuck = "1.14"
flate2 = { version = "1.0", optional = true }
flexbuffers = { version = "2.0", optional = true }
half = { version = "2.3.1", optional = true, features = ["serde"] }
kd-tree = { version = "0.5", optional = true }
noise = { version = "0.8.2", optional = true }
ply-rs = { version = "0.1", optional = true }
rand = "0.8"
rayon = { version = "1.8", optional = true }
serde = "1.0"
static_assertions = "1.1"
typenum = "1.17.0"
wgpu = "0.17.1"


Expand All @@ -89,7 +134,6 @@ console_error_panic_hook = "0.1"
wasm-bindgen = "0.2"


# TODO: use minimal bevy features
[dependencies.bevy]
version = "0.12"
default-features = false
Expand All @@ -102,7 +146,7 @@ features = [


[dependencies.web-sys]
version = "0.3.4"
version = "0.3"
features = [
'Document',
'Element',
Expand Down Expand Up @@ -162,6 +206,10 @@ name = "test_radix"
path = "tests/gpu/radix.rs"
required-features = ["debug_gpu", "sort_radix"]

[[example]]
name = "minimal"
path = "examples/minimal.rs"


[[bench]]
name = "io"
Expand Down
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,11 @@ bevy gaussian splatting render pipeline plugin. view the [live demo](https://mos
- [X] gaussian cloud particle effects
- [X] wasm support /w [live demo](https://mosure.github.io/bevy_gaussian_splatting/index.html?arg1=cactus.gcloud)
- [X] depth colorization
- [X] f16 and f32 gcloud
- [X] wgl2 and webgpu
- [ ] 4D gaussian cloud wavelet compression
- [ ] accelerated spatial queries
- [ ] temporal depth sorting
- [ ] f16 and f32 gcloud support
- [ ] skeletons
- [ ] volume masks
- [ ] level of detail
Expand Down Expand Up @@ -87,17 +88,21 @@ fn setup_gaussian_cloud(
- [dreamgaussian](https://github.com/dreamgaussian/dreamgaussian)
- [dynamic-3d-gaussians](https://github.com/JonathonLuiten/Dynamic3DGaussians)
- [ewa splatting](https://www.cs.umd.edu/~zwicker/publications/EWASplatting-TVCG02.pdf)
- [gaussian-grouping](https://github.com/lkeab/gaussian-grouping)
- [gaussian-splatting](https://github.com/graphdeco-inria/gaussian-splatting)
- [gaussian-splatting-viewer](https://github.com/limacv/GaussianSplattingViewer/tree/main)
- [gaussian-splatting-web](https://github.com/cvlab-epfl/gaussian-splatting-web)
- [gir](https://3dgir.github.io/)
- [making gaussian splats smaller](https://aras-p.info/blog/2023/09/13/Making-Gaussian-Splats-smaller/)
- [masked-spacetime-hashing](https://github.com/masked-spacetime-hashing/msth)
- [onesweep](https://arxiv.org/ftp/arxiv/papers/2206/2206.01784.pdf)
- [pasture](https://github.com/Mortano/pasture)
- [phys-gaussian](https://xpandora.github.io/PhysGaussian/)
- [point-visualizer](https://github.com/mosure/point-visualizer)
- [rusty-automata](https://github.com/mosure/rusty-automata)
- [spacetime-gaussians](https://github.com/oppo-us-research/SpacetimeGaussians)
- [splat](https://github.com/antimatter15/splat)
- [splatter](https://github.com/Lichtso/splatter)
- [sturdy-dollop](https://github.com/mosure/sturdy-dollop)
- [sugar](https://github.com/Anttwo/SuGaR)
- [taichi_3d_gaussian_splatting](https://github.com/wanmeihuali/taichi_3d_gaussian_splatting)
Binary file modified assets/scenes/icecream.gcloud
Binary file not shown.
6 changes: 6 additions & 0 deletions examples/minimal.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// TODO: minimal app


fn main() {
println!("Hello, world!");
}
Loading