Rendering Options Similar to PyMOL

Was curious if there is any development work to support PyMOL as a rendering backend or, even better, if it is possible to achieve the styles below with existing ray tracing backends?

QuteMol Like

Stylized Ball and Stick

Hi Stefan,

Thanks for the question. We have discussed this topic internally and also with the folks from NVIDIA who develop the VisRTX rendering backend and the ANARI specification for scientific 3d visualization.

Our current development goals in this area, which we are already working on or will be working on this year, are:

  • Real-time high-quality rendering with VisRTX in the interactive viewports
  • Integration of more rendering backends through the ANARI interface, e.g. the Cycles renderer from the Blender software
  • Giving OVITO users access to more advanced materials effects - as far as they are supported by the different rendering backends
  • Long-term: A rewrite of the existing OpenGL-based viewport render to improve real-time visual quality and incorporate platform-specific rendering APIs such as Direct3D, Vulkan or Metal

What the images you posted feature is an outline effect. This type of graphical effect is difficult to achieve using the ray-tracing/path-tracing techniques employed by OSPRay, VisRTX and Tachyon. However, it may be possible to achieve such an effect using a framebuffer post-processing approach, and this is something we will explore.

Regarding the idea of incorporating PyMOL as a rendering backend: I have my doubts as to whether this is feasible. This is probably a use case for which PyMOL was not designed. Or do you know more about it?

Please let me know if you have any further suggestions. Perhaps I was wrong in assuming that you were mainly interested in the outline effect.

-Alex

1 Like

Hi Alex,

Thank you for the detailed response on the development focus.

Yes, my primary interest lies in achieving the outline effect in combination with ambient occlusion, which OVITO already supports. Specifically, I am interested in the ability to combine ambient occlusion with outline borders or depth-aware borders and depth-aware halo effects, similar to what the QuteMol package offers; which PyMOL leverages as shown in the earlier image.

Additionally, I am also interested in the flat-style ball-and-stick model. I am curious if this could be achieved by having a preset for the OpenGL render shape and display options, which is what I think PyMOL does.

Kind regards,
Stefan

Hi Stefan,
I experimented with the material and lighting settings in the OSPRay renderer. Although the results didn’t perfectly match your images, I was able to achieve a somewhat flat look.
Here are my results and you might be able to get the desired look by further tweaking the render settings:

-Daniel

1 Like

@utt this looks pretty fantastic, thanks for the effort and sharing your settings.

1 Like

We have updated both the VisRTX and OSPRay rendering backends to support outlines similar to PyMOL. Here is an example:


The feature is currently available in an OVITO Pro development version, which you can access here:

Please let us know if you encounter any issues or have suggestions for improvement.

The settings are currently undocumented, but here is a brief description:

image

  • Min. Depth Delta: The minimum depth difference (along the viewing direction) required to start drawing a fully opaque outline. Outlines are partially transparent for smaller depth differences.
  • Max. Depth Delta: The depth difference (along the viewing direction) needed to reach the maximum outline thickness.
  • Min. Outline Width: The minimum width of the outline.
  • Max. Outline Width: The maximum width of the outline.
  • Outline Color: The color of the outline.
1 Like