Texture get blur when far away [also disappear] !!!!

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
pandaben7890
Posts: 12
Joined: Mon Nov 23, 2009 3:36 pm

Texture get blur when far away [also disappear] !!!!

Post by pandaben7890 »

I don't know what happened to my program?

Texture get blur or disappear - -

- I use EDT_DIRECT3d9 with 32 bits and 1024*768
- videoDriver->beginScene(true,true,video::SColor(255,150,150,255));
- My Texture is 2048 * 2048 (so it has nothing to do with power of 2 texture)
- My black line is cube node from irrlicht with 64*64 black texture
- I use node->setMaterialTexture
- I tried using EMF_ANTI_ALIASING but nothing happened
- I already use EMF_NORMALIZE
- I use directional Light, so it's as you see everything is all bright

--- I have the same problem with my last program also but this time i can't stand this anymore TT

--------- Help me Plz TT -----------

What i have to do if i want them to be more clear.
and I want my black line to be more straight - -

Ps. Sorry for my bad English TT

Image
Last edited by pandaben7890 on Fri Jan 01, 2010 8:02 pm, edited 1 time in total.
sRc
Posts: 431
Joined: Thu Jul 28, 2005 1:44 am
Location: Salt Lake City, Utah
Contact:

Post by sRc »

are the black lines on that same texture? it just looks like some bad rolls with the mipmapping to me
The Bard sRc

Blog | Twitter
pandaben7890
Posts: 12
Joined: Mon Nov 23, 2009 3:36 pm

Post by pandaben7890 »

black lines use the same texture.
But if I use 64*64 and it's all black why you said it's about mipmapping ?
pandaben7890
Posts: 12
Joined: Mon Nov 23, 2009 3:36 pm

Post by pandaben7890 »

I use EMF_ANISOTROPIC_FILTER now so the ground is now acceptable with less blur now.

But black lines still not straight and they don't have the same thickness.
bitplane
Admin
Posts: 3204
Joined: Mon Mar 28, 2005 3:45 am
Location: England
Contact:

Post by bitplane »

If the black lines are polygons then you need to enable antialiasing (device creation parameters) to smooth the edges.
The reason why parts of them vanish at a distance is because you're drawing them too close to the ground, your z-buffer does not have enough resolution.
Either raise them up a bit so they are away from the ground, adjust your near and far plane to increase z-buffer resolution, or set up a custom render loop where they are always rendered directly after the ground but with SMaterial.ZBuffer = ECFN_ALWAYS
Submit bugs/patches to the tracker!
Need help right now? Visit the chat room
Post Reply