Implementation

RenderGibbon will be a subset of the RenderMan shading language. It will allow surface shading and surface displacement, but will not implement light source descriptions or volume shaders (atmospheric effects). Some of the more exotic procedures available in the RenderMan language may not be available in RenderGibbon. Particularly those that are more appropriate for shaders not supported by RenderGibbon. It is possible that a shader written in the RenderMan language will compile and even work exactly as intended in its simian counterpart--however, that is not the aim of the project. The aim of this project is to provide an easy method of experimentation with writing textures in a formal environment. RenderMan provides a very elegant solution to this. As such, RenderGibbon will be based more on the spirit of RenderMan rather than trying to duplicate exact performance. RenderGibbon will also be limited to polygon scenes to reduce the scope of the project. Shadows will also be ignored.

RenderGibbon will be implemented as a scan-line converter. However, since transparency must be handled properly, a Z-buffer solution is not possible. Therefore, an A-buffer (anti-aliased, area-averaged, accumulation buffer) will be used. The project will consist of two main modules: a shading language compiler and the rendering engine itself. The shading compiler will input a shading module, perform syntax checking and produce a compiled object module in an intermediate format suitable for the rendering program to process.

Two shader classes will be allowed in RenderGibbon: surface shaders and displacement shaders. Surface shaders modify the appearance of the object calling that shader. Primarily, the concern of the surface shader is to generate the appropriate pigment and finish at a given point. Typical examples of surface shaders are plastic shaders (essentially, the Phong shading model) and marble shaders.

Displacement shaders perturb the object surface point by point. This allows a shader to add apparent geometric complexity to a simple model. For instance, the bumps on an orange could be specified as a displacement texture. The model of the orange itself could be a simple sphere, rather than trying to explicitly model every pip and bump. Displacement mapping will first only function by modifying the surface normals (bump-mapping) but will be expanded to perform true displacement if time permits.

The renderer will read in a scene described in a very simple scripting language, similar to the one developed for the ray-tracing program during winter term. Objects will be specified as raw triangular data, with texture points and normal vectors specified for each vertex.


Bibliography End