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

Prototype transparency #256

Open
1 of 4 tasks
Tracked by #19
blairlyons opened this issue Mar 10, 2022 · 2 comments
Open
1 of 4 tasks
Tracked by #19

Prototype transparency #256

blairlyons opened this issue Mar 10, 2022 · 2 comments
Assignees

Comments

@blairlyons
Copy link
Contributor

blairlyons commented Mar 10, 2022

Use Case

As a developer supporting users visualizing dense scenes, I would like a performant way to display objects that are transparent.

Acceptance Criteria

Development plan for implementing transparency.

Details

There are still open UX questions about when and how transparency should be controlled, i.e. does the user set it in the data and/or in real time? what are the controls like?

But first we need to figure out if transparency is feasible and how to maintain good performance in real time.

This scope does not include picking transparent objects, just rendering them for now.

@blairlyons blairlyons moved this to 🌳 Backlog in Simularium Planning Apr 26, 2022
@blairlyons blairlyons moved this from 🌳 Backlog to 🏁 Ready for work in Simularium Planning Apr 27, 2022
@blairlyons blairlyons moved this from 🏁 Ready for work to 🌳 Backlog in Simularium Planning May 27, 2022
@blairlyons blairlyons moved this from 🌳 Backlog to 🏁 Ready for work in Simularium Planning May 27, 2022
@blairlyons blairlyons moved this from 🏁 Ready for work to 🌳 Backlog in Simularium Planning May 27, 2022
@jsavieo jsavieo added the 9 https://github.com/simularium/simularium-planning/issues/66 label Aug 1, 2022
@blairlyons blairlyons added 10 https://github.com/simularium/simularium-planning/issues/74 and removed 9 https://github.com/simularium/simularium-planning/issues/66 labels Aug 20, 2022
@blairlyons blairlyons added 10 https://github.com/simularium/simularium-planning/issues/74 and removed 10 https://github.com/simularium/simularium-planning/issues/74 labels Sep 20, 2022
@blairlyons blairlyons removed the 10 https://github.com/simularium/simularium-planning/issues/74 label Nov 14, 2022
@blairlyons blairlyons added the next sprint Issue prioritized for next sprint label Feb 7, 2023
@toloudis
Copy link
Contributor

toloudis commented Feb 7, 2023

We had a quick meeting to discuss what to do here. To mark this ticket as done:

  • in the viewer test app, add a third checkbox to each agent type. The checkbox will turn transparency on or off for all agents of that type. Opacity can be just a hardcoded value like 0.3. (Bonus: add single global opacity slider in the tweakpane. Double bonus: per-agent-type opacity inputs?)
  • transparent agents will not be clickable in any way.
  • transparent agents will not be able to be outlined (this may yet be possible but first prototype doesn't require it)
  • transparent agents will be properly occluded by opaque agents in front of them

Implementation details: this will require a new "forward" render pass that reuses the depth buffer from the current render passes. Agents will have to be grouped and added to the new render pass and excluded from the others. Possibly a new fragment shader will have to be written for the new render pass, to do the alpha-based coloring with alpha blending. This will be an extra geometry pass so expect performance to drop.

Once this basic render pass is hooked up to everything, we will be able to build on it and investigate what other enhancements are possible.

In a separate ticket we should address single-agent settings. I think that is a bigger general concern beyond transparency.

@toloudis
Copy link
Contributor

toloudis commented Mar 23, 2023

Status:

  • separate transparency render pass was added to renderer, all data now partitioned to have separate groupings for transparent pdbs and meshes

remaining TODOs of current first implementation:

  • assign correct colors
  • add opacity slider to tweakpane ui
  • consider changing opacity and/or color with depth, similarly to how the compositeshader does it.
  • make it work for fibers too

@blairlyons blairlyons moved this from 🌳 Backlog to 🏃 In Progress in Simularium Planning Apr 4, 2023
@blairlyons blairlyons removed the next sprint Issue prioritized for next sprint label Apr 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🏃 In Progress
Development

No branches or pull requests

4 participants