Dispersion prism

Hi! Im trying to make a dispersion prism, decomposing the light in a rainbow. I have already tried luxcore and cycles, but nothing works. Octane render doesnt render. Can someone help me please? I’m a total noob.
Thanks.

There are many tutorials out there in YouTube.
One of them is https://youtu.be/lEPZ1IUkoB4
And if you want to use OSL idk about it.

Thanks but i have already watched that video and this was the result.

I have been playing with that dispersion shader in the video for the last few weeks.

This is the best I got prism wise:


(I can almost here the music :slightly_smiling_face:)

The shader is the one that we were making in this thread,

but for the prism I had to gave it a twist.

I used the diffuse ray depth to mix the shader (with nothing?) at the end of the node group.

Also there is a ground plane that intersects the prism, It needs to intersect for the outgoing rays to be visible.

I do not know why I get the purple in the middle where green should be.

I still do not really understand what is going on with this, if you get rid of the last mix shader with the diffuse depth as factor all the colours just mix together.

It is a cheat but I think that is inevitable with Cycles.

Here is the file:
Prism.blend (124.1 KB)

2 Likes

Wow thats pretty great. Thanks for the information, but now i have another problem…
It’s refracting the light even when the plate is spinning however, the spining motion is not recognised by the render animation (I Guess). It just render a image not a lot of them. Do you Know what should I do?

thx for the file i will try what you said. Thank you very much

Sorry I do not quite understand what you mean.

Your refraction looks really good. In the 2 images you posted I can see the refraction has changed angle as you rotate, what is the problem?

Edit I see you are using a driver to spin, what are the driver settings, did you keyframe the spin?
Edit 2
I just checked rotating a cube with a driver ( #frame/10 ) and no keyframes the animation rendered fine.

I presume you set your output to video format and used “render animation” (not render image)