Source for file torus.php
Documentation is available at torus.php
require_once('Image/3D.php');
$light = $world->createLight ('Light', array (-2000 , -2000 , -2000 ));
$redLight = $world->createLight ('Light', array (90 , 0 , 50 ));
$torus = $world->createObject ('torus', array ('inner_radius' => 110 , 'outer_radius' => 170 , 'detail_1' => 60 , 'detail_2' => 30 ));
$torus->transform ($world->createMatrix ('Rotation', array (60 , -10 , 0 )));
$renderer = $world->createRenderer ('perspectively');
$world->createDriver ('GD');
$world->render (500 , 500 , 'Image_3D_Object_Torus.png');
Documentation generated on Mon, 11 Mar 2019 15:48:15 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.
|