Answered Ray of light/light-source solution 🤔

D-Rock

Well-known member
Featured Contributor
Messages
60
Reactions
333
Points
53
Website
subscribestar.adult
Twitter
DeeeR0ck
I've got a flashlight CUA and I thought that it'd just be easier/more convenient to use an invisible spotlight in VAM for the light. It works as far as just being a light source, but it doesn't actually emit a light ray, which is what I'm looking for. Is there a solution?
 
I don't think you can make the actual light beam visible, like using a flashlight in the fog. But you can fake it. Try adding an IScone (add atom>shapes>iscone)

Set the color to something yellowish and turn the alpha way down, so it's barely visible, and turn physics&collision off. Then physics link it to the flashlight. Adjust the scale so it's about the same angle as the light.

Here's what i came up with in a minute or so. I'm sure it could be improved.
1661284785978.png
 
Upvote 0
An actual light beam like this reflects off of dust in the air. That's the only thing that makes it visible IRL. In 3D apps, this is referred to as a caustic or volumetric effect. They are extremely compute intensive. Is it possible in VAM to use a map file for the Alpha channel? If so, an Alpha map of random noise could be a better way to fake this effect. Random noise maps can be generated in any number of image editing apps.
 
Upvote 0
Yes, the Alpha channel trick works. I added an Iscone, as described. Go to Material 1, Textures, add the noise map to _AlphaTex. Lower the Alpha Adjust under Materials. In Material 2, adjust the color as needed. I set the Alpha on Material 2 to -1 so you wouldn't see the base of the cone. The tip of the cone should be hidden inside your flashlight. Play with this and see what you get.
 

Attachments

  • 1661575710.jpg
    1661575710.jpg
    283.8 KB · Views: 0
  • 3D_Noise.jpg
    3D_Noise.jpg
    253.5 KB · Views: 0
Upvote 0
In Daz, these are sometimes called Godrays if they come from above. 😇 There are various ways to fake them in Daz too.
 
Upvote 0
Back
Top Bottom