iced-rs / iced

A cross-platform GUI library for Rust, inspired by Elm
https://iced.rs
MIT License
24.79k stars 1.17k forks source link

Implement a 3D widget #343

Open Yamakaky opened 4 years ago

Yamakaky commented 4 years ago

The current Canvas widget supports only 2D graphics. It would be cool to have a 3D counterpart, maybe limited to wgpu at first. I see it basically as a boilerplate-free version of https://github.com/hecrj/iced/blob/0.1/examples/integration/src/main.rs. My personal use-case is to have a window with a 3D view on one side (only when the option is enabled) and the other side with configuration options.

hecrj commented 4 years ago

Yes, there has been some discussion about this in #32.

codec-abc commented 4 years ago

I would be also interested in the ability to 3D (in order to render a point cloud inside a GUI app). Is 3D rendering somewhat doable for people with little experience in Iced? #32 seems to indicate that it might be feasible if someone dare to implement a 3D Canvas for him/herself but this seems out of reach for me.

dhardy commented 4 years ago

If you want WGPU support in a Rust-native GUI, this is (somewhat) possible in KAS: see the mandlebrot example. I'd be interested in getting some feedback on this (sorry @hecrj to jump in here)!

codec-abc commented 4 years ago

@dhardy: I tried it really quick before asking for update here but I was unable to build it. This is because of my weird setup (a Ubuntu 16.04 without sudo group and missing dependencies (for example cmake)). I also tried to cross compile it using mingw into a docker container but ran into issues. It seems like the C++ code need a C++ 11 compiler and mingw doesn't support it. Anyway, KAS looks great and I will give it another shot but if somehow KAS could be pure Rust it would make things somewhat easier in my case.

dhardy commented 4 years ago

I'm a little surprised, the non-Rust dependencies are basically the same as Iced (plus some optional text bits). Open an issue over on the KAS repo and let me know what fails. You could also try --no-default-features.

NicTanghe commented 1 year ago

Hello, I`m just here to make sure that the format used is USD and not old ones. https://openusd.org/release/index.html https://github.com/PixarAnimationStudios/USD

THis does mean a MaterialX /hydra deligate should be provided. https://github.com/AcademySoftwareFoundation/MaterialX

IT`s also always a good idea in anyhing that outputs color to implement. (best wait until 2.0 is released ? ) ACES: https://github.com/AcademySoftwareFoundation/OpenColorIO-Config-ACES

the entire industry is switching over and gltf is basically depricated. this does mean a materialX renderer is supposed to be implemented.

obj ects are just intermediates these days.

you-win commented 1 year ago

the entire industry is switching over and gltf is basically depricated

Dropping in to dispute that gltf is "basically depricated (sic)". GLTF is a commonly supported format in 3d modeling as well as game development (see Godot, Unity, Unreal)

breynard0 commented 2 months ago

While GLTF isn't deprecated, the USD file format is indeed much more advanced and comprehensive than GLTF.