demos/buddha.py
branchpyrit
changeset 38 5d043eeb09d9
parent 30 33f95441790e
child 60 a23b5089b9c3
equal deleted inserted replaced
37:5f954c0d34fc 38:5d043eeb09d9
    10 from plyreader import LoadStanfordPlyFile
    10 from plyreader import LoadStanfordPlyFile
    11 import Image
    11 import Image
    12 
    12 
    13 rt = Raytracer()
    13 rt = Raytracer()
    14 mat = Material(colour=(0.9, 0.9, 0.9))
    14 mat = Material(colour=(0.9, 0.9, 0.9))
    15 LoadStanfordPlyFile(rt, "../models/happy/happy_vrip_res4.ply",
    15 LoadStanfordPlyFile(rt, "../models/happy/happy_vrip_res2.ply",
    16 	mat, smooth=True, scale=20.0, trans=(0,-3,0))
    16 	mat, smooth=True, scale=20.0, trans=(0,-3,0))
    17 
    17 
    18 light = Light(position=(-5.0, 2.0, 8.0), colour=(0.9, 0.3, 0.6))
    18 light = Light(position=(-5.0, 2.0, 8.0), colour=(0.9, 0.3, 0.6))
    19 rt.addlight(light)
    19 rt.addlight(light)
    20 
    20