Project Nayuki


Facebook anniversary ray trace

Facebook anniversary ray trace

This 3D scene depicts a birthday cake painted with the Facebook icon and a single birthday candle on it.

Source code (POV-Ray): facebook-anniversary.pov, facebook-anniversary-debug.pov, facebook-icon.jpg.

Decomposition

Here is the decomposition of the objects in the scene. Each checkerboard square represents exactly 1/10 unit of length in the scene.

Object Original view xz projection xy projection yz projection
Whole scene
Facebook cake
Birthday candle
Candle flame
Silver cake tray

Object details

Whole scene
  • Horizontal field of view is 30° (approximately like a 67 mm lens on a full-frame 35 mm camera), which is a medium focal length
  • Contains a square area light above for even lighting and soft shadows
  • Almost every object uses bump mapping so that the surfaces don’t look so flat and idealized
Facebook cake
Birthday candle
  • A cylinder with spirals etched out (CSG), plus a cone on top
  • Each spiral is approximated with a chain of cylinders and spheres
Candle flame
  • An ellipsoid with cloudy emissive media for a glow effect
  • Contains an embedded volume light source to light up other objects in the scene
Silver cake tray
  • A very fat, short cylinder
  • Silver reflective and bumpy surface
Bottom plane
  • A boring gray plane that everything sits on