-
Notifications
You must be signed in to change notification settings - Fork 56
Description
I'm only really familiar with macOS and iOS, but on those platforms it would make sense to split the window and the view handles in two.
That way, users could make some sort of interface in the native toolkit, and just provide the NSView
handle to wgpu
to render into. With the current design, we're assuming that the whole window's content is what should be rendered into.
I think this is roughly how it already works on web, e.g. you can lay out the page in a certain way, and then just create a canvas that you pass on to the renderer to do its thing. (Though arguably winit
shouldn't be creating a canvas, perhaps instead it should provide a div
that the graphics library itself can insert the canvas into?)
Would this sort of thing work on other platforms?