colours | objects | textures | transformation | lighting


p o v - r a y
textures

predefined textures

wooden sphere » wooden sphere after texture transformation

the left image is a scene of a wooden sphere. its texture is determined using predefined textures. the code used is as follows:
line07: #include "textures.inc"
line90: DMFWood3
line07 is required to use predefined textures as these textures are set in the include file, in this case, textures.inc. it is possible that users create their own include file for custom predefined textures. line90 is used in the texture parameter of the sphere object. the texture name is case sensitive according to how it is named in the include file.

the right image is a scene of the same wooden sphere, but with transformations to the texture. the code used is as follows:
line96: scale 3.0
line97: translate 0.5
line96 indicates the texture has been enlarged 3.0 times the original size. line97 indicates the texture has then been translated 0.5 vectors along the x, y, and z axes, which may also be written as "<0.5, 0.5, 0.5>". this technique has created a completely different looking wooden sphere with the same predefined texture.



pattern

glass sphere on grey plane » glass sphere on blue plane

the left image is a scene of a glass sphere placed on a grey and white checkered plane. its type of pattern is determined along with several of its attributes. the code used is as follows:
line53: checker
line54: color rgb 1.0
line55: color Gray50
line56: scale 0.5
line53 determines the type of pattern, for this case, the checker pattern. line54 and line55 sets the colours to be used in the checker pattern. in this scene, rgb 1.0, which is white, and Gray50, a predefined colour, is used. line56 determines the size of the checkers.

the right image is a scene of the glass sphere on the same checkered plane, but this time blue and white in colour. this is achieved by changing the values of the colours. the code used is as follows:
line55: color Blue
this line shows the colour is now predefined colour Blue instead of Gray50. looking through the glass sphere indicates it is translucent as the change in colour of the plane also changes the appearance of the sphere.



transmit

glass sphere with full transmit » glass sphere with half transmit

the left image is a scene of a glass sphere that is fully translucent. the code used is as follows:
line103: color White transmit 1.0
this line indicates the colour of the sphere as well as the level of transmission. transmit is the syntax used to set the translucency of the object. therefore, the sphere is white in colour with 100% translucency.

the right image is a scene of the same glass sphere, but now is less translucent than the image on the left. this is achieved by changing the value of its transmit. the code used is as follows:
line103: color White transmit 0.5
this line shows the colour has not changed and remains white. but the value of transmit is now 0.5, which is half of the original. this is evident in the image as it is more difficult to see clearly through it. the photon effect has also become smaller than before.



index of refraction

glass sphere » diamond sphere

the left image is a scene of a glass sphere that is translucent with refraction. this is proven by the distortion of the blue and white checkered plane when looking through it. the code used is as follows:
line117: ior 1.5
this line is used in the interior parameter of the sphere object. it indicates the ior, or index of refraction, of the object. ior 1.5 is used here, which is the value of the glass material.

the right image is a scene of the same glass sphere, but now has higher refraction than the image on the left. this is achieved by changing the value of its ior. the code used is as follows:
line117: ior 2.4
this line shows the value of ior is now higher, which is 2.4, the value of the diamond material. this is evident in the image as its refraction is more complicated than the image on the left. the photon effect is also larger and more spread out.



specular and phong

matte blue sphere » gloss blue sphere

the left image is a scene of a blue sphere with a normal specular highlight. it is soft and spread out. the code used is as follows:
line95: specular 0.6
this line is used in the finish parameter of the sphere object. specular is usually used to indicate the object is not very shiny.

the right image is a scene of the same blue sphere, but this time has a lower specular and added a phong highlight. the code used is as follows:
line95: specular 0.2
line96: phong 1.5
line95 shows the value of specular is now lower to smooth out the phong effect. phong is then made visible by adding line96 to the sphere object. this gives the effect of the blue sphere being very shiny.



reflection mapping

gloss yellow sphere » metallic yellow sphere

the left image is a scene of a yellow sphere that is a bit reflective. it appears smooth and shiny. the code used is as follows:
line97: reflection 0.1
this line is used in the finish parameter of the sphere object. the reflectivity of the sphere is only set to 10%. such low values are good for surfaces that are slippery, such as pool balls and tiled floors.

the right image is a scene of the same yellow sphere, but is now much more reflective. it appears almost mirror like. the code used is as follows:
line97: reflection 0.5
this line shows the value of reflection is now greater than the image on the left. a reflectivity value of 50% is high enough to not lose its original pigment, and when combined with the colour yellow, makes it appear somewhat like gold or polished brass.



colours | objects | textures | transformation | lighting