vladbat00 / bevy_egui

This crate provides an Egui integration for the Bevy game engine. 🇺🇦 Please support the Ukrainian army: https://savelife.in.ua/en/
MIT License
974 stars 252 forks source link

implement worldspace ui #299

Closed Schmarni-Dev closed 3 months ago

Schmarni-Dev commented 4 months ago

this reimplements #214 while referencing a lot of parts of the pr

vladbat00 commented 3 months ago

Hi, thank you a lot for the PR, this is great! I'm still trying to find the time+energy to review and test it, so apologies for the delay.

I'm thinking how we should handle inputs for worldspace ui. I guess we need some sort of API to allow users pass mouse events casted to 3D surfaces.. Maybe users can manually emit native Bevy events by mapping keyboard/mouse events if they detect a cursor is over a 3D surface.

I think it's something we can try exploring in examples before providing a better API for it (it doesn't necessarily have to be introduced in this PR).

Schmarni-Dev commented 3 months ago

i already have code to interact with world space egui using bevy_mod_picking here https://github.com/NexusSocial/nexus-vr/tree/main/crates/egui-picking, i just need to update it to use this impl and add improvements. i would like to upstream that to here once bevy upstreams bevy_mod_picking in 0.15

vladbat00 commented 3 months ago

Merged as part of #304. Thank you for your help to drive this to completion!