Community
Arnold for 3ds Max Forum
Rendering with Arnold in 3ds Max using the MaxtoA plug-in.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Map the density of the Standard Volume

12 REPLIES 12
SOLVED
Reply
Message 1 of 13
Anonymous
944 Views, 12 Replies

Map the density of the Standard Volume

Hi. I'm working on a scene that involves several types of laser beams. They are modeled as cones and I was hoping to render them with the Standard Volume shader, but when a beam gets more focused (smaller radius) it becomes less visible instead of more visible.

So is there a way to 2D map the density so a small radius will light up more than a large radius?

Tags (2)
Labels (2)
12 REPLIES 12
Message 2 of 13
madsd
in reply to: Anonymous

Not entirely sure I understand, but intuition says Float ramp on a single axis, like v or u and then pipe it up and scale it.

Message 3 of 13
Anonymous
in reply to: madsd

Thanks for replying so quick! This screenshot might help. The diagonal part of the laser focuses on a small point and that's where I want the beam to be the most bright.

Message 4 of 13
madsd
in reply to: Anonymous

Added 2020 file as well.

4370-qwe.gif

Message 5 of 13
Anonymous
in reply to: madsd

Thanks for the effort! Still when I render the ramp seems to be aligned to the screen rather than to the object when viewed at an angle. I can't open your file because my workplace is still using Max 2019 (Arnold 3.0.77.0). Also my Ramp Float node has an extra input slot ("type").screenshot-2.jpg

Message 6 of 13
madsd
in reply to: Anonymous

Attached 2019 file.

Now I see your cone looks very different than mine, so I am not sure my setup is working for your item, but the gradient translates, so just adjust it so it works in your case.

Message 7 of 13
Anonymous
in reply to: madsd

Have you tried viewing it at an angle? Because your file has the same result (horizontal cutoff instead of object-aligned). You'll see it better with interpolation set to constant.

screenshot-3.jpg conev2.zip

Message 8 of 13
lee_griggs
in reply to: Anonymous

Btw, you can also achieve this with a spotlight using a high Lens Radius and atmosphere volume enabled.

4419-gundam-lens-radius-laser-sword.jpg

Lee Griggs
Arnold rendering specialist
AUTODESK
Message 9 of 13
madsd
in reply to: Anonymous

That is because float ramp is screenspace pr default, you can map fix it in several ways.

I set up a camera projection here as an example:

Message 10 of 13
Anonymous
in reply to: Anonymous

@Mads Drøschler could you please teach me how to adjust the Ramp from screenspace to object space? I still can't seem to make it work and I want to avoid using lights.

Message 11 of 13
madsd
in reply to: Anonymous

Try use a camera projection node, put the ramp into input and send out the info to the volume material from the camera projection shader, remember to pick actual scene camera ( you have to click a button in the shader UI and then pick the camera in the viewport ) - and adjust its position so it covers the item, now you can make a float ramp on a specific axis on the item.
If you need to animate the beams with rotation or soemthing simular, remember to move the camera projection camera with it, interconnect them.

Message 12 of 13
Anonymous
in reply to: madsd

That works perfectly! Thank you very Mads 🙂

Message 13 of 13
Anonymous
in reply to: madsd

Mads, thanks for your insights here. I'm having a hard time getting the camera projection to work the way I want- just a simple gradient or ramp on a box, where the bottom has a density of 1 and the top has a density of 0 and a clean blend in between. I'm trying to make an atmosphere box that I could stick in a valley to simulate an atmosphere that's thick down below and thinner higher up. You mentioned being able to fix the mapping of the float ramp in several ways- can you list some other options? Thanks so much!

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report