Please can you implement "+ Send" for egui_plot PlotItem

Offen
#103 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Anfängerfreundlichkeit
38/100
Issue-Typ
Feature
Klarheit
Größtenteils klar
Aktivitätsstatus
Veraltet
Tech-Stack
rust

Rechercherichtung

Beginne damit, das PlotItem-Trait und seine Verwendung von Box im egui_plot-Quellcode zu lokalisieren, und überprüfe dann, wie egui::Plot Plot-Items konsumiert. Prüfe die vorhandenen Tests und die Compile-Time-Anforderungen von Send, bevor du entscheidest, wie die threadübergreifende Verwendung verifiziert werden sollte. Als erledigt gilt die Aufgabe, wenn die angeforderte threadübergreifende Verwendung ohne den gemeldeten E0277-Fehler unterstützt wird und die relevanten Tests bestehen.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

Hello, I need to use egui_plot PlotItem across threads, basically my Rust code is to generate an oscilloscope trace from SPI input using egui::Plot. Without using a thread to draw the trace, the oscilloscope trace drawing is far too slow. The error message I'm getting is as follows:
error[E0277]: dyn egui_plot::PlotItem cannot be sent between threads safely
= help: the trait Send is not implemented for dyn egui_plot::PlotItem
= note: required for Unique<dyn egui_plot::PlotItem> to implement Send
note: required because it appears within the type Box<dyn egui_plot::PlotItem>

I have researched implementing "+ Send" as part of my code but it would appear it needs to be implemented in the PlotItem library/source, I have tried just about everything to get PlotItem to work across threads and am tearing my hair out! Many thanks in anticipation.

Vorherrschende Sprache
Rust
Sterne
494
Forks
110
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus emilk/egui_plot

Alle Issues in emilk/egui_plot

Ähnliche Issues

Weitere Issues zu Rust

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.