Code: Select all
textures/central_europe/jh_gtwindow1
{
qer_keyword window
qer_keyword glass
surfaceparm trans
nopicmip
cull none
{
map textures/central_europe/jh_gtwindow1.tga
blendfunc blend
depthWrite
nextbundle
map $lightmap
}
}
textures/central_europe/jh_gtwindow1
{
qer_keyword window
qer_keyword glass
surfaceparm trans
surfaceparm glass
nopicmip
cull none
{
map textures/central_europe/jh_gtwindow1.tga
blendfunc blend
depthWrite
nextbundle
map $lightmap
}
}When I duplicate this process and compile my window panes are filled with white. In the editor the panes do not look frosted there either. When I apply the texture I can see through the panes as if they were clear, just like when you apply the jh_gtwindow1 texture. However its editor image shows the frosted glass look. Mine has funny geometric shapes inside the panes which are white in color. How did they accomplish this frosted glass look for both in the editor and when it is compiled? The statement nextbundle in the shaders must have something to do with this. I have read extensively on the q3map shaders. It says that nextbundle statement is used for multiple images or to include the next image. The next image shader statement after the second jh_gtwindow1 statement is:
Code: Select all
textures/central_europe/earth_road_gen1bend
{
qer_keyword terrain
qer_keyword road
qer_keyword dirt
qer_keyword gravel
surfaceparm dirt
{
clampmap textures/central_europe/earth_road_gen1bend.tga
depthWrite
rgbGen identity
}
{
map $lightmap
rgbGen identity
blendFunc GL_DST_COLOR GL_ZERO
depthFunc equal
}
}My image is tga 32bit. It's nearly exact like the gtwindow.tga image, just a different pattern on the panes. I selected all the areas where the panes would be and chose 'save selection'. Named it layer 0 transparency.
Something else I noticed. When I opened the jh_gtwindow1.tga and loaded the selection, the areas selected are not the panes but the inverse of that. All the wood areas of the window were selected. I tried that too for mine and still looks the same, clear in the editor but when compiled the panes become solid white.
Can anyone help me out here?
By the way a great source of information for shaders besides the q3map shader handbook is this place:
http://www.ritualistic.com/games/ef2/gd ... anual.html
It tells you what nextbundle means. Q3map shader handbook speaks nothing of this statement.
This is what that page says about nextbundle:
Code: Select all
5.10 nextbundle
Used to define the next texture in a multi-texture operation. A map command should immediately follow this command. Any stage commands may follow except for blendFunc.
Example 16.: An example of a multi-texture shader
textures/techdemo/mtexwater1
{
cull none
surfaceparm nolightmap
surfaceparm trans
surfaceparm water
qer_editorimage textures/liquids/blue_water1.tga
qer_trans 0.500000
{
map $whiteimage
blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA
alphaGen oneMinusDot
rgbGen constant 0.000000 0.250000 0.750000
}
if mtex
{
map textures/liquids/blue_water1a.tga
blendFunc GL_ONE GL_ONE
tcMod scale 0.330000 0.330000
tcMod turb 0.000000 0.200000 0.000000 0.100000
nextbundle
map textures/liquids/blue_water1b.tga
tcMod scale 0.660000 0.660000
tcMod scroll -0.050000 -0.030000
}
endif
{
map textures/liquids/blue_water1a.tga
blendFunc GL_SRC_ALPHA GL_ONE
alphaGen lightingSpecular
tcMod scroll 0.070000 -0.040000
}
}
Design Note: Currently OpenGL multi-texture only allows for the textures involved in the operation to be multiplied together. This is what will happen to the 2 textures before they are placed into the frame buffer with blendFunc.
Any help here appreciated,
G3mInI

