Volumetric Gradient index rendering
Posted: Sat Mar 12, 2022 3:20 pm
Hello everybody,
I would like to trace rays through gradient index media, which rather bend the rays then refract them. I already wrote a small program which is fast enough and is embedded in a ray-tracer which works on basis of meshes. The general principle is, that the volume is connected to a surface and as soon as a ray hits this surface the subsequent calculation is performed step-wise through the volume, with fixed intervals, until the end of it is reached where it switches back again to surface based ray-tracing. With a sufficiently small step-size this approach turned out to be still reasonably fast.
Now I was wondering if it would be somehow possible to define such a functionality into LuxCore. I don't know if such a functionality would ever be useful for a broad range of people. Not being able to detect collisions inside the volume limits adds some complexity on how to define the scene. I would be very happy if somebody could give me either some help or show me where i would have to implement such functionality.
I would like to trace rays through gradient index media, which rather bend the rays then refract them. I already wrote a small program which is fast enough and is embedded in a ray-tracer which works on basis of meshes. The general principle is, that the volume is connected to a surface and as soon as a ray hits this surface the subsequent calculation is performed step-wise through the volume, with fixed intervals, until the end of it is reached where it switches back again to surface based ray-tracing. With a sufficiently small step-size this approach turned out to be still reasonably fast.
Now I was wondering if it would be somehow possible to define such a functionality into LuxCore. I don't know if such a functionality would ever be useful for a broad range of people. Not being able to detect collisions inside the volume limits adds some complexity on how to define the scene. I would be very happy if somebody could give me either some help or show me where i would have to implement such functionality.