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

Add optional solid/filled (triangle mesh) rendering to Boxes3D and Ellipsoids. #6953

Merged
merged 22 commits into from
Jul 24, 2024
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
4dabd76
Add `SolidColor` component type.
kpreid Jul 19, 2024
3816943
Make `process_color_slice()` take any component containing a color.
kpreid Jul 19, 2024
a4ebd47
Add `SolidCache` and use it in `EllipsoidsVisualizer`.
kpreid Jul 16, 2024
4e30473
Split color in `Ellipsoids` to `solid_colors` and `line_colors`.
kpreid Jul 19, 2024
8a96a1c
Add `solid_colors` to `Boxes3D`.
kpreid Jul 19, 2024
3a185a7
Add `ProcMeshKey::Cube`.
kpreid Jul 19, 2024
da3cb05
Add solid color support to `Boxes3DVisualizer`.
kpreid Jul 19, 2024
f5ac705
Change `box3d_batch` example to use solid colors.
kpreid Jul 19, 2024
32a3517
Don't use annotation info to set solid colors (for now).
kpreid Jul 21, 2024
355e2bb
Update archetype test and snippets for new components.
kpreid Jul 22, 2024
9b2b1d2
Add newline for lint
kpreid Jul 22, 2024
1927ae3
Add `FillMode` component, for `Boxes3D` and `Ellipsoids`.
kpreid Jul 23, 2024
6e2a5be
Add `SolidCache`.
kpreid Jul 16, 2024
b34e797
Add `ProcMeshKey::Cube`.
kpreid Jul 19, 2024
b0a97f4
Add `FillMode::Solid` support to `Boxes3D` and `Ellipsoids` visualizers.
kpreid Jul 24, 2024
eb48eb6
Add `FillMode` to snowman snippets.
kpreid Jul 23, 2024
58d509f
Add `FillMode` to `box3d_batch` snippets.
kpreid Jul 23, 2024
43e6cb3
Merge old two-component development to preserve it.
kpreid Jul 24, 2024
56329b1
Add missing `FillMode` reexport in C++.
kpreid Jul 24, 2024
1a44f2f
add editor for FillMode
Wumpf Jul 24, 2024
2b23ed3
Merge remote-tracking branch 'origin/main' into trimesh
Wumpf Jul 24, 2024
00a51d9
remove defunct py-test from contributor ci (pixi.toml says it's not s…
Wumpf Jul 24, 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
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,11 @@ table Boxes3D (
/// Optional rotations of the boxes.
rotations: [rerun.components.Rotation3D] ("attr.rerun.component_recommended", nullable, order: 2100);

/// Optional colors for the boxes.
colors: [rerun.components.Color] ("attr.rerun.component_recommended", nullable, order: 2200);
/// Optional colors for the boxes' surfaces.
solid_colors: [rerun.components.SolidColor] ("attr.rerun.component_recommended", nullable, order: 2200);

/// Optional colors for the lines that make up the boxes.
colors: [rerun.components.Color] ("attr.rerun.component_recommended", nullable, order: 2300);

// --- Optional ---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,15 @@ table Ellipsoids (
/// If not specified, the axes of the ellipsoid align with the axes of the coordinate system.
rotations: [rerun.components.Rotation3D] ("attr.rerun.component_recommended", nullable, order: 2100);

/// Optional colors for the ellipsoids.
colors: [rerun.components.Color] ("attr.rerun.component_recommended", nullable, order: 2200);
/// Optional colors for the ellipsoids' surfaces.
///
/// This color may be transparent to render the ellipsoid as a wireframe alone.
solid_colors: [rerun.components.SolidColor] ("attr.rerun.component_recommended", nullable, order: 2200);

/// Optional colors for the ellipsoids' wireframe lines.
///
/// This color may be transparent to render the ellipsoid as a colored surface alone.
line_colors: [rerun.components.Color] ("attr.rerun.component_recommended", nullable, order: 2300);
kpreid marked this conversation as resolved.
Show resolved Hide resolved

// --- Optional ---

Expand Down
1 change: 1 addition & 0 deletions crates/store/re_types/definitions/rerun/components.fbs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 19 additions & 0 deletions crates/store/re_types/definitions/rerun/components/solid_color.fbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
namespace rerun.components;

// ---

/// An RGBA color for the surface of an object.
///
/// In representation and color space, this is identical to [components.Color].
/// Unlike that component, it is used specifically to request that this color should be
/// applied to the entire surface of the object (as opposed to the lines of a wireframe).
table SolidColor (
"attr.arrow.transparent",
"attr.python.aliases": "int, Sequence[int], npt.NDArray[Union[np.uint8, np.float32, np.float64]]",
"attr.python.array_aliases": "int, Sequence[Sequence[int]], npt.NDArray[Union[np.uint8, np.uint32, np.float32, np.float64]]",
"attr.rust.derive": "Copy, PartialEq, Eq, PartialOrd, Ord, bytemuck::Pod, bytemuck::Zeroable",
"attr.rust.repr": "transparent",
"attr.docs.unreleased"
) {
rgba: rerun.datatypes.Rgba32 (order: 100);
}
55 changes: 45 additions & 10 deletions crates/store/re_types/src/archetypes/boxes3d.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

76 changes: 59 additions & 17 deletions crates/store/re_types/src/archetypes/ellipsoids.rs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions crates/store/re_types/src/components/.gitattributes

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading