POV-Ray : Newsgroups : povray.newusers : difficult problem with lights : Re: difficult problem with lights Server Time
4 Nov 2024 19:15:21 EST (-0500)
  Re: difficult problem with lights  
From: Warp
Date: 15 May 2003 21:18:50
Message: <3ec43c7a@news.povray.org>
Posting the scene file in question would help finding the problem in
this case.

  Let me introduce a rather technical explanation about how objects "shine"
when light hits them and how this is achieved in a renderer like POV-Ray.

  It's clear that light reflects from objects and that's why we see these
objects in the first place. However, this is a simplification. Light can
reflect from the surface of an object in different ways depending on the
properties of the surface.
  In a simplified lighting model (which is usually enough for making
good-looking images) there are two ways light can reflect from a surface:
Diffusely and specularly.

  Diffuse reflection assumes the surface is extremely rough at microscopic
level and thus reflects light equally to all directions (all directions
that can be seen from the surface, naturally). Less-technical synonyms for
a diffuse surface are "matte" and "dull". The brightness of the surface
is not dependent on the direction you are looking at it.

  Specular reflection assumes a very smooth surface, with little roughness,
which causes light to be reflected mostly like a mirror does. The brightness
of the surface is highly dependant on where do you look at it from: If
the light is reflected directly at your eye, you see a bright spot at
that place in the surface.

  Since most real-life surfaces are not purely diffuse nor specular, but
something in between, this is simulated by calculating both properties
and adding them together (even though it might not be 100% physically
correct, it gives a result which looks good enough).

  Now, shiny surfaces are shiny because they have a very high specular
property to them. They reflect a lot of light specularly (ie. in the
reflected direction).
  This means that to get a shiny object, you have to specify a high
specular property to it.

  One requirement for the object to look shiny is that light reflects
from its surface to the camera. That is, parts of the surface must be
oriented so that this happens.
  One problem which might arise is if you use objects with sharp edges
and planar (ie. flat) surfaces. There simply might not be any surface on
the object which is oriented correctly to show a shiny highlight.

  Objects in real life have seldom sharp edges and perfectly planar
surfaces. Rounding the edges of your object helps a lot (the specular
highlights will usually appear on the rounded edges because part of
them will have the right orientation). Naturally positioning the camera
and the light source so that they are at the proper angle with respect
to a planar surface of the object will give a (usually big) highlight
on this surface, but that's usually quite artificial (even though
sometimes it gives a great look to the object).

  So from the above technical mumbo-jumbo we can conclude two requirements
to make your object look shiny:

  1. Define a "finish { specular 1 }" (or a variant) in your object.

  2. Round the edges of your object. (This usually requires some modelling
     skills, but that's what rendering is all about.)

-- 
plane{-x+y,-1pigment{bozo color_map{[0rgb x][1rgb x+y]}turbulence 1}}
sphere{0,2pigment{rgbt 1}interior{media{emission 1density{spherical
density_map{[0rgb 0][.5rgb<1,.5>][1rgb 1]}turbulence.9}}}scale
<1,1,3>hollow}text{ttf"timrom""Warp".1,0translate<-1,-.1,2>}//  - Warp -


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.