Custom Blend material/bump map error transition

Got problems with your models? Struggling with textures? Get help with your custom assets.

Re: Custom Blend material/bump map error transition

Postby Groxkiller585 on Sun Sep 12, 2010 10:28 pm

Your trying to make a puddle right?

Just make a decal for it, make a texture that looks sort of like water. Make an animated bumpmap (though have it sutle as it's a puddle) make it transparent, you know the deal. then put it ingame as a decal or overlay, and it should reflect if you buildcubemaps.
User avatar
Groxkiller585
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Fri Jul 09, 2010 3:43 pm

Re: Custom Blend material/bump map error transition

Postby Plague on Sun Sep 12, 2010 10:31 pm

Groxkiller585 wrote:Your trying to make a puddle right?

Just make a decal for it, make a texture that looks sort of like water. Make an animated bumpmap (though have it sutle as it's a puddle) make it transparent, you know the deal. then put it ingame as a decal or overlay, and it should reflect if you buildcubemaps.


Wet surface.
Irc wet asphalt right?
Contact. The EU welcomes the pain free. That's emotional impact.
I actually think limitation is good for creativity. If we had an engine that could do everything, we would be in trouble. It gives us focus. ~~ Randy Lundeen
User avatar
Plague
Veteran
Veteran
 
Joined: Tue Jun 22, 2010 7:12 pm

Re: Custom Blend material/bump map error transition

Postby zzdd on Sun Sep 12, 2010 11:58 pm

The idea of the decal is not bad! 8)
Tomorrow I will try this. This can also simplify my map: I'll get rid of a lot of displacements.
CS:S forever
User avatar
zzdd
Member
Member
 
Joined: Thu Sep 02, 2010 10:46 pm
Location: Italy

Re: Custom Blend material/bump map error transition

Postby pk_hunter on Mon Sep 13, 2010 1:20 am

Pretty sure decals can't have normal maps. Certainly run into problems every time I've tried, anyhoo.
Image
User avatar
pk_hunter
Pheropod
Pheropod
 
Joined: Thu Oct 23, 2008 4:05 pm
Location: Glasgow, UK

Re: Custom Blend material/bump map error transition

Postby Groxkiller585 on Mon Sep 13, 2010 2:38 am

pk_hunter wrote:Pretty sure decals can't have normal maps. Certainly run into problems every time I've tried, anyhoo.


If a decal can't an overlay definetely can, I've seen it myself. Though I've used normal textures for it, not sure your supposed to but hey, it works!
User avatar
Groxkiller585
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Fri Jul 09, 2010 3:43 pm

Re: Custom Blend material/bump map error transition

Postby poisonic on Mon Sep 13, 2010 8:58 am

Did you use a env_cubemap ?? without them reflection sucks big time ;)
[img:400]http://mypsn.eu.playstation.com/psn/profile/poisonic.png[/img]
User avatar
poisonic
Pheropod
Pheropod
 
Joined: Tue Jan 20, 2009 5:10 pm

Re: Custom Blend material/bump map error transition

Postby Groxkiller585 on Mon Sep 13, 2010 10:45 am

poisonic wrote:Did you use a env_cubemap ?? without them reflection sucks big time ;)


Correction: Without env_cubemaps, you don't get ANY reflections. SO yes he has them in the map.
User avatar
Groxkiller585
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Fri Jul 09, 2010 3:43 pm

Re: Custom Blend material/bump map error transition

Postby marks on Sun Sep 19, 2010 4:47 pm

pk_hunter wrote:Pretty sure decals can't have normal maps. Certainly run into problems every time I've tried, anyhoo.


erm, dont bullet-hole decals have normalmaps? I don't understand why you technically couldn't do it unless the engine's decal system just doesnt support it.
User avatar
marks
Creative Assembly
Creative Assembly
 
Joined: Tue Aug 16, 2005 5:07 pm

Re: Custom Blend material/bump map error transition

Postby zzdd on Sun Oct 03, 2010 2:31 am

Omg I've struggled a lot with WorldVertexTransition and no way.
I've tried with normals without alphachannel, fake normals, etc but still I haven't find the solution.
Seems every time I call a envmap it brings some reflection to all the displacement.
Now I'm going to say goodbye to f*****g WorldVertexTransition shader and go on with decals/overlays.
Are you sure that decals/overlays support bump mapping? I've tried in the past with no success.
Any help will be appreciated
CS:S forever
User avatar
zzdd
Member
Member
 
Joined: Thu Sep 02, 2010 10:46 pm
Location: Italy

Re: Custom Blend material/bump map error transition

