home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 16
/
CD_ASCQ_16_0994.iso
/
news
/
4613
/
char.rrt
< prev
next >
Wrap
Text File
|
1980-01-10
|
5KB
|
240 lines
// Real Ray Tracer
// 'Un char à voile' to break the speed world record.
// Designed by Fabrice LAMIDE & Pascal HAUTIN
// June 1994
#include "colors.inc"
#include "shapes.inc"
#include "textures.inc"
camera {
location <-10 4 -12>
point_at <-1.5 0 0>
angle 16
}
environment {
// background color Blue
// clouds
sky
color_map { [0 1 color Blue color White ] }
fall_off 0.09
}
//object { light_source { <4 10 -8> intensity 10 color White } }
object { light_source { <-30 40 -80> intensity 40 color White } }
#declare Materiau = texture {
color White
ambient 0.15
diffuse 0.55
reflection 0.30
phong 0.35
phong_size 90
}
#declare Verre = texture {
Phong_Transparent
color SkyBlue
diffuse 0.05
refraction 0.95
}
#declare Long_Voile = 0.3
#declare Larg_Voile = 4.5
#declare Haut_Voile = 10.0
#declare Long_Traverse1 = 7.00
#declare Larg_Traverse1 = 0.40
#declare Epais_Traverse1 = 0.15
#declare Long_Traverse2 = 7.00
#declare Larg_Traverse2 = 0.35
#declare Epais_Traverse2 = 0.15
#declare Abaisser_trav = -0.375
#declare Long_Cockpit = 1.0
#declare Larg_Cockpit = 2.5
#declare Epais_Cockpit = 0.8
#declare Rayon_Jante = 0.5
#declare Rayon_Pneu = 0.05
#declare Somme_Rayons = 0.55
#declare M_Somme_Rayons = -0.55
#declare Voile = object {
union {
intersection {
QCone_Y
slab { <0 1 0> 0.5 1 }
translate <0 -0.5 0>
scale <2 20 2>
scale <0.9987523389 0.9987523389 0.9987523389>
}
intersection {
Ellipsoid
slab { <0 1 0> -0.049937617 -1 }
translate <0 0.049937617 0>
}
}
rotate <0 0 180> // Symetrie /Oxz
scale <0.0909090909 0.0909090909 0.0909090909>
translate <0 0.908 0>
scale <Larg_Voile Haut_Voile Long_Voile>
texture { Materiau }
}
#declare Traverse1 = object {
intersection {
intersection {
Cylinder_Z
plane { <0 -1 0> 0 }
}
slab { <0 0 1> -0.5 0.5 }
}
texture { Materiau }
}
#declare Traverse2 = object {
intersection {
intersection {
intersection {
Cylinder_Z
plane { <0 -1 0> 0 }
}
slab { <0 0 1> -0.5 0.5 }
}
object { Ellipsoid scale <1 1 0.5> }
}
texture { Materiau }
}
#declare Cockpit = object {
difference {
difference {
object { Ellipsoid }
object { Ellipsoid scale <0.93 0.93 0.93> }
}
box { <-1 0.333 -1> <0.5 1 1> }
}
texture { Materiau }
}
#declare Hublot = object {
intersection {
difference {
object { Ellipsoid }
object { Ellipsoid scale <0.93 0.93 0.93> }
}
box { <-1 0.333 -1> <0.5 1 1> }
}
texture { Verre }
}
#declare Siege = object {
difference {
box { <-0.2 -0.5 -0.5> <0.5 0.45 0.5> }
box { <-1 -0.4 -1> <0.4 1 1> }
}
texture { color Red }
}
#declare Cabine = object {
bound {
object { Cockpit }
object { Hublot }
object { Siege }
}
by box { <-1 -1 -1> <1 1 1> }
scale <0.5 0.5 0.5>
scale <Larg_Cockpit Epais_Cockpit Long_Cockpit>
}
#declare Jante = object {
intersection {
object { Cylinder_Z }
slab { <0 0 1> -1 1 }
}
scale <Rayon_Jante Rayon_Jante Rayon_Pneu>
texture { Materiau }
}
#declare Pneu = object {
difference {
torus { <0 0 0> <0 0 1> Rayon_Jante Rayon_Pneu }
object { Cylinder_Z scale <Rayon_Jante Rayon_Jante 1> }
}
texture {
color Black
ambient 0.2
diffuse 0.4
reflection 0.2
phong 0.3
phong_size 90
}
}
#declare Roue = object {
bound {
object { Jante }
object { Pneu }
}
by sphere { <0 0 0> Somme_Rayons }
}
#declare Sable = object {
plane { <0 1 0> Abaisser_trav }
translate <0 M_Somme_Rayons 0>
texture {
color red 1.0 green 0.75 blue 0.25
ambient 0.20
diffuse 0.55
bump { bumps 0.3 scale <0.05 0.05 0.05> }
}
}
object { Sable }
object {
composite {
object { Voile translate <0.30 Abaisser_trav 0> }
object { Cabine translate <-0.20 0 -0.80> }
object {
Traverse1
scale <Larg_Traverse1 Epais_Traverse1 Long_Traverse1>
translate <0 Abaisser_trav 0>
}
object {
Traverse2
scale <Larg_Traverse2 Epais_Traverse2 Long_Traverse2>
rotate <0 90 0>
translate <0 Abaisser_trav 3.6>
}
}
translate <0 -0.25 0>
}
object { Roue translate <0 Abaisser_trav -3.5> }
object { Roue translate <-3.75 Abaisser_trav 3.55> }
object { Roue translate <3.75 Abaisser_trav 3.55> }
end.