/* @(#)bumpy.sl 1.1 (Pixar - RenderMan Division) 9/28/89 */ /*-______________________________________________________________________ ** ** Copyright (c) 1989 PIXAR. All rights reserved. This program or ** documentation contains proprietary confidential information and trade ** secrets of PIXAR. Reverse engineering of object code is prohibited. ** Use of copyright notice is precautionary and does not imply ** publication. ** ** RESTRICTED RIGHTS NOTICE ** ** Use, duplication, or disclosure by the Government is subject to the ** following restrictions: For civilian agencies, subparagraphs (a) through ** (d) of the Commercial Computer Software--Restricted Rights clause at ** 52.227-19 of the FAR; and, for units of the Department of Defense, DoD ** Supplement to the FAR, clause 52.227-7013 (c)(1)(ii), Rights in ** Technical Data and Computer Software. ** ** Pixar ** 3240 Kerner Blvd. ** San Rafael, CA 94901 ** ** ______________________________________________________________________ */ displacement bumpy2( float amplitude = 1; string texturename = "";) { if (texturename != "") { N += bump(texturename, N, dPdu, dPdv) * amplitude; } point Nf; Nf = faceforward(normalize(N),I); Oi = Os; Ci = Os * Cs * (1*ambient() + 1*diffuse(Nf) ) ; }