RenderKit / ospray

An Open, Scalable, Portable, Ray Tracing Based Rendering Engine for High-Fidelity Visualization
http://ospray.org
Apache License 2.0
982 stars 178 forks source link

Nan/dev231 2.10.0 #544

Closed ghost closed 11 months ago

ghost commented 1 year ago

This PR contains Ansys EnSight’s changes to support EnSight’s customized modes. There are four major changes:

For example, to support 1D texture mapping of a variable, we directly pass the raw values of the variable to the raytracer during mesh initialization, together with the corresponding mapping functions. During rendering, the 1D texture coordinate is computed on-the-fly for texture lookup. This is necessary, since sometimes a 1D texture coordinate cannot be computed due to the input value being an Undefined value. In engineering, this is possible for some vertices, or even for the whole mesh. Thus, it should be mapped to a specified color, not an interpolated value from the palette. Similar implementation is used for alpha by operation.

The image below shows such a situation: some nodes have undefined values so that they are mapped to a user specified constant color, not palette colors; and the mesh’s opacity varies due to alpha by mapping

image