next up previous contents index
Next: 7.28 data/examples/nurbsurf3.dat Up: 7. Source Files Previous: 7.26 data/examples/nurbsurf1.dat   Contents   Index


7.27 data/examples/nurbsurf2.dat


/*
 * FILE: nurbsurf2.dat
 *
 * a half of a cylinder
 *
 */

surf1 = NURBSURF( 
  (0., 0., 1., 1.),
  (0., 0., 0., 0.5, 0.5, 1., 1., 1.),
  (
    ((5., 0.,  0., 0.5), (5., 5.,  0., 0.5)),
    ((5., 0., 2.5, 0.5), (5., 5., 2.5, 0.5)),
    ((5., 0.,  5., 1.),  (5., 10., 5., 1.)),
    ((0., 0., 2.5, 0.5), (0., 5., 2.5, 0.5)),
    ((0., 0.,  0., 0.5), (0., 5.,  0., 0.5))   
  )
);
front1 = FRONT_MATERIAL
(
  (0.05, 0.15, 0.075, 1.0),        /* diffuse color    */
  (0.0125, 0.0375, 0.019, 1.0),    /* ambient color    */
  (0.0, 0.0, 0.0, 1.0),            /* emissive color   */
  (0.2, 0.6, 0.3, 1.0),            /* specular color   */
  0.5                              /* shininess        */
);
back1 = BACK_MATERIAL
(
  (0.3, 0.15, 0.12, 1.0),          /* diffuse color    */
  (0.075, 0.0375, 0.03, 1.0),      /* ambient color    */
  (0.0, 0.0, 0.0, 1.0),            /* emissive color   */
  (0.8, 0.4, 0.3, 1.0),            /* specular color   */
  0.5                              /* shininess        */
);
SCENEROOT = SCENENODE ( 
  (), 
  ( ATTRIBS(front1,back1) ), 
  (surf1)
);


next up previous contents index
Next: 7.28 data/examples/nurbsurf3.dat Up: 7. Source Files Previous: 7.26 data/examples/nurbsurf1.dat   Contents   Index
Administrator 2002-01-20