m a t r i x    c o m p o s i t i o n


This page demonstrates the basics of scripting shapes directly into a RenderMan RIB file. Coding shapes in this way focuses attention on the use of color, opacity and the fundamental concepts related to xyz coordinate system.





This image shows the composition with basic shading, no displacements, no depth of field, and a basic lighting setup without shadows. All objects were saved as pre-baked ribs.

			
			
			
			
			



This image depicts the shadow setup that will be used in the final composition.

Here's the code for the primary shadow casting lights in my scene.
The last is a fill light.			
			
LightSource  "shadowspot" 1 "intensity" 35 "from" [0.75 10 0] "to" [.75 0 0]
		"lightcolor" [1.0 1.0 1.0]
		"shadowname" ["Mainspot1.tx"]
		"width" 8
		"samples" 32
		"beamdistribution" 2.0
LightSource "shadowspot" 2 "intensity" 65 "from" [-6 6 10] "to" [-6 0 0]
		"shadowname" ["fillspot1.tx"]
		"width" 8
		"samples" 32
		"beamdistribution" 2.0
LightSource "shadowspot" 3 "intensity" 50 "from" [3 4 15] "to" [3 0 0]
		"shadowname" ["fillspot2.tx"]
		"width" 8
		"samples" 32
		"beamdistribution" 2.0
LightSource "pointlight" 2 "intensity" 8 "from" [1.75 3 2]
		"lightcolor" [.05 .85 .05]
			



Here's the final composition with displacements, materials, and texturing applied. Everything was created from code. All elements are in focus.




Here's a low-angled camera placed directly in front of the composition. Depth of field is used so foreground and background elements are slightly blurred.

			
			
			



The camera is placed on the left side of the scene with depth of field that draws attention to a red-lit building.

These images show the color and displacement 
maps used to get the building details.
		

			
			
		



From a high angle on the right side of the scene, we can see the street down below and UFOs in focus.

			
			
			
			
			



Down on the street, we can see the transition of depth of field clearly.

This code created the camera angle and depth of field.

DepthOfField 25 1 8
Translate  -1.1 -1.25 11
Rotate 5 1 0 0
Rotate 74 0 1 0
Scale 1 1 -1
			




Here's a rotation of the scene.