Crystal Space: 5.9 Previewing Models (viewmesh)

[ < ] | [ > ] |  | [ << ] | [ Up ] | [ >> ] |  |  |  |  | [Top] | [Contents] | [Index] | [ ? ]

## 5.9 Previewing Models (`viewmesh`)

Viewmesh is a tool included with Crystal Space that can be used to preview models (mesh factories and libraries).

### Commandline Options

- ``-R'` Real path from where to load the model. This option takes a path and then mounts it to ``/tmp/viewmesh'`. Then it sets the current VFS directory to that.
- ``-C'` This is the current VFS directory to use when loading the model. If you use this option in combination with ``-R'` you can change the current directory relative to ``/tmp/viewmesh'`.
- ``-L'` Load a library file (for textures or materials for example). This is a VFS path to the library file (possibly relative to the current VFS dir as given by ``-R'` and ``-C'`).
- ``-Scale'` Scale the loaded object with the given factor.
- ``-RoomSize'` The model is loaded in a room. With this option you can change the size of that room. By default the size is 5.

And then there is an optional filename parameter. Here is an example on how to use viewmesh:

    viewmesh -R=c:\data\gamedata.zip -C=objects/actor factories/genActor

This example requires some explanation. First we use the ``-R'` option to take our game data archive and mount that to ``/tmp/viewmesh'`. Then we use the ``-C'` option to go inside the ``objects/actor'` directory that is inside that ZIP archive. And finally we load the actual model that is still in a deeper directory called ``factories/genActor'`. This example demonstrates how it can be useful to have good control over the current directory in VFS. Usually with models exported from blender2crystal there will be a ``factories'` and a ``textures'` directory. So you want the current directory to be the parent of those so that the model can reference textures like ``textures/bla.jpg'`.

### User Interface

@ TODO

[ < ] | [ > ] |  | [ << ] | [ Up ] | [ >> ]

This document was generated using texi2html 1.76.