Detail textures
by Krzysztof Szaton · in Technical Issues · 09/07/2008 (12:46 pm) · 11 replies
Hello.
I have only one question this time;) Can I have multiple detail textures on my one object? For example: building with wood door. How can I define where engine(TGEA) will display brick detail and where wood. I'm not sure if i understand detail texture methodology. Thanks for advice.
I have only one question this time;) Can I have multiple detail textures on my one object? For example: building with wood door. How can I define where engine(TGEA) will display brick detail and where wood. I'm not sure if i understand detail texture methodology. Thanks for advice.
#2
09/17/2008 (1:31 am)
Ok. Thank You. This is what i need;)
#3
09/17/2008 (6:31 pm)
I believe TGEA has detail maps disabled, doesn't it?
#4
09/17/2008 (6:53 pm)
It does. Anybody knows how to add them back?
#5
09/22/2008 (12:12 am)
What was the reason for not giving TGEA detail texture function?
#6
In TGE detail maps were a feature of DTS.
In TGEA detail maps are part of the Material system. So in TGEA you do...
In TGEA 1.8 ... which also supports OSX... you have a new parameter in the material settings:
After 1.8 expect support for at least 2 UV sets in DTS (possibly a variable amount) and control for which UV set to use with any texture slot in the Material.
09/22/2008 (8:38 am)
TGEA does support detail maps... it just does them differently than TGE.In TGE detail maps were a feature of DTS.
In TGEA detail maps are part of the Material system. So in TGEA you do...
new Material(BrownGreenRock)
{
baseTex[0] = "./BrownGreenRock.dds";
bumpTex[0] = "./BrownGreenRockBump.dds";
detailTex[0] = "./BrownGreenRockDetail.dds";
pixelSpecular[0] = true;
specularPower[0] = 15;
};... while this works, you don't get control of the detail texture repetition. Its just set to a hard coded value at the moment.In TGEA 1.8 ... which also supports OSX... you have a new parameter in the material settings:
new Material(BrownGreenRock)
{
baseTex[0] = "./BrownGreenRock.dds";
detailTex[0] = "./BrownGreenRockDetail.dds";
detailScale[0] = 4.0;
};Which gives you control of the UV scale for applying the detail... more reason to check out the 1.8 beta.After 1.8 expect support for at least 2 UV sets in DTS (possibly a variable amount) and control for which UV set to use with any texture slot in the Material.
#7
09/23/2008 (11:16 am)
Hello Tom. I have question: how they(technically) work in TGEA? Detail texture is texture that model uses when player is near it? Or this is texture that is multiply by base textuse? I made two textures... base (all white) and detail(all black). My model was black. Even when I was far away. I used Your code. Thank You for explanation!
#8
@Chris ~ black and white aint gonna help you much, use a blurred color texture (say wood) and a grayscale tileable wood pattern for detail. Then you'll see the difference.
09/23/2008 (11:27 am)
@Tom ~ in TGEA 1.7.1 I tried the detailMap code but all I've got was a darker diffuse map; I tried it a few days ago from XSI and I know I tried several times from Max. Perhaps I should move on to 1.8 already@Chris ~ black and white aint gonna help you much, use a blurred color texture (say wood) and a grayscale tileable wood pattern for detail. Then you'll see the difference.
#9
Also Chris's issue brings up another point. The DTS detail map feature would lod out distance... Chris is always getting a black model because his detail map was always on.
So what would we do to support detail map lod in the material system? In DTS at least it wasn't just a distance to the model... it was based on the pixel size of the model on screen.
I'm thinking that the material system doesn't need to know how to do this... but that it needs a hook for support it. Like maybe Material::setLodFactor( F32 zeroToOneLodState ).
Any ideas/suggestions on how this should work?
09/23/2008 (11:58 am)
@Apparatus - Strange... well lets be sure you test out the detail maps via materials in the 1.8 beta. I'll do what i can to make sure it works for you.Also Chris's issue brings up another point. The DTS detail map feature would lod out distance... Chris is always getting a black model because his detail map was always on.
So what would we do to support detail map lod in the material system? In DTS at least it wasn't just a distance to the model... it was based on the pixel size of the model on screen.
I'm thinking that the material system doesn't need to know how to do this... but that it needs a hook for support it. Like maybe Material::setLodFactor( F32 zeroToOneLodState ).
Any ideas/suggestions on how this should work?
#10
If my detail textures must be a grayscale that means that on very dark models detail texture will not show up? Right?
Here's my today try:
img139.imageshack.us/my.php?image=ttestwk5.jpg
I used TGEA(1.7.1) demo with rock model(from this demo). I also tryed Apparatus fix(Your screenshot from link in first post look great) but in 1.7.1 code looks different.
09/24/2008 (2:20 am)
@ApparatusIf my detail textures must be a grayscale that means that on very dark models detail texture will not show up? Right?
Here's my today try:
img139.imageshack.us/my.php?image=ttestwk5.jpg
I used TGEA(1.7.1) demo with rock model(from this demo). I also tryed Apparatus fix(Your screenshot from link in first post look great) but in 1.7.1 code looks different.
#11
And detail textures can indeed be color textures just as fine, only you need to tweak them a bit so the final result is nut burning your eyes.
09/24/2008 (2:32 am)
If the base texture is very dark why bother adding detail in the first place; But in any case, it is still visible - even if that means that the model is a tone darker than without detail. Try the same thing with something else, something like a pattern (or add some letters to your detail texture) so we can tell. And detail textures can indeed be color textures just as fine, only you need to tweak them a bit so the final result is nut burning your eyes.
Torque 3D Owner Apparatus
See this thread for some more info:
How to fix the detail maps in stock tge 1.5.2