Nilirad / bevy_prototype_lyon

Draw 2D shapes in Bevy
Apache License 2.0
702 stars 87 forks source link

Abnormal CPU and memory usage leads to low FPS #246

Open erayerdin opened 7 months ago

erayerdin commented 7 months ago

I'm not quite sure if it is related to this crate, but wanted to open it up since my troubleshooting does not lead anywhere else. I'm coming from this discussion in official Bevy Github Discussions.

The discussion itself is self-explanatory. Basically, drawing 2562 outlined rectangles leads to abnormal CPU and memory usage even when the program is run on GPU. The only idea I've got is maybe, for some reason, the rectangles outside the viewport are not culled although this docs say (mind it's unofficial):

Every frame, after "visibility propagation", Bevy will check what entities can be seen by what view (camera or light), and store the outcome in these components.

If, upon investigation, it is not related to this project, feel free to close.