Stefano wrote:
> 2007/5/7, Marcus Lindblom <[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>>:
> 
>     Hm. Maybe filtering doesn't work for depth data? (It can happen, depth
>     is a bit tricky to texture with) Try to test if you get at least
>     bilinear filtering.
> 
> 
> Don't know if I'm saying something stupid, but I'm pretty sure that 
> mipmapping works as it should.. using the following fragment shader I 
> can see my depth buffer "blurred" as it should be if mipmaps worked:

Mipmapping works. What might not work is filtering between mipmap 
levels. There is a difference. (i.e you're getting 
nearest_mipmap_nearest even if you are saying linear_mipmap_linear)

> void main(void) {
>   vec4 dd = texture2D(depth, gl_TexCoord[0].xy, 4.0); // <<-- bias=4.0!
>   gl_FragColor = dd;
> }

Test some values to see if you are getting discrete steps, or simply set 
nearest_mipmap_nearest and see if it yields equivalent results.

> I guess my problem lies where I grab the depth texture. It seems I take 
> a texture format with too little bits... It's setted correctly, isn't it?

If your texture is depth_component_24 it ought to work just fine.

What card are you using btw? (Don't know if you've said that before) I 
_know_ some cards don't filter depth component textures at all. (The 
GF7800 doesn't, for instance.)

Cheers,
/Marcus

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to