Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

xracer-mkmeshnotex(1) [debian man page]

XRACER-TOOLS(1) 					      General Commands Manual						   XRACER-TOOLS(1)

NAME
xracer-mkmeshnotex -- XRacer texture coordinates maker SYNOPSIS
xracer-mkmeshnotex [--outputc OUTPUTFILE] --texture TEXTURE [--texscale TEXSCALE] [--rottexture ROTATION] [--cprefix CPREFIX] [--ver- bose] [INPUTFILE] DESCRIPTION
This manual page documents briefly the xracer-mkmeshnotex command. This manual page was written for the Debian distribution because the original program does not have a manual page. xracer-mkmeshnotex is a perl script that exports meshes with texture coordinates to Blender. This script takes a simple VideoScape-format mesh file INPUTFILE, adds textures coordinates TEXTURE to it using a very simple algorithm, and generates C source file OUTPUTFILE that contains code suitable to be a scenery object to your track in the game XRacer. OPTIONS
--outputc OUTPUTFILE the C file to write --texture TEXTURE the texture to use --texscale TEXSCALE the texture scale factor (default: 1.0) --rottexture ROTATION the amount to rotate the texture (in degrees - currently only 0, 90, 180, 270 are supported) --cprefix CPREFIX the name to use before all C identifiers --verbose verbose output SEE ALSO
xracer (6), XRacer::BVRML (3pm) AUTHOR
This manual page was written by Ying-Chun Liu (PaulLiu) <grandpaul@gmail.com> for the Debian system (but may be used by others). Permis- sion is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 2 any later ver- sion published by the Free Software Foundation. On Debian systems, the complete text of the GNU General Public License can be found in /usr/share/common-licenses/GPL. XRACER-TOOLS(1)

Check Out this Related Man Page

BlenderImport(3pm)					User Contributed Perl Documentation					BlenderImport(3pm)

NAME
XRacer::BlenderImport - Import files exported by xracer-blenderexport.py SYNOPSIS
use XRacer::BlenderImport; $world = parse XRacer::BlenderImport [ $filename ]; $index = $world->add_vertex ($vertex); $verticesref = $world->get_vertices; %layerinfo = $world->get_layer_info; @objects = $world->get_meshes_in_layer ($layer); DESCRIPTION
The "XRacer::BlenderImport" module contains functions for importing special XRacer-specific Blender files into Perl scripts. These Blender files have been previously exported by the "xracer-blenderexport.py" Python script for Blender. The "XRacer::BlenderImport" module parses the "blender.export" file, cleans it up (removing multiple vertices, for example) and presents an internal world representation. The world is divided into layers (corresponding to the layers in the original Blender image), and in each of these layers is a set of meshes. FUNDAMENTAL TYPES Vertices are stored in a global list, so that common vertices are only stored once. A vertex structure looks like this: $vertex = { coords => [ $x, $y, $z, 0 ], texcoords => [ $u, $v ], normal => [ $nx, $ny, $nz, 0 ], colour => [ $r, $g, $b, $a ] }; The fields are (in order): the coordinates of the vertex, the texture coordinates, the normal vector at this point and the colour of the vertex. Faces are stored simply as a list of vertex indices (relative to the global list of vertices). A face looks like this: $face = { vertices => [ $index0, $index1, $index2, ... ] } Faces have at least three vertices, and maybe more. A mesh is a list of faces and additional information, such as the name of the mesh (object). A mesh structure looks like this: $mesh = { name => $name, layer => $layer, faces => @faces, material => [ $red, $green, $blue ], has_colours => $has_colours, has_texcoords => $has_texcoords, has_material => $has_material }; The fields are: the name of the mesh (or object), the layer on which the object exists, the list of faces, the material and then three flags which are passed to us from Blender: did the user supply vertex colours? did the user supply texture coordinates? and did the user supply a material? CLASS METHODS
$world = parse XRacer::BlenderImport [ $filename ]; Parse the import file $filename (or "blender.export" if no filename is given) and generate a world representation. If the file could not be parsed, then this function will print an error message and return "undef". OBJECT METHODS
$index = $world->add_vertex ($vertex) This function adds a single vertex to the world object (vertices are stored in a large shared list so that common vertices are folded into one). It returns the vertex index of the new vertex. If another vertex with the same position, texture coordinates, normal and colour existed, then this function would return the index of the other vertex, rather than creating a fresh vertex object. $verticesref = $world->get_vertices This returns a reference to the global list of vertices. You must not update or change this list. Use the "add_vertex" method instead. %layerinfo = $world->get_layer_info This method returns a hash. The keys of the hash are layers which contain at least one object. The values of the hash are the number of objects in that layer. For example, if the world contained 3 objects on layer 1, 1 object on layer 2 and 4 objects on layer 5, then the hash returned would be equivalent to: %layerinfo = ( 1 => 3, 2 => 1, 5 => 4 ); @objects = $world->get_meshes_in_layer ($layer) Get a list of the objects (i.e. meshes) found in layer $layer. See the DESCRIPTION section above for a description of the mesh structure. AUTHOR
Richard W.M. Jones, <rich@annexia.org> COPYRIGHT
XRacer is copyright (C) 1999-2000 Richard W.M. Jones (rich@annexia.org) and other contributors listed in the AUTHORS file. SEE ALSO
perl(1), xracer(6). perl v5.14.2 2000-01-30 BlenderImport(3pm)
Man Page