IntroductionThe following tutorial guides you through the process of creating a Parallax Occlusion Map, for use in CryEngine levels.
TutorialWe will use a standard (But resized to a size of 512x512) Crysis texture as an example.
[url=http://wiki.crymod.com/index.php/Image
omtut1.jpg]
[/url]
Displacement & Normal mapsOpen the texture file in Crazybump and create displacement and normal maps. Save them to a place you will remember.
Saving to .ddsOpen up the texture file (in this case the crysis example given above) And save it as a .dds, using the Nvidia dds Plugin with the following settings.
[url=http://wiki.crymod.com/index.php/Image
omtut.jpg]
[/url]
Editing in CrazyBumpOpen both the normal map and displacement map we created using CrazyBump. In the Displacement file window, select everything (Ctrl/Strg+ A) and copy it (Ctrl/Strg+C). Next, select alpha channel layer of the normal map and paste into here (Ctrl/Strg+V).
Saving to CryTifYou now need to save this file as in CryTif format, using the photoshop plugin (Installation Instructions) with the following settings.
[url=http://wiki.crymod.com/index.php/Image
omtut3.jpg]
[/url]
NoteDue to a bug in the CryTif plugin, the generated bumpmap texture file may be unreadable by the sandbox. To solve this, simply regenerate it until the Sandbox recognizes it. Also, remember: If you change the bumpmap, the bump info is lost. To fix this problem, save your work and restart the editor.
Creating the .mtl fileOpen notepad and paste the following text in, and remember to write your texture filename where indicated below:
<Material MtlFlags="45" Shader="Terrain.Layer" GenMask="402657284" SurfaceType="Test" Diffuse="1,1,1" Specular="0,0,0" Emissive="0,0,0" Shininess="10" Opacity="1"> <Textures> <Texture Map="Diffuse" File="textures/terrain/detail/YOUR_DIFFUSE_TEXTURE_FILENAME_HERE.dds" > <TexMod TileU="0.5" TileV="0.5"/> </Texture> <Texture Map="Bumpmap" File="textures/terrain/detail/YOUR_NORMAL_MAP_FILENAME_HERE.tif"> <TexMod TileU="0.5" TileV="0.5"/> </Texture> </Textures> <MaterialLayers /> </Material>
Then save it as a .mtl file, and put it in the Game\Materials\Terrain directory (If any of these folders do not exist, create them)
Final stepsCopy/Move both The diffuse (file you started off with(.dds format)) andd your Normal Map (.tif format) to the Game\textures\terrain\detail folder (Again, if folders do not exist create them).
Set the mtl you made in step 4 as the surface type for one of your texture layers, You should now be able to paint POM textures!
[url=http://wiki.crymod.com/index.php/Image
omtutfinished.jpg]
[/url]
PS:这篇文章暂时只能让看得懂E文的人士看,到时候俺才做一下翻译。。。