POV-Ray : Newsgroups : povray.advanced-users : Fast volume rendering Server Time
31 Oct 2024 06:14:41 EDT (-0400)
  Fast volume rendering (Message 1 to 5 of 5)  
From: yesbird
Subject: Fast volume rendering
Date: 23 Sep 2024 09:26:27
Message: <66f16c83$1@news.povray.org>
Hi all !

I am working on web GUI to Povray for volume visualization
applications, using 'media' and 'df3' format. The main idea is providing
the user with some fast WebGL-based gizmos (bounding box, grid,light
version of volume data) for fast camera positioning like here:
https://threejs.org/examples/?q=volume#webgl_volume_perlin

and then making server-side high-quality rendering like here:
https://povlab.online/?scene=dicom.pov

Can anyone suggest how to make volume rendering faster, but without
losing a quality ?

Thanks in advance.
--
YB


Post a reply to this message

From: Bald Eagle
Subject: Re: Fast volume rendering
Date: 23 Sep 2024 10:25:00
Message: <web.66f1797c1b0021ea5a6be6925979125@news.povray.org>
yesbird <sya### [at] gmailcom> wrote:
> Hi all !
>


> the user with some fast WebGL-based gizmos (bounding box, grid,light
> version of volume data) for fast camera positioning like here:
> https://threejs.org/examples/?q=volume#webgl_volume_perlin
>

> https://povlab.online/?scene=dicom.pov
>

> losing a quality ?
>
> Thanks in advance.
> --
> YB

Off the top of my head, POV-Ray's media would get approximated by a procedural
function that governed the rgb values based on the <x, y, z> coordinates, and so
whatever method that threejs uses, or Shadertoy ought to give decent results.

Reading in a df3 file would seem to be the only bottleneck.

Are you looking to make it faster than the examples you linked to?
Or are you looking to find a way to render 3D volumes in POV-Ray faster than
whatever methods you're currently using?

- BW


Post a reply to this message

From: yesbird
Subject: Re: Fast volume rendering
Date: 23 Sep 2024 11:14:23
Message: <66f185cf$1@news.povray.org>
On 23/09/2024 17:21, Bald Eagle wrote:
> Or are you looking to find a way to render 3D volumes in POV-Ray faster than
> whatever methods you're currently using?
Yes, this one.
I see the following workflow:

User is playing with the scene using three.js and then by
clicking "Render" button (or by releasing the mouse button) sends an SDL
scene, generated on-the-fly, to the server, getting a rendered image.
(Assuming that 'df3' data is already on the server).

The main goal is to make this cycle as fast as possible, ideally
achieving near-real-time performance. I am investigating 'media' with
'df3' deeply now, maybe there are some hidden tricks and/or parameters
will help ...

General idea is building the bridge between the WebGL/WebXR (three.js)
and Povray for different applications, like this future  math-museum:
https://math.povlab.online/
(inspired by https://virtualmathmuseum.org/)

BTW, behind the povlab.online now 128 virtual cores of:
--------------------------------------------------
AMD EPYC 7763 64-Core Processor
CPU MHz         : 2599.927
--------------------------------------------------
YB


Post a reply to this message

From: Alain Martel
Subject: Re: Fast volume rendering
Date: 23 Sep 2024 11:21:05
Message: <66f18761$1@news.povray.org>
Le 2024-09-23 à 09:26, yesbird a écrit :
> Hi all !
> 
> I am working on web GUI to Povray for volume visualization
> applications, using 'media' and 'df3' format. The main idea is providing
> the user with some fast WebGL-based gizmos (bounding box, grid,light
> version of volume data) for fast camera positioning like here:
> https://threejs.org/examples/?q=volume#webgl_volume_perlin
> 
> and then making server-side high-quality rendering like here:
> https://povlab.online/?scene=dicom.pov
> 
> Can anyone suggest how to make volume rendering faster, but without
> losing a quality ?
> 
> Thanks in advance.
> -- 
> YB
> 
> 
The type of media used have a lot of effect. A media can be emissive, 
absorbing or scattering.
Emissive media renders the fastest. They work better against a dark 
background. They add to the background. They never cast any shadow and 
never interact with any light_source.

Absorbing media is a close second. Work better against a light 
background. They subtract from the background. They do cast shadows when 
there is some light_source present. Lights never illuminate them.

Scattering media are the slowest. They need a light source that interact 
with them. They subtract from the background, when there is a light, 
they also add to the background.

Use the default sampling method 3. NEVER use an intervals value larger 
than the default of 1, increase the sample value instead. More intervals 
can cause glitches and is MUCH slower. intervals 10 samples 10 is at 
least 5 times slower than just samples 200 for half the samples.


Post a reply to this message

From: yesbird
Subject: Re: Fast volume rendering
Date: 23 Sep 2024 11:36:41
Message: <66f18b09$1@news.povray.org>
On 23/09/2024 18:21, Alain Martel wrote:
> The type of media used have a lot of effect. A media can be emissive, 
> ...

Thank you very much for detailed explanation and useful suggestions -
you saved me a lot of time, while I am still have a space for
interesting experiments with media :).
--
YB


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.