Urho3D Wik…

Editing

Creating Textures with NeoTextureEdit

1
  • The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit. If you are undoing an edit that is …
Latest revision Your text
Line 1: Line 1:
 
NeoTextureEdit (http://neotextureedit.sourceforge.net/) is a free software (LGPL) Java tool to create procedural and seamless textures with a node based system. It's weird too use, sometimes super slow, lacks documentation and the examples are not that good. This page tries to help a bit.
 
NeoTextureEdit (http://neotextureedit.sourceforge.net/) is a free software (LGPL) Java tool to create procedural and seamless textures with a node based system. It's weird too use, sometimes super slow, lacks documentation and the examples are not that good. This page tries to help a bit.
 
'''Note:''' A Blender method was found to do a similar seamless texture creation using Blender. That may be better as using NeoTextureEdit considering its flaws: [[Creating Seamless Procedural Textures with Blender]]
 
 
'''Note:''' NeoTextureEdit has a bug with loading project files (at least for me). Sometimes it can't be started unless the settings file "TextureEditorSettings" is deleted. Also it doesn't seem to be able to load it's project files properly. The files seem to contain all nodes with all settings but it just load one or two nodes.
 
   
 
=== Program Explanation ===
 
=== Program Explanation ===
Line 16: Line 12:
 
The shipped examples are often using the "FilterEmboss"-Node which is simulating light fall on the material, which seems to be similar to the "Bump Map"-filter in GIMP (Filters->Map->Bump Map). Such an effect is weird to use to create textures as a bump or normal map should be dynamically rendered in the game (if you use normal mapping) using the textures and should not be prerendered into the textures.
 
The shipped examples are often using the "FilterEmboss"-Node which is simulating light fall on the material, which seems to be similar to the "Bump Map"-filter in GIMP (Filters->Map->Bump Map). Such an effect is weird to use to create textures as a bump or normal map should be dynamically rendered in the game (if you use normal mapping) using the textures and should not be prerendered into the textures.
   
The "Blur"-node (the red one, I guess it's red because it's making the calculation sometimes super slow) is used to make the transition between the stone tiles and the gap between them softer. The normal map calculation gives really bad results without this blurring. You can also blur the calculated normal map image afterwards using other tools like Gimp. A slight blur with a radius of 1 or 2 is usually enough.
+
The "Blur"-node (the red one, I guess it's red because it's making the calculation super slow) is used to make the transition between the stone tiles and the gap between them softer. The normal map calculation gives really bad results without this blurring. You can also blur the calculated normal map image afterwards using other tools like Gimp. A slight blur with a radius of 1 or 2 is usually enough.
   
In this example It would make more sense to get the second input of the "Mask"-Node marked with the blue D from the "Blend"-node directly next to the "Normal Map"-node marked with the blue N, as that output is also used to generate the normal map. It was an oversight at first but also avoids using the sometimes super slow "Blur"-node when generating the diffuse map image (that blur takes like an hour on my machine for the material shown here). Would be better to not use the blur at all and blur at least the normal map later with another tool like GIMP, the red channel needs to be inverted anyway for the normal map (see next area).
+
In this example It would make more sense to get the second input of the "Mask"-Node marked with the blue D from the "Blend"-node directly next to the "Normal Map"-node marked with the blue N, as that output is also used to generate the normal map. It was an oversight at first but also avoids using the super slow "Blur"-node when generating the diffuse map image (that blur takes like an hour on my machine). Would be better to not use the blur at all and blur at least the normal map later with another tool like GIMP, the red channel needs to be inverted anyway for the normal map (see next area).
   
 
There is also a plugin for GIMP to create a normal map out of a height map: https://code.google.com/p/gimp-normalmap/ Maybe it's better to export a height map, blur that and create a normal map in GIMP, not sure if blurring a normal map has really no downside.
 
There is also a plugin for GIMP to create a normal map out of a height map: https://code.google.com/p/gimp-normalmap/ Maybe it's better to export a height map, blur that and create a normal map in GIMP, not sure if blurring a normal map has really no downside.
   
 
=== Fixing the Normal Map ===
 
=== Fixing the Normal Map ===
The "Normal Map"-Node in NeoTextureEdit has the red channel inverted compared to the Urho shaders.
+
The "Normal Map"-Node in NeoTextureEdit has the red channel inverted compared to the Urho shaders. You can fix this with custom shaders that interpret the red channel differently or by inverting the red channel of the generated normal map image like this in GIMP:
 
'''Method 1:''' Use a Math-Node in NeoTextureEdit to invert the red channel of the normal map (the math node is selected, see right side for settings):
 
[[File:NTE tiles.jpg|thumb|400x400px|none|link=http://vignette2.wikia.nocookie.net/urho3d/images/7/7a/NTE_tiles.jpg]]
 
'''Method 2:''' You can also fix this with custom shaders that interpret the red channel differently.
 
 
'''Method 3:''' Or by inverting the red channel of the generated normal map image like this in GIMP:
 
   
 
Go to "Colors->Curves" and select the red channel:[[File:NTE fix1.jpg|thumb|400x400px|none]]Move the point in the lower left corner to the top left and the point at the top right corner to the lower right corner and you are done:[[File:NTE fix2.jpg|thumb|400x400px|none]]
 
Go to "Colors->Curves" and select the red channel:[[File:NTE fix1.jpg|thumb|400x400px|none]]Move the point in the lower left corner to the top left and the point at the top right corner to the lower right corner and you are done:[[File:NTE fix2.jpg|thumb|400x400px|none]]
   
 
== Texture Gallery ==
 
== Texture Gallery ==
Mossy stone, based on the cobblestone sample: [https://raw.githubusercontent.com/gawag/Urho-Sample-Platformer/master/blends/mossy_stone.tgr NeoTextureEdit project file]
+
Mossy stone: [https://raw.githubusercontent.com/gawag/Urho-Sample-Platformer/master/blends/mossy_stone.tgr NeoTextureEdit project file]
 
[https://raw.githubusercontent.com/gawag/Urho-Sample-Platformer/master/Build/bin/Data/Textures/mossy_stone_diff.jpg diffuse map]
 
[https://raw.githubusercontent.com/gawag/Urho-Sample-Platformer/master/Build/bin/Data/Textures/mossy_stone_diff.jpg diffuse map]
 
[https://raw.githubusercontent.com/gawag/Urho-Sample-Platformer/master/Build/bin/Data/Textures/mossy_stone_norm.jpg normal map]
 
[https://raw.githubusercontent.com/gawag/Urho-Sample-Platformer/master/Build/bin/Data/Textures/mossy_stone_norm.jpg normal map]
Line 36: Line 32:
 
[[File:NTE mossy stone commented.jpg|thumb|300x300px|center|link=http://vignette4.wikia.nocookie.net/urho3d/images/5/52/NTE_mossy_stone_commented.jpg]]
 
[[File:NTE mossy stone commented.jpg|thumb|300x300px|center|link=http://vignette4.wikia.nocookie.net/urho3d/images/5/52/NTE_mossy_stone_commented.jpg]]
   
<br>Wood planks, based on the "Wood" sample: [http://files.gawag.org/plank_diff.png diffuse map] [http://files.gawag.org/plank_norm.png normal map] [http://files.gawag.org/plank_spec.png specular map] [http://files.gawag.org/wood_planks.xml Urho material file] (project file lost due to crashes)
+
<br>
<br>Here the normal map was not just fixed (the red channel issue) but also blurred with a radius of 2 because the normal map was weirdly chaotic at the slopes.
 
 
[[File:Urho NTE planks-0.jpg|thumb|300x300px|left|link=http://vignette3.wikia.nocookie.net/urho3d/images/9/9d/Urho_NTE_planks-0.jpg]]
 
[[File:Urho NTE planks-0.jpg|thumb|300x300px|left|link=http://vignette3.wikia.nocookie.net/urho3d/images/9/9d/Urho_NTE_planks-0.jpg]]
 
[[File:NTE planks-0.jpg|thumb|300x300px|center|link=http://vignette2.wikia.nocookie.net/urho3d/images/1/1d/NTE_planks-0.jpg]]
 
[[File:NTE planks-0.jpg|thumb|300x300px|center|link=http://vignette2.wikia.nocookie.net/urho3d/images/1/1d/NTE_planks-0.jpg]]
 
<br>Rusty iron plates (also look like bathroom tiles): [http://files.gawag.org/iron_plates.tgr NeoTextureEdit project file] [http://files.gawag.org/iron_plates_diff.png diffuse and specular map] [http://files.gawag.org/iron_plates_norm.png normal map] [http://files.gawag.org/iron_plates.xml Urho material file]
 
[[File:Urho NTE tiles.jpg|thumb|300x300px|left|link=http://vignette4.wikia.nocookie.net/urho3d/images/0/05/Urho_NTE_tiles.jpg]]
 
[[File:NTE tiles.jpg|thumb|300x300px|center|link=http://vignette2.wikia.nocookie.net/urho3d/images/7/7a/NTE_tiles.jpg]]
 
  Loading editor
Below are some commonly used wiki markup codes. Simply click on what you want to use and it will appear in the edit box above.

View this template