Postby Groxkiller585 on Sun Oct 03, 2010 4:11 am

Actually may have the solution.

1. make normalmap.

2. make non-reflecting bits have an opacity of 1. ( 0 will NOT work and you cannot see 1 anyway. This is very sensitive as if it's above 1 it will fully reflect. This is in paint.net, the setting may differ in GIMP or photoshop but try it anyway.)

3. add "$normalmapalphaenvmapmask" 1 to your VMT right under "$envmap" "env_cubemap"

4. Check ingame to see if it worked.

Proof it works for me:

Image
User avatar
Groxkiller585
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Fri Jul 09, 2010 3:43 pm

Re: Custom Blend material/bump map error transition

Postby zzdd on Sun Oct 03, 2010 11:31 am

Sorry but I don't understand. What does "make non-reflecting bits have an opacity of 1" mean?
You mean setting the alphachannel of the normal map to 1 (RGB: 1 1 1)?
If this works you have made my day
CS:S forever
User avatar
zzdd
Member
Member
 
Joined: Thu Sep 02, 2010 10:46 pm
Location: Italy

Re: Custom Blend material/bump map error transition

Postby zzdd on Sun Oct 03, 2010 12:43 pm

NICE ONE Groxkiller585!!! :smt023 :-D

Finally I managed it to work!! I've get rid of displacements and I use a Lightmappedgeneric shader instead of WorldVertexTransition.
Following your suggestion, I've created a normal map for my texture. I've filled its alphachannel with RGB(1,1,1) and then painted some puddle-effects with pure white RGB(255,255,255).
The result is that normal map can have transparency and I will use this for creating some puddles in texture.
The cons is that I have to create some more textures, but can be done.

Thank you so much!!! :smt045

PS: I will post some screenshots
CS:S forever
User avatar
zzdd
Member
Member
 
Joined: Thu Sep 02, 2010 10:46 pm
Location: Italy

Re: Custom Blend material/bump map error transition

Postby Groxkiller585 on Sun Oct 03, 2010 4:59 pm

Don't foget you can also do this to make it an overlay.

Make everything not-reflective transparent with an aplha value of 255 255 255. (like you said, see in Paint. net it goes from 255 to 1, basiclly all three channels at once. so if I say 1, yours is 1 1 1. If I said 200, yours is 200 200 200 etc.)

Make the puddle a semi-transparent clear greyish-blue with an alpha of around 50 (dark grey).

Put in "$basealphaenvmapmask " 1 with "$envmap" "env_cubemap". Now your probably wondering why I said to make NON-reflective areas white. The reason is because if it's embedded in the basetexture the colors work in reverse; white is no reflection, black is full reflection. We do this because apperently sometimes normalmaps may not work with overlays/decals so we need to embed it in the texture itself.

Anyway once that's done test it ingame on an overlay AND a decal (to see if it works for both). I don't know if this will work but in theory it should, and it will make adding puddles far easier.
User avatar
Groxkiller585
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Fri Jul 09, 2010 3:43 pm

Re: Custom Blend material/bump map error transition

Postby zzdd on Sun Oct 03, 2010 6:19 pm

The idea sounds good, but if I use alpha from basetexture I can't reach the complexity of a normalmap. The reflection (if it works) will be a plain reflection. Doesn't it?
To reach a realistic reflection I have to work a lot on basetexture. Can be a simple semi-transparent texture with some water works inside. Then I have to build the basetexture alphachannel to reach two goals: the transparency of the texture (infact is a decal/overlay) and the specularity (alphachannel of basetexture is read to build specular map).
Am I wrong?

EDIT:
no I am right :-D

From developer.valvesoftware:
Alpha channels embedded in $basetexture work in reverse. Black areas are reflective, white areas are matte. This is because, say, a window texture's alpha mask would be mostly black to allow for transparency -- yet that black part of the mask would also be the most reflective part. To avoid having to duplicate a .VTF file simply to invert the alpha mask, you can use this VMT parameter instead.
CS:S forever
User avatar
zzdd
Member
Member
 
Joined: Thu Sep 02, 2010 10:46 pm
Location: Italy

Re: Custom Blend material/bump map error transition

Postby zzdd on Sun Oct 03, 2010 7:17 pm

:roll: the decal cannot work because both transparent and reflective areas have to be painted in black in the base-alphachannel. In a puddle transparent areas aren't reflective.
CS:S forever
User avatar
zzdd
Member
Member
 
Joined: Thu Sep 02, 2010 10:46 pm
Location: Italy
PreviousNext

Return to Custom Asset Help

Who is online

Users browsing this forum: No registered users