How to use the new features of q3map2


(Maggumaster) #1

Hi@all,
I´v tried the new feature of the q3map2, that allowes improved vertex colors, but i can´t make it work. Btw, I´m the guy with that simpsons map, so i really need these colors :smiley:
My Colorshaders look like this right now:

textures/simpsons/couch
{
qer_editorimage textures/simpsonscolors/couch.jpg

{
map $lightmap
rgbGen identity

}
{
map $whiteimage
blendFunc GL_DST_COLOR GL_ZERO
rgbGen const ( 0.63137254901961 0.68235294117647 0.74901960784314 )
}
}

The new feature of the q3map2 should make these colorshaders more effective and faster. In ydnars small manual how to use the features, it sais you have to use this whiteshader to remap the colors:

textures/rgbmod/white
{
q3map_noVertexLight // leaves vertex rgb alone
{
map $lightmap
rgbGen indentity
}
{
map textures/rgbmod/white
blendFunc GL_DST_COLOR GL_ZERO
rgbGen vertex
}
}

As exampletextures he gives a blue, a red, a green and a yellow texture. Like this for example:

textures/rgbmod/green
{
q3map_rgbGen set ( 0 1 0 )
q3map_remapShader textures/rgbmod/white
}

Well, I´ve tried this exampletextures, but they don´t work somehow…
Could someone post his experiences with the new q3map2 features? If someone could also tell me how this “textures/simpsons/couch” texture would have to look like with the new feature, that would be great.

greetz
Maggumaster


(ydnar) #2

textures/simpsons/generic_white
{
	q3map_noVertexLight
	{
		map $lightmap
		rgbGen identity
	}
	{
		map $whiteimage
		rgbGen exactVertex
		blendFunc GL_DST_COLOR GL_ZERO
	}
}

textures/simpsons/couch
{
	qer_editorimage textures/simpsonscolors/couch.tga
	q3map_rgbGen const ( 0.63137254901961 0.68235294117647 0.74901960784314 )
	q3map_remapShader textures/simpsons/generic_white
}

textures/simpsons/red
{
	qer_editorimage textures/simpsonscolors/red.tga
	q3map_rgbGen const ( 1 0 0 )
	q3map_remapShader textures/simpsons/generic_white
}


(Maggumaster) #3

Great, this time it worked. Thank you very very much for this feature ydnar. I will impliment it into the map now.

Greetz
Maggumaster


(Maggumaster) #4

I converted the colorshaders, but now i have a new problem. Watch this:

Looks like the shaders don´t work correctly. I don´t know what´s wrong. The shaders don´t have the right colors. They are simply too sharp, i guess. Here´s the shader for the couchcolor:

textures/simpsons/couch3
{
qer_editorimage textures/simpsonscolors/couch3.jpg
q3map_remapShader textures/simpsons/generic_white
q3map_rgbGen const ( 0.44705882352941 0.062745098039216 0.058823529411765 )
}

and here´s the generic_white:

textures/simpsons/generic_white
{
q3map_noVertexLight
{
map $lightmap
rgbGen identity
}
{
map $whiteimage
rgbGen exactVertex
blendFunc GL_DST_COLOR GL_ZERO
}
}

Any ideas?

greetz
Maggumaster


(ydnar) #5

Try using rgbGen vertex instead of rgbGen exactVertex.

y


(Maggumaster) #6

sorry, still got the same problem. I compiled with this shader:

textures/simpsons/generic_white
{
q3map_noVertexLight
{
map $lightmap
rgbGen identity
}
{
map $whiteimage
rgbGen Vertex
blendFunc GL_DST_COLOR GL_ZERO
}
}

You see, i used rgbGen vertex…


(ydnar) #7

In the console, set /r_mapoverbrightbits 0 and vid_restart. See if that corrects the color issues.

y


(Maggumaster) #8

ok, this helped. But now, the map is too dark:

The colors on the asemodels have a problem, too. They have no lightmap:

greetz
Maggumaster


(ydnar) #9

Okay. Try dividing the colors by 4. So where you have this:

q3map_rgbGen const ( 0.44705882352941 0.062745098039216 0.058823529411765 )

Have this:

q3map_rgbGen const ( 0.1117 0.0157 0.0147 )

And recompile.

y


(Maggumaster) #10

strange, i compiled now with the new scripts, but nothing has changed… really nothing. Maybe the compile had an error. I´ll try it again.


(Maggumaster) #11

cool, i´ve compiled again and this time it worked! I looked into the log from the last compile, and there was an error. Solved it, and now it works. A very big thank you to to ydnar. great support g.

greetz
Maggumaster


(Maggumaster) #12

just one more thing, the colors on the asemodels have still no lightmap, as you can see on screenshot 2, 4 posts ago. They look like they´re surrounded by lightsources, so they have no dark sides… is there a chance to solve this, too?

greetz
Maggumaster


(ydnar) #13

That technique won’t work for ASE models with vertex-lit shaders. So either add q3map_forceMeta, or use normal textures/shaders for the models.

y