Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Frontend Thoughts #5

Open
greggman opened this issue Oct 21, 2022 · 4 comments
Open

Frontend Thoughts #5

greggman opened this issue Oct 21, 2022 · 4 comments

Comments

@greggman
Copy link
Collaborator

Hi @sebavan

I've made a few front end sites but I'm not an expert by any means. If you have any thoughts, ideas, advice, suggestions I'm all ears and feel free to hack on whatever.

Some random thoughts:

  • I got some tiling window library in. I haven't wrangled it into making unlimited panes yet. My thought was looking at RenderDoc it would be nice to be able to open multiple texture views, multiple buffer views, etc.

  • My plan is to try to implement various views. An event view, a texture view, a buffer view, a result view, a shader view, a renderpass view, etc, and you can open as many of each as you want.

Looking at Safari's debugger it shows this

Screen.Recording.2022-10-20.at.5.18.56.PM.mov

So the event view (command view) is a tree of frames->commands. I'm guessing for WebGPU it would be frames->deviceCalls->commandbuffers->encoderCmds. So I'm imagining

frame1
frame2
  device.writeBuffer
  device.writeTexture
  device.submit(...)
    commandBuffer1
    commandBuffer2
      renderEncoder.beginRenderPass(desc)
      renderEncoder.setPipeline
      renderEncoder.setBindGroup
      renderEncoder.setVertexBuffer
      renderEncoder.setIndexBuffer
      renderEncoder.drawindexed

Or something like that. For the most part, the UI just needs a tree of data. I doesn't need to know details of what's in the tree, thou, for leaf it needs a list of resources. For example renderEncoder.setVertexBuffer needs the arguments (slot, buffer, offset, size) but it can probably generically make buffer clickable without having to know anything about specfically encoder.setVertexBuffer.

  • I'd like to be able to pop-out the UI into a separate window. That can certainly wait until later.

  • I don't know if there are any react component/widget libraries we should be looking into. In the past, when I've gone looking, they've often seemed designed for web forms where there's lots of white space and long scrolling page, vs for an app where you're trying to keep everything visible. Of course they can be styled. I don't like reiventing everything but I haven't found one that seemed to have features I needed in a form where is wasn't more work to take than reinvent.

  • I have no real opinion on how to manage state. It seems like the capture state will all be handled separately. Not sure what other state needs to be kept. Probably mostly the state of what's being viewed and maybe there is not much to do there. Guess I'm just wondering if we should be thinking about this now or waiting until we're sure we need something more structured.

Anyway, just thinking out loud. Looking forward to collaborating and your thoughts and insight.

@sebavan
Copy link
Collaborator

sebavan commented Oct 24, 2022

Hey @greggman I am availble every day this week from 8 to 9 PST time and after 2PM, would be great to have a chat :-)

You can send me an invite at [email protected]

@greggman
Copy link
Collaborator Author

2pm PST? I can try to do that today. [email protected] Or I can try at 8pm as well

@sebavan
Copy link
Collaborator

sebavan commented Oct 24, 2022

I am in Europe timezone :-) would 2PM PST tomorrow works as well ?

@greggman
Copy link
Collaborator Author

I pinged you on google chat. I'm free now (3:43pm PST) and can be available until 9pm PST though. 2pm PST tomorrow is fine too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants