-
Notifications
You must be signed in to change notification settings - Fork 373
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[pure refactor] move data ui to new
re_data_ui
crate (#2048)
* re_data_ui crate setup * move all data_ui except tensor to re_data_ui * move annotations to re_viewer_context * move tensor stats & decode cache to re_viewer_context * move gpu bridge to re_viewer_context for the time being * move image ui to re_data_ui and re-enable data ui for tensors * fix links in readme * deduplicate select_hovered_on_click logic again, leaving a comment that it is misplaced * minor crate cleanup via cargo machete
- Loading branch information
Showing
70 changed files
with
412 additions
and
325 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
[package] | ||
authors.workspace = true | ||
description = "Provides ui elements for Rerun component data for the Rerun Viewer." | ||
edition.workspace = true | ||
homepage.workspace = true | ||
license.workspace = true | ||
name = "re_data_ui" | ||
publish = true | ||
readme = "README.md" | ||
repository.workspace = true | ||
rust-version.workspace = true | ||
version.workspace = true | ||
include = ["../../LICENSE-APACHE", "../../LICENSE-MIT", "**/*.rs", "Cargo.toml"] | ||
|
||
[package.metadata.docs.rs] | ||
all-features = true | ||
|
||
[dependencies] | ||
re_arrow_store.workspace = true | ||
re_data_store.workspace = true | ||
re_error.workspace = true | ||
re_format.workspace = true | ||
re_log_types.workspace = true | ||
re_log.workspace = true | ||
re_query.workspace = true | ||
re_renderer.workspace = true | ||
re_ui.workspace = true | ||
re_viewer_context.workspace = true | ||
|
||
anyhow.workspace = true | ||
bytemuck.workspace = true | ||
egui_extras.workspace = true | ||
egui.workspace = true | ||
image.workspace = true | ||
itertools.workspace = true | ||
nohash-hasher.workspace = true | ||
rfd.workspace = true | ||
|
||
[target.'cfg(not(target_arch = "wasm32"))'.dependencies] | ||
puffin.workspace = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# re_data_ui | ||
|
||
Part of the [`rerun`](https://github.com/rerun-io/rerun) family of crates. | ||
|
||
[![Latest version](https://img.shields.io/crates/v/re_data_ui.svg)](https://crates.io/crates/re_data_ui) | ||
[![Documentation](https://docs.rs/re_data_ui/badge.svg)](https://docs.rs/re_data_ui) | ||
![MIT](https://img.shields.io/badge/license-MIT-blue.svg) | ||
![Apache](https://img.shields.io/badge/license-Apache-blue.svg) | ||
|
||
Provides ui elements for Rerun component data for the Rerun Viewer. |
3 changes: 1 addition & 2 deletions
3
...ewer/src/ui/data_ui/annotation_context.rs → crates/re_data_ui/src/annotation_context.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
use re_viewer_context::{Item, UiVerbosity, ViewerContext}; | ||
|
||
use crate::DataUi; | ||
|
||
impl DataUi for Item { | ||
fn data_ui( | ||
&self, | ||
ctx: &mut ViewerContext<'_>, | ||
ui: &mut egui::Ui, | ||
verbosity: UiVerbosity, | ||
query: &re_arrow_store::LatestAtQuery, | ||
) { | ||
match self { | ||
Item::SpaceView(_) | Item::DataBlueprintGroup(_, _) => { | ||
// Shouldn't be reachable since SelectionPanel::contents doesn't show data ui for these. | ||
// If you add something in here make sure to adjust SelectionPanel::contents accordingly. | ||
} | ||
Item::ComponentPath(component_path) => { | ||
component_path.data_ui(ctx, ui, verbosity, query); | ||
} | ||
Item::InstancePath(_, instance_path) => { | ||
instance_path.data_ui(ctx, ui, verbosity, query); | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.
6c14940
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible performance regression was detected for benchmark 'Rust Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold
1.25
.mono_points_arrow_batched/generate_message_bundles
27496592
ns/iter (± 1104270
)20723598
ns/iter (± 1445354
)1.33
mono_points_arrow_batched/generate_messages
5535137
ns/iter (± 500180
)4392746
ns/iter (± 259076
)1.26
mono_points_arrow_batched/decode_total
11975869
ns/iter (± 495779
)8101214
ns/iter (± 126551
)1.48
This comment was automatically generated by workflow using github-action-benchmark.