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

Port all rust blueprint archetypes to eager serialization & update API #8697

Merged
merged 3 commits into from
Jan 16, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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 @@ -3,6 +3,7 @@ namespace rerun.blueprint.archetypes;

/// The query for the dataframe view.
table DataframeQuery (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
// --- Optional ---
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ namespace rerun.blueprint.archetypes;

/// Tries to move the center of mass of the graph to the origin.
struct ForceCenter (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Whether the center force is enabled.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ namespace rerun.blueprint.archetypes;

/// Resolves collisions between the bounding circles, according to the radius of the nodes.
struct ForceCollisionRadius (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Whether the collision force is enabled.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ namespace rerun.blueprint.archetypes;

/// Aims to achieve a target distance between two nodes that are connected by an edge.
struct ForceLink (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Whether the link force is enabled.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ namespace rerun.blueprint.archetypes;
///
/// If `strength` is smaller than 0, it pushes nodes apart, if it is larger than 0 it pulls them together.
struct ForceManyBody (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Whether the many body force is enabled.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ namespace rerun.blueprint.archetypes;

/// Similar to gravity, this force pulls nodes towards a specific position.
struct ForcePosition (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Whether the position force is enabled.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ namespace rerun.blueprint.archetypes;

/// Configuration for the 3D line grid.
table LineGrid3D (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Whether the grid is visible.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ namespace rerun.blueprint.archetypes;

/// Configuration for the background map of the map view.
table MapBackground (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.python.aliases": "blueprint_components.MapProviderLike"
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ namespace rerun.blueprint.archetypes;
/// Configuration of the map view zoom level.
//TODO(ab): Turn this archetype into `MapArea` and include a `center: LatLon` componnent or similar
table MapZoom (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.python.aliases": "datatypes.Float64Like"
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ namespace rerun.blueprint.archetypes;

/// Controls the distance to the near clip plane in 3D scene units.
table NearClipPlane (
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Copy"
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Controls the distance to the near clip plane in 3D scene units.
///
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ namespace rerun.blueprint.archetypes;

/// Shared state for the 3 collapsible panels.
table PanelBlueprint (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default"
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ namespace rerun.blueprint.archetypes;

/// Configuration for the legend of a plot.
table PlotLegend (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default",
"attr.python.aliases": "blueprint_components.Corner2D"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ namespace rerun.blueprint.archetypes;

/// Configuration for the scalar axis of a plot.
table ScalarAxis (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default"
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ namespace rerun.blueprint.archetypes;

/// Configures how tensor scalars are mapped to color.
table TensorScalarMapping (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default"
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ namespace rerun.blueprint.archetypes;

/// Specifies a 2D slice of a tensor.
table TensorSliceSelection (
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default, Hash, PartialEq, Eq"
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Which dimension to map to width.
///
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ namespace rerun.blueprint.archetypes;

/// Configures how a selected tensor slice is shown on screen.
table TensorViewFit (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default",
"attr.python.aliases": "blueprint_components.ViewFitLike"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ namespace rerun.blueprint.archetypes;

/// The description of a single view.
table ViewBlueprint (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
// --- Required ---
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ namespace rerun.blueprint.archetypes;
/// The last rule matching `/world` is `- /world`, so it is excluded.
/// The last rule matching `/world/house` is `+ /world/**`, so it is included.
table ViewContents (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default"
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ namespace rerun.blueprint.archetypes;

/// The top-level description of the viewport.
table ViewportBlueprint (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default"
) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ namespace rerun.blueprint.archetypes;
/// - For time series views, the default is to show the entire timeline.
/// - For any other view, the default is to apply latest-at semantics.
table VisibleTimeRanges (
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Default",
"attr.python.aliases": "datatypes.VisibleTimeRangeLike, Sequence[datatypes.VisibleTimeRangeLike]"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ namespace rerun.blueprint.archetypes;
/// If no visual bounds are set, it will be determined automatically,
/// based on the bounding-box of the data or other camera information present in the view.
table VisualBounds2D (
"attr.rerun.scope": "blueprint",
"attr.rust.archetype_eager": ""
"attr.rust.archetype_eager",
"attr.rerun.scope": "blueprint"
) {
/// Controls the visible range of a 2D view.
///
Expand Down
Loading
Loading