Materials from code?

I ran across this page

https://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/Render/POV-Ray/Sample_Materials

And there are some pretty cool materials I would love to use, but there’s no .blend downloads, only what looks like code. I tried pasting it in to the python console but kept getting errors. Is there a guide on how to use these?

These are POVray materials.

To use them you’d need to use the POVray renderer.

Using POVray in Blender is discussed here:

https://www.blender.org/forum/viewtopic.php?t=580

Thank you! I suppose this means that any cycles materials I have already collected in my library would not work with Povray?

the code shown is written in C
so I guess this would need to be compiled

happy bl

That is correct. Shaders are generally incompatible between renderers unless specifically designed (like Eevee and Cycles) or unless they use a compatible language (like OSL).

Hello,
It is not C code but POV-Ray SDL, (Blender Wiki had no C syntax highlight, so c is the closest. you just have to paste it in Blender text editor, check it to Use BOTH exported properties and POV code property in text editor, and use the material name in materials replacement field There is a blend file demonstrating this at the help page: https://wiki.blender.org/uploads/9/91/POV_WORKSPACE_1.blend

The wiki page explains it here :
https://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/Render/POV-Ray#Custom_POV_Code
and also shows a video tutorial for it.