faking dispersion using the new blend material

You can now create a Vray material for rendering dispersion. Notice the additive mode, which in this case should be physically acceptable.

Using this material on a ‘diamond shaped’ object: (some glows and stars from photoshop) The small change in ior gives a subtle color change in the material.

wow!
great result u got there!

must try one of this days dispersin just for fun…i dont get to need it so often (never is what i need to say…) in these archiviz… :cry:
8)

Wow Gijs - that’s amazing. :shock:

Gijs…if you take it out of Shellac mode, you will not need to do 255/3… you can just do 255, because it will disolve them together.

Maybe another render? this one doesnt show dispresion very well.

Chris, I’ll check that, thanks.

Morbid Angel, well, it is like I said, a subtle effect. You can easily change it by increasing the differences in IOR’s.

BTW I also tried to come up with a 6 color blend, but somehow this failed miserably.

Looks pretty cool but not much colour dispersion Gijs, seems most of the colour is coming from an hdri?

yeah, need something like this

another thumbs up to chaos for sneaking in these “silly” small things, which make a huge difference in the right hands :slight_smile:
I was SO frustrated by max trying to recreate it :slight_smile:

Lele

sweeeeeeeeeeeeeeeeeeet!!!

morbid, is that a render?

indeed, and its final rendered render… With some post process i think. Took it of of their website.

ahhhh sneaky

5 as reflection/refraction max depth is too low to see any diffraction.
Especially with “reflect on back side” on, rays would be trapped in, and show the BG.
In my tests 15 is a good dept to improve the diffraction presence without changing IoR spread.
And maybe lower a bit refraction cutoff to let the softer tones come through (0.003 or similar?)

Also, i found it best to avoid very bright light sources, as when diffraction occurs, the rays are fairly energetic and tend to show colorful, and meaningless, speckles around the object, making it hell for the AA to clean it.

Lele

Hows that? Rather stupid model but…

@Natty: it is not from HDRI :slight_smile:

@Morbid Angel: that example is very exaggerated, and doesn’t look very real to me. I was after a crystal material like shown here

@Lele: you’re right about those numbers, they need to be higher to get more realistic results

@Chris: I am afraid that the normal blend does not work like you said. If you are sure however, please show me how it is done :wink:

here’s another test with ior varying from 1.48 to 1.52, so more dispersion. As you can see it works fairly well for the ball , but for the pyramid we should need more steps:

only drawback with this blend material is the fact that shadows become black. Here the rendering without dispersion:

That looks better .. Whats is it like when you use the Fog rather than refraction colour? does that work at all?

Devil of a man, i didn’t think about it.
Lemme try as well :smile:

Lele


fn clrRampBuilder id baseColor = (
		baseColor = color 0 0 0
		baseColor.Value = 255
		basecolor.Saturation= 255
		basecolor.hue=(255.0/7)*id
		return baseColor
		)
fn iorRampBuilder id spread baseIor newIor= (
		newIor=baseIor+(id*spread)
		return newIor
		) 
matSlot = VRayBlendMtl ()
matSlot.baseMtl=vraymtl()
matSlot.baseMtl.diffuse =color 0 0 0 
refFraction=1.0/7
matSlot.baseMtl.texmap_reflection = VRayColor red:refFraction green:refFraction blue:refFraction
matSlot.baseMtl.reflection_fresnel=on
matSlot.baseMtl.option_reflectOnBack=on
matSlot.baseMtl.refraction =(clrRampBuilder 0 baseColor)
matSlot.baseMtl.refraction_ior = (iorRampBuilder 0 0.03 1.7 newIor)
matSlot.baseMtl.refraction_affectShadows=on
matSlot.baseMtl.refraction_affectAlpha=on
matSlot.baseMtl.refraction_maxDepth=15
matSlot.baseMtl.reflection_maxDepth=15
baseIor=matSlot.baseMtl.refraction_ior 
for i=1 to 6 do (
matSlot.coatMtl[i]=copy matSlot.baseMtl
matSlot.coatMtl[i].refraction = (clrRampBuilder i baseColor)
matSlot.coatMtl[i].refraction_ior = (iorRampBuilder i 0.03 1.7 newIor)
matSlot.blend[i]=color 255 255 255
)
matSlot.additiveMode = on
meditmaterials[1]=matslot

Running this creates a 7 colours spectrum diffractive material, with a ior spread of 0.03 in the first mateditor slot.
Slight issue: when i turn “shellac mode” on, the editor slot takes a ZILLION years to render the sample…
Can anyone else confirm this?

Lele

over 7 mins and still updating… Zillion years confirmed :slight_smile: