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 file export support + more #39

Merged
merged 8 commits into from
Aug 23, 2021
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
8 changes: 4 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
# Changelog

All notable changes to `puffin` will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).


## Unreleased
* New `serialization` feature flag enables exporting and importing `.puffin` files. This replaces the old `with_serde` feature flag.
* Add `GlobalProfiler::add_sink` for installing callbacks that are called each frame.

* Speed up `GlobalProfiler::new_frame`.


## 0.6.0 - 2021-07-05

* Handle Windows, which uses backslash (`\`) as path separator.


## 0.5.2

* Add opt-in `serde` support.


## 0.5.1

* Remove stderr warning about empty frames.


## 0.5.0

* `GlobalProfiler` now store recent history and the slowest frames.
29 changes: 28 additions & 1 deletion Cargo.lock

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

5 changes: 3 additions & 2 deletions puffin-imgui/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ All notable changes to `puffin-imgui` will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).


## Unreleased
* Fix "Toggle with spacebar." tooltip always showing.
* Show frame index.


## 0.9.0

* Paint flamegraph top-down
* Scrollable flamegraph
* Option to sort threads by name
Expand All @@ -19,7 +21,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0


## 0.8.0

* Select frames from recent history or from among the slowest ever.
* Nicer colors.
* Simpler interaction (drag to pan, scroll to zoom, click to focus, double-click to reset).
5 changes: 3 additions & 2 deletions puffin-imgui/src/ui.rs
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ impl ProfilerUi {
}
}
}
if ui.is_any_item_hovered() {
if ui.is_item_hovered() {
ui.tooltip_text("Toggle with spacebar.");
}

Expand All @@ -381,7 +381,8 @@ impl ProfilerUi {
);

ui.text(im_str!(
"Current frame: {:.1} ms, {} threads, {} scopes, {:.1} kB",
"Showing frame #{}, {:.1} ms, {} threads, {} scopes, {:.1} kB",
frame.frame_index,
(max_ns - min_ns) as f64 * 1e-6,
frame.thread_streams.len(),
frame.num_scopes,
Expand Down
6 changes: 5 additions & 1 deletion puffin/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,18 @@ include = [ "**/*.rs", "Cargo.toml"]
[dependencies]
byteorder = { version = "1" }
once_cell = "1"
anyhow = { version = "1", optional = true }
bincode = { version = "1.3", optional = true }
lz4_flex = { version = "0.8.2", optional = true }
serde = { version = "1", features = ["derive", "rc"], optional = true }

[dev-dependencies]
criterion = "0.3"

[features]
default = []
with_serde = ["serde"]
# Feature for enabling loading/saving data to a binary stream and/or file.
serialization = ["anyhow", "bincode", "lz4_flex", "serde"]

[[bench]]
name = "benchmark"
Expand Down
Loading