From cbc79ddecb5ceaaecfb812b619395b9c3c3568f6 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Mon, 9 Feb 2009 19:55:43 +0000 Subject: updated textures section of the modelling manual --- doc/models.html | 90 +++++++++++++++++++++++++++++++++------------------------ 1 file changed, 53 insertions(+), 37 deletions(-) diff --git a/doc/models.html b/doc/models.html index 740bc3d..f4c5513 100644 --- a/doc/models.html +++ b/doc/models.html @@ -45,7 +45,7 @@
  • Clip
  • Detail brushes
  • Textures -
  • Surface flags +
  • Shader files
  • Lights
  • Flares
  • Particles @@ -69,7 +69,7 @@ Note that it does not include the Osirion support files by default.

    This document will not explain how to use the editor. Consult google - for numerous tutorials on this subject. Any basic brush-creating + for numerous tutorials on this subject. All basic brush editing techniques for any Quake-engine based game can be used.

    The main difference with other games is that you are not creating @@ -127,55 +127,71 @@ is within detail range, close enough to the camera. When it is further away, only structural brushes will be rendered. The actual detail range depends on the size of the model. +

    This means that any object that could only been seen from close by should be made from detail brushes. +

    This has one improtant implication: if you show the structural brushes only (with the CTRL+D filter in Gtkradiant) there should be no obvious gaps of caulk that were previously hidden behind detail brushes. - -

    - Textures -

    -

    - The engine does not support textured models. Every brush face is drawn - using a single color and any real texturing information is ignored.

    - The color textures in the directory /textures/colors can be used by - the editor. The engine translates these textures into RGB colors - when the model is loaded. Unknown textures will be colored hot pink. +

    + Materials +

    - The fixed set of colors is rather limited, more colors can be added by - using the common/entity_* family of textures. The actual in-game + While the engine does support several image file formats, it does not + support textured models. Instead the model brushes will be rendered + using plain colors. The engine uses a material system similar to Quake 3 Arena + shader files, to provide an easy way to apply the different colors. +

    + The file materials/shaderlist.txt contains a list of shader files + that can be used by the engine. Each shader file can contain several materials. +

    + The default shaderlist.txt looks like this: +

    +
    +common
    +colors
    +
    +

    + On startup, the engine will read materials from the files materials/common.shader + and materials/colors.shader. If a model contains an unknown material, + a warning will be given and the brushes will be colored hot pink. +

    + In radiant, the materials can be used as normal textures, like you can with + Quake 3 Arena shaders. A number of default materials are already defined + and can be used out of the box. +

    + The materials in the colors/ directory can be used to + draw brush faces with a specified color. The actual RGB color is defined + by the material script. Examples are red, green and blue. +

    + The default set of colors is rather limited, more colors can be added by + using the common/ family of materials. The actual in-game color information for these faces will be provided by the engine. -

    - The special texture common/entity represents an object's primary color. - In-game the faces with this texture will be drawn in the color that the entite has - provided as the object's primary color. For example, for player-controled ships will - have their owner's color as primary color. -

    - Similar, the texture common/entity_second represents on object's secondary - color. common/entity_third will be a mix of the primary and secondary color. - Each of these textures also has a _dark variant. -

    - You can also use two other special textures: as explained above, - faces with the common/caulk texture will be ignored on load. -

    - The common/clip texture is reserved for - future use. At the moment they will be ignored as well.

    - At the time of writing, texture names are hardcoded - in src/model/map.cc. +

    + The common/entity material represents an object's primary color. + In-game the faces with this texture will be drawn with the primary color of the entity + that uses the model. For example, a player's ship will have its owner's color. + Similar, the material common/entity_second represents the secondary + color of an entity. common/entity_third will be a mix of the primary and secondary color. + Each of these materials also has a _dark variant. +

    + There are two special material that will cause the brush faces to be ignored + by the engine: as explained above, the common/caulk material can be used + on hidden faces. The common/clip material is reserved for future use + brush faces using this texture will be ignored as well. +

    -

    - Surface flags +

    + Shader files

    - The only supported surface flag is light. This will render - the brush face fullbright and can be used to create light-emiting objects - or windows. - + TODO: write a section on shader files. +

    Lights

    -- cgit v1.2.3