|PathEngine home||previous: ||next: |
Provides a worked example of a split content process based on initial creation of 'content chunks' which are then later instantiated for PathEngine's content processing.
This project provides a worked example of this functionality with units setup to enable both both effective pre-validation of the content chunks and per instance scaling of the chunks.
The example loads four content chunks (from 'SDKRoot/resource/content') and places instances of these chunks as a fix set of hard-coded positions to generate a PathEngine ground mesh.
The content chunks are modelled in Max at a scale of 1 unit == 1 centimetre.
A PathEngine coordinate unit of 1 millimetre is then chosen so that the chunks can be scaled up when they are placed into the world.
This enables the chunks to be usefully scaled both up and down by the integer scaling versions of the content chunk placement methods.
(A scale value of 10 indicates that the object is placed at the modelled scale. A value of 9 scales the object down slightly. A value of 11scales the object up slightly, and so on.)
Using the integer scaling versions of the placement methods means that content chunk pre-validation can be applied effectively.
If object scaling is not desired then objects can be modelled at the same scale as the base PathEngine unit without any problems.
If more precise rotation and scaling are required then floating point versions of the content chunk
placement methods can be used.
In this case the implication is that validation errors can be introduced when geometry is placed at certain angles and scales.
The terrain part of the environment is generated
procedurally (by deriving a suitable class from
This approach can be used in real-world situations
where the terrain callback mechanism is being used to enable terrain height detail to be stripped
out of PathEngine's ground mesh.
In this case, the height of terrain parts of the mesh is irrelevant, because PathEngine will
callback to a client-side terrain representation for heights in these parts of the mesh.
(This is why the resulting mesh includes some huts which appear to float some distance above the terrain.)
Alternative approaches to representing the terrain parts of an environment include using a hand modelled mesh for this terrain, and procedural generation of a base terrain mesh from a tiled representation.
The 3DS Max source files for each of the content chunks can be found in the file '3DSMaxExampleMeshes.zip', which can be found on the PathEngine downloads page.
|Documentation for PathEngine release 6.00 - Copyright © 2002-2016 PathEngine||next: |