Blender homepage link
header graphic
 

Test Cases

This page holds a (hopefully growing, over time) number of test cases for Verse applications, expressed as VML files. The intent is to capture some particular aspect of a 3D scene, and store it in a reusable form in VML, so that developers working on Verse-aware applications (renderers, savers/loaders, and other tools) can have some easy-to-obtain test data. Suggestions on what to include here are welcome.

To save a test file for local use, right-click the test's title, and pick "Save Link As..." in your browser's menu (or use an equivalent solution, depending on your browser).

You can also access these tests through the tests/ directory in the vml CVS module.

position



This test tests the positioning part of the Verse transform. Three cubes are shown (sharing the same geometry node), each at a different position. Please notice that the positions are not symmetrical; each of the three objects is at different distance from the origin.


rotation



This test creates a single geometry node, and then links to it using three object nodes. The geometry creates an arrow, pointing in Verse's native "forward" direction of negative Z. The objects then use their transforms to rotate the geometry so that one arrow points in each of the positive X, Y and Z directions. This is useful to test how a renderer implements rotation support, for instance.

scale



This test contains three cubes, all located at the origin. Object scaling is used to stretch each cube in one of the X, Y and Z directions. Because the cube is defined asymmetrically at the vertex level, it scales differently along the Y axis.

position+scale



This test creates a cube geometry, which is then linked to by six object nodes. The objects use position and scaling, combined, to create the scene shown. Note that the objects do not overlap.

children



This test uses Verse's support for hierarchical transform to create a simple two-level scene depicting a simple car-like object. The root object is the central body of the car, and the four wheels are children of the body. The body is rotated to face towards the "north west" (negative X and Z). Note how the wheels inherit this rotation and are oriented the same way, although their transforms in the file have a zero rotation.

bitmap



This file uploads a simple bitmap. It can be used to test bitmap storage and handling in a client. Note that unlike e.g. the transform tests above, it does not define a full Verse "scene"; there is only a bitmap node contained in the VML file. You must use some bitmap-aware tool to view the image, as it won't render using a standard rendering client.

texturequad



This test defines a simple geometry, consisting of a single quadrilateral. It then defines a material, and a bitmap (the same as in the bitmap test, above). The geometry contains UV-mapping data, and the material defines the simplest possible texture-mapping. The result is a texture-mapped quadrilateral. The screenshot is from Connector.

multimaterial



This test shows how to express multiple materials on a single geometry using Verse. There is a HOWTO that describes the technique used in detail. There are also comments in the VML file itself. Please note that it is not required to have a unique material node per face, it is possible to re-use them too. Also, using multiple materials is not the easiest way to express just a change in color per face, but it keeps the material definitions simple.

sphere



This test defines a sphere, using subdivision surfaces. The base mesh geometry, if rendered without subdivision, is a cube. Explicit crease layers full of zeroes are used for both vertex and edge sharpness, to be very clear. The screenshot is from Connector.

cylinder



A cylinder. This is created using subdivision surfaces, by creasing a cube. The VML file also defines a light source, so that the cylinder is lit from above and a bit from the side. The screenshot is from Connector. The "spot" close to the center is simply the light source, which is visualized as a small flare.