ASE models uv-mapping is fucked up


(burzum) #1

In 3dsmax and gtkradiant the texturemapping is ok but not ingame - why ? :frowning:
Oh, and it does not clip.

Heres my testshader :


textures/burzum/sandy_rock
{
qer_editorimage textures/burzum/adobe1c.jpg

	q3map_lightmapsampleoffset 4.0
	q3map_tcGen ivector ( 384 0 0 ) ( 0 384 0 )
	{
		map textures/burzum/adobe1c.jpg
	}
	{
		map $lightmap
		blendFunc GL_DST_COLOR GL_ZERO
		tcGen lightmap
	}
}

[/quote]


(rgoer) #2

needs q3map_nonplanar and q3map_forcemeta


(ydnar) #3

textures/burzum/sandy_rock
{
	qer_editorimage textures/burzum/adobe1c.tga
	
	q3map_nonplanar
	q3map_shadeAngle 120
	q3map_clipModel
	q3map_lightmapSampleOffset 4.0
	
	{
		map $lightmap
	}
	{
		map textures/burzum/adobe1c.tga
		blendFunc GL_DST_COLOR GL_ZERO
	}
}

Note I nuked q3map_tcGen. That was what was borking your texture coordinates.

y


(obsidian) #4

q3map_tcGen causes your model to be planar mapped along a single axis. Setting it makes it override your UVW-coordinates.

Models do not clip by default. You can set spawnflags 2 on your misc_model entity to toggle on autoclipping. However, in your case, it’s probably better to just manually clip that model.


(burzum) #5

Ok, thanks for your help !
But i still get no lightmapping or has the wrong color but its the same texture i use for the brushrocks :???:

And the texture on the car model disappeard since the last compile, dont know why.

http://www.doomzone.de/shot0038.jpg


(Gringo Starr) #6

Is that bumpmapped, or would I see that in the shader? That is a wickedly clear looking texture.


(RabidCow) #7

try adding spawnflags 6 to the entity. That wil both autoclip and lightmap the model.
RC


(ydnar) #8

Ah, crap. I forgot this one line in your shader:

q3map_forceMeta

y


(ratty redemption) #9

if we compile with -meta then do we also need q3map_forceMeta in our shaders? just curious.


(ydnar) #10

Yep. q3map_forceMeta forces a model to be split up into the meta triangles process.

y