Importing Textures

From Computing and Software Wiki

(Difference between revisions)
Jump to: navigation, search
 
Line 1: Line 1:
-
Texture maps used by the C4 Engine have the .tex file extension.
+
==Getting Started==
-
For more information about Texture Format, please go [http://www.terathon.com/wiki/index.php?title=Importing_a_Texture Importing a Texture]
+
At times you may find that the textures provided are not what you need or possibly too limited for your tastes.  In this case the C4 Game Engine allows you to import your own personal '''*.tga''' files to use as textures for objects.  Many programs such as Adobe Photoshop support this file format and can be used to create Targa files.  Texture maps used by the C4 Engine have the .tex file extension. For more information about texture format, please go [http://www.terathon.com/wiki/index.php?title=Importing_a_Texture Importing a Texture].  The most important thing you need to know for importing *.tga files is that they must be of length and width that is of a '''power of 2'''. (For Example: 32, 64, 128, 256, 512, 1024...)  If the length or width is not correct, you will receive an error message through the console saying that the import failed.
 +
 
 +
==Importing a Targa File (*.tga)==
 +
 
 +
Make sure that your *.tga file is placed somewhere in the '''Import''' folder before you begin.  Start C4 and select '''Tools > Import Texture''' from the engine menu.  The Import Texture window is displayed.  Select the texture you want to import and click OK. A window is displayed that has import options. The default options are usually appropriate for importing a simple texture.
 +
 
 +
[[Image:imptex1.jpg]]
 +
 
 +
Then click OK.  In the console you should see something like the following indicating success '''Imported Texture: *.tga'''.  The texture imports into '''..\C4\Data\tex'''. If you did not see that make sure to check your height and width size of the texture to ensure they are powers of two.  You may now use your imported texture in the world editor to apply to objects.
 +
 
 +
[[Image:imptex2.jpg]]
 +
 
<br>
<br>
-
'''IMPORTANT'''
 
-
<br>TGA files may be in 8-bit grayscale, 16-bit, 24-bit, or 32-bit format, with or without RLE compression
 
-
<br>HEIGHT AND WIDTH OF THE TEXTURE MUST BE POWER OF 2 (example: 2, 4, 8, 32, 64, 128, 256, 512...)
 
-
----
 
-
<br>The texture map resources must be created by importing textures from the "..\C4\Import" directory using the Texture Importer tool module.
 
-
<br>
 
-
Start C4. Select Tool Import Texture
 
-
*pic
 
-
Import Texture window is displayed. Select the texture you want to import and click OK. Another window is displayed.
 
-
*pic
 
-
Another dialog window display and the default settings are usually appropriate for ordinary color texture maps.
 
-
*pic
 
-
Then click OK
 
-
<br>
 
-
Texture import into "..\C4\Data\tex"
 
<br>
<br>
<br>Return to [http://www.cas.mcmaster.ca/wiki/index.php/RCaragogo RCaragogo]
<br>Return to [http://www.cas.mcmaster.ca/wiki/index.php/RCaragogo RCaragogo]

Current revision as of 02:15, 20 March 2008

Getting Started

At times you may find that the textures provided are not what you need or possibly too limited for your tastes. In this case the C4 Game Engine allows you to import your own personal *.tga files to use as textures for objects. Many programs such as Adobe Photoshop support this file format and can be used to create Targa files. Texture maps used by the C4 Engine have the .tex file extension. For more information about texture format, please go Importing a Texture. The most important thing you need to know for importing *.tga files is that they must be of length and width that is of a power of 2. (For Example: 32, 64, 128, 256, 512, 1024...) If the length or width is not correct, you will receive an error message through the console saying that the import failed.

Importing a Targa File (*.tga)

Make sure that your *.tga file is placed somewhere in the Import folder before you begin. Start C4 and select Tools > Import Texture from the engine menu. The Import Texture window is displayed. Select the texture you want to import and click OK. A window is displayed that has import options. The default options are usually appropriate for importing a simple texture.

Image:imptex1.jpg

Then click OK. In the console you should see something like the following indicating success Imported Texture: *.tga. The texture imports into ..\C4\Data\tex. If you did not see that make sure to check your height and width size of the texture to ensure they are powers of two. You may now use your imported texture in the world editor to apply to objects.

Image:imptex2.jpg




Return to RCaragogo


References
http://www.terathon.com/wiki/index.php?title=Importing_a_Texture

Personal tools