29

I wrote a Ray Tracer for an assignment this past semester and wanted to keep working on it. There were 5 kinds of materials (for objects) in the assignment and we were given their ambient, diffuse, specular, and shininess values. I'm having a hard time finding a list of these values to create new materials online (one that also included indices of refraction would be fantastic) and was wondering if anyone knew of a good resource for this.

This is the best one I have found so far but it doesn't have that many materials and the materials that have indices of refraction don't have the other values I mentioned above: http://www.nicoptere.net/dump/materials.html

I have never done refraction for a Ray Tracer (planning on learning it for fun), any general advice would be welcome.

asimes
  • 5,749
  • 5
  • 39
  • 76
  • I did find something with a number of common materials: http://globe3d.sourceforge.net/g3d_html/gl-materials__ads.htm – asimes Dec 28 '12 at 14:31
  • In your first link, the other material properties are given further down for most of the materials, except for 'clear' ones like diamond and water. – fluffels Jul 31 '14 at 07:53
  • Also, if you have the index of refraction `eta` you can calculate the amount of reflected and refracted light: http://en.wikipedia.org/wiki/Fresnel_equations – fluffels Jul 31 '14 at 07:54
  • You might want to look into physically based ray tracing. – fluffels Jul 31 '14 at 07:55
  • @fluffels, thank you but I figured this out a long time ago (this was posted a year and a half ago). I just let the question stay because it appears when Googling "raytracing materials" – asimes Jul 31 '14 at 16:42

1 Answers1

3

Use other open source ray tracers as resource, e.g. POV-Ray. You find the definition of materials in the distribution/include Path.

An example from metals.inc (put together):

#declare P_Brass1    = color rgb <0.30, 0.20, 0.10>;

#declare F_MetalA  =
finish {
    ambient 0.35
    brilliance 2
    diffuse 0.3
    metallic
    specular 0.80
    roughness 1/20
    reflection 0.1
}

#declare T_Brass_1A = texture { pigment { P_Brass1 } finish { F_MetalA  } }
Günther Jena
  • 3,706
  • 3
  • 34
  • 49