Enable wgpu device features and limits#1401
Enable wgpu device features and limits#1401PixelDust22 wants to merge 4 commits intobevyengine:mainfrom
Conversation
|
"getting stuck" is not the right way to call my PR, but I dont mind - @cart can pick which one he wants use. |
|
Cool I'll do a review of both in the near future. |
|
@Neo-Zhixing @verzuz I was initially inclined to merge this pr as it also includes wgpu limits and the api is a closer match to Wgpu. I also like how this pr includes WgpuFeatures inside of WgpuOptions. However #547 has the desirable behavior of breaking when the wgpu bitflags change (ex: a flag is renamed or removed). A list of enums is also more serialization-friendly, and there is a world where we move to "serialized" plugin configuration for the Bevy Editor. I think I'll merge #547 (with DeviceFeatures merged into WgpuOptions), but it would be awesome if this pr could be adapted to account for #547 so we can get the nice WgpuLimits config too. |
Follow up on #547 and #1401 Co-authored-by: Zhixing Zhang <[email protected]>
This PR implements wireframe rendering. Usage: This is now ready as soon as #1401 gets merged. Usage: ```rust app .insert_resource(WgpuOptions { name: Some("3d_scene"), features: WgpuFeatures::NON_FILL_POLYGON_MODE, ..Default::default() }) // To enable the NON_FILL_POLYGON_MODE feature .add_plugin(WireframePlugin) .run(); ``` Now we just need to add the Wireframe component on an entity, and it'll draw. its wireframe. We can also enable wireframe drawing globally by setting the global property in the `WireframeConfig` resource to `true`. Co-authored-by: Zhixing Zhang <[email protected]>
Alternative implementation to #547.
This PR also added
WgpuFeatures,name, andWgpuLimitstoWgpuOptions. Additionally, it also re-exported certain wgpu render resource limit constants.This is ready for review.