File: example-4b.rib

package info (click to toggle)
lg-issue15 2-3
  • links: PTS
  • area: main
  • in suites: hamm, slink
  • size: 1,448 kB
  • ctags: 122
  • sloc: ansic: 113; makefile: 30; sh: 3
file content (55 lines) | stat: -rw-r--r-- 1,275 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#########################################
# Working Example 1c for Linux Gazette
# By Paul M. Sargent (8th Feb 1997)
#########################################

# First we setup the output file 
Display "Example_1c.tiff" "file" "rgb"

# Then set the x & y resolution of the image and the pixel aspect
# ratio (1 = square pixels)
Format 300 300 1

# We now setup the camera (projection type and field of view)
Projection "perspective" "fov" 20

# Move the camera into position
Identity
Translate 0 0 10

# Start Describing the Scene
WorldBegin

# Add the Lightsources
  Attribute "light" "shadows" "on"
  LightSource "spotlight" 1 "from" [1 3 -4] "to" [0 0 0] "intensity" 15
  LightSource "spotlight" 1 "from" [-4 4 -1] "to" [0 0 0] "intensity" 15
  
# Start our first object
  AttributeBegin
    Surface "glass"
    Displacement "stucco"
    Sphere 1 1 -1 360
  AttributeEnd

# Put a Floor in.
  AttributeBegin
    Surface "wood2"
    Patch "bilinear" "P" [-5 -1 -10  
                           5 -1 -10  
  			  -5 -1  5  
			   5 -1  5]
  AttributeEnd
  
# And a Back Wall  
  AttributeBegin
    Surface "wallpaper_2stripe"
    Patch "bilinear" "P" [-5  10  5 
                           5  10  5  
  			  -5 -1   5  
			   5 -1   5]
  AttributeEnd
  
# Finished
WorldEnd