Transparent water

Having a problem with a shader or texture
RedSnappa
Posts: 323
Joined: Sun Aug 21, 2011 12:10 pm
Location: North Carolina (USA)

Re: Transparent water

Post by RedSnappa »

A few questions concerning the shader I just posted:
1. What does q3map_globaltexture do?
2. Why does it have fogparms when surfaceparm fog is not listed?
3. What does tessSize 64 do?
4. I know deformVertexes makes the water have waves. I don't know what the numbers do.
5. textures/hedo/env/reflejo3.jpg looks like a skybox texture. Why would it be blended with water?
6. textures/hedo/pmarron.tga is actually a .jpg file, but it still works. Does file extension not matter?
[LCDLC]Snappa
LCDLC Mapmaking Dept.
Maps finished: Hellhouse, Sorry, Worrior 1-20
Maps modded: CubeOrigin
Maps in release candidate: Blockforts, Cannons 1, Hotzone, Icecastle
Maps in beta: Arctica, Cannons 2, Cerulean-River, Igloo, Skygarden, Spacestation
Maps in alpha: Merlin, Totem

RedSnappa
Posts: 323
Joined: Sun Aug 21, 2011 12:10 pm
Location: North Carolina (USA)

Re: Transparent water

Post by RedSnappa »

My texture has an alpha channel but this shader isn't working. I still need to know how this other shader works as well.
[LCDLC]Snappa
LCDLC Mapmaking Dept.
Maps finished: Hellhouse, Sorry, Worrior 1-20
Maps modded: CubeOrigin
Maps in release candidate: Blockforts, Cannons 1, Hotzone, Icecastle
Maps in beta: Arctica, Cannons 2, Cerulean-River, Igloo, Skygarden, Spacestation
Maps in alpha: Merlin, Totem

User avatar
Delirium
Posts: 366
Joined: Sat Aug 27, 2011 8:37 am
Location: Auckland, New Zealand

Re: Transparent water

Post by Delirium »

Ive posted shaders and comands to use. if you avoid my help how am i meant to help you further?

As for what certain things do i suggest you use the q3 shader manual
Image

RedSnappa
Posts: 323
Joined: Sun Aug 21, 2011 12:10 pm
Location: North Carolina (USA)

Re: Transparent water

Post by RedSnappa »

I looked in Q3 Shader Manual and it answered questions 1-4. I still have no idea about questions 5 and 6.

Creating an alpha channel and using your first shader didn't work. Now I will try the image without alpha channel and use your second shader and see if that works.
[LCDLC]Snappa
LCDLC Mapmaking Dept.
Maps finished: Hellhouse, Sorry, Worrior 1-20
Maps modded: CubeOrigin
Maps in release candidate: Blockforts, Cannons 1, Hotzone, Icecastle
Maps in beta: Arctica, Cannons 2, Cerulean-River, Igloo, Skygarden, Spacestation
Maps in alpha: Merlin, Totem

User avatar
Delirium
Posts: 366
Joined: Sat Aug 27, 2011 8:37 am
Location: Auckland, New Zealand

Re: Transparent water

Post by Delirium »

If the extention is .tga it will look for a tga first then a jpg but if the extention is .jpg it will only look for a .jpg
Image

RedSnappa
Posts: 323
Joined: Sun Aug 21, 2011 12:10 pm
Location: North Carolina (USA)

Re: Transparent water

Post by RedSnappa »

I just tried your second shader. It wasn't successful. Solid looking water was the result.

Your first one gave me some transparency, but not much. I want water as transparent as what is found in ramelle or edo. I try copying those shaders and they won't work.
[LCDLC]Snappa
LCDLC Mapmaking Dept.
Maps finished: Hellhouse, Sorry, Worrior 1-20
Maps modded: CubeOrigin
Maps in release candidate: Blockforts, Cannons 1, Hotzone, Icecastle
Maps in beta: Arctica, Cannons 2, Cerulean-River, Igloo, Skygarden, Spacestation
Maps in alpha: Merlin, Totem

RedSnappa
Posts: 323
Joined: Sun Aug 21, 2011 12:10 pm
Location: North Carolina (USA)

Re: Transparent water

Post by RedSnappa »

I used this shader:

Code: Select all

textures/greatwall/water
{
   qer_editorimage textures/greatwall/water.jpg
   qer_trans 0.5
   q3map_globaltexture
   surfaceparm trans
   surfaceparm nonsolid
   surfaceparm water
   cull disable
   tessSize 32
   deformVertexes wave 32 sin 0 1 0 0.25
   {
      map textures/greatwall/pmarron.tga
      blendFunc GL_dst_color GL_one
      rgbgen identity
   }
   {
      map textures/greatwall/agua4.jpg
      blendFunc GL_dst_color GL_one
      rgbgen identity
      tcmod rotate -5
   }
   {
      map textures/greatwall/agua3.jpg
      blendFunc GL_dst_color GL_one
      rgbgen identity
      tcmod rotate 5
   }
}

and it worked! Now I just have to see if I can sub in my textures for the ones in edo. I notice for some reason that .jpg textures seem to be working for this while .tga textures are not. I'm not sure why.
[LCDLC]Snappa
LCDLC Mapmaking Dept.
Maps finished: Hellhouse, Sorry, Worrior 1-20
Maps modded: CubeOrigin
Maps in release candidate: Blockforts, Cannons 1, Hotzone, Icecastle
Maps in beta: Arctica, Cannons 2, Cerulean-River, Igloo, Skygarden, Spacestation
Maps in alpha: Merlin, Totem

Post Reply