Considerations for Power Draw with egui

This page summarizes the projects mentioned and recommended in the original post on /r/rust

CodeRabbit: AI Code Reviews for Developers
Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.
coderabbit.ai
featured
Nutrient – The #1 PDF SDK Library, trusted by 10K+ developers
Other PDF SDKs promise a lot - then break. Laggy scrolling, poor mobile UX, tons of bugs, and lack of support cost you endless frustrations. Nutrient’s SDK handles billion-page workloads - so you don’t have to debug PDFs. Used by ~1 billion end users in more than 150 different countries.
www.nutrient.io
featured
  1. egui

    egui: an easy-to-use immediate mode GUI in Rust that runs on both web and native

    I have been contemplating the development of an image manipulation tool as a side project during my university studies. After some consideration, I have decided to implement it in Rust using wgpu for rendering and compute shaders. The supported platforms will include desktop and desktop web. As an image manipulation tool requires more than just a viewport, it also needs some form of GUI around it. Therefore, the choice of GUI library, if any, becomes quite relevant from an architectural perspective. I have been exploring egui, but I have encountered a problem. Since it employs immediate mode rendering, the entire content of the application needs to be re-rendered every time a user interacts with it, such as moving their cursor over the window. This can result in a power draw that presents issues for portable devices like laptops.

  2. CodeRabbit

    CodeRabbit: AI Code Reviews for Developers. Revolutionize your code reviews with AI. CodeRabbit offers PR summaries, code walkthroughs, 1-click suggestions, and AST-based analysis. Boost productivity and code quality across all major languages with each PR.

    CodeRabbit logo
  3. wgpu

    A cross-platform, safe, pure-Rust graphics API.

    I have been contemplating the development of an image manipulation tool as a side project during my university studies. After some consideration, I have decided to implement it in Rust using wgpu for rendering and compute shaders. The supported platforms will include desktop and desktop web. As an image manipulation tool requires more than just a viewport, it also needs some form of GUI around it. Therefore, the choice of GUI library, if any, becomes quite relevant from an architectural perspective. I have been exploring egui, but I have encountered a problem. Since it employs immediate mode rendering, the entire content of the application needs to be re-rendered every time a user interacts with it, such as moving their cursor over the window. This can result in a power draw that presents issues for portable devices like laptops.

  4. rerun

    Visualize streams of multimodal data. Free, fast, easy to use, and simple to integrate. Built in Rust.

    To test the power draw, I conducted an unscientific experiment by circling the cursor over both a GTK4 app (GNOME Console) and an egui app (Rerun Viewer), while monitoring the CPU/GPU utilization and stabilized power draw with PowerTOP. The results indicated that when circling the cursor over the GTK4 app, the CPU/GPU usage was nearly negligible, and the stabilized power draw was around 13 W. In contrast, when circling the cursor over the egui app, the CPU/GPU usage was considerably higher, resulting in a stabilized power draw of around 21 W. This amounts to an increase of approximately 60%. Taking into account a power draw of around 10 W when doing nothing at all, the increase becomes roughly 260%. I also tried the same experiment with Iced, and while the increase was not as extreme, it still utilized resources when circling the cursor over a blank surface.

  5. pixels

    A tiny hardware-accelerated pixel frame buffer. 🦀

    You can use wgpu instead of opengl as in the pixels example: https://github.com/parasyte/pixels/tree/main/examples/minimal-fltk

  6. iced

    A cross-platform GUI library for Rust, inspired by Elm

  7. floem

    A native Rust UI library with fine-grained reactivity

  8. rui

    Declarative Rust UI library

  9. Nutrient

    Nutrient – The #1 PDF SDK Library, trusted by 10K+ developers. Other PDF SDKs promise a lot - then break. Laggy scrolling, poor mobile UX, tons of bugs, and lack of support cost you endless frustrations. Nutrient’s SDK handles billion-page workloads - so you don’t have to debug PDFs. Used by ~1 billion end users in more than 150 different countries.

    Nutrient logo
  10. kayak_ui

    Bevy with https://github.com/StarArawn/kayak_ui

  11. Ribir

    Non-intrusive GUI framework for Rust/WASM

  12. Graphite

    2D vector & raster editor that melds traditional layers & tools with a modern node-based, non-destructive, procedural workflow.

    There's also https://graphite.rs/ which is an existing image manipulation application in Rust project that you could join in with. It's currently rendering to SVG, but they are actively working on moving to Vello (which also builds on top of wgpu).

  13. solid-docs

    Official documentation for the Solid ecosystem

    Since you're already planning to support the web, why not just use Tauri and build your UI with some sort of web stack? There are a handful of frontend web frameworks for Rust, so you wouldn't even need to write HTML/CSS/JS if you're looking to avoid that. But if you don't mind learning/writing some web code, SolidJS is stupid fast and lightweight.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Help wanted: OpenGL in Bevy

    2 projects | /r/bevy | 27 Apr 2023
  • Simple custom button with Slint in under 4 Minutes

    2 projects | /r/rust | 8 Dec 2022
  • Hey which gui framework would be better?

    2 projects | /r/learnrust | 5 Oct 2022
  • GUI library for university project?

    4 projects | /r/rust | 29 Jul 2022
  • Need help choosing a language :(

    3 projects | /r/rust | 5 May 2022

Did you know that Rust is
the 5th most popular programming language
based on number of references?