Page 1 of 1

Gui images looks ugly. Why?

Posted: Thu Dec 29, 2005 12:36 pm
by LarryTM
Why gui images looks so ugly ? (like after resizing and smoothing)? My background image size is 828x628 and i display it without resizing. How to disable smoothing / filtering?

Here is my code ->

Code: Select all

edit_tlo=driver->getTexture("images/gui/main/background.png");	
    desg_window=env->addImage( core::rect<s32>( 0, 0, 828, 628 ), 0, 0, 0 ); 
    desg_window->setImage(edit_tlo); 

Posted: Thu Dec 29, 2005 1:26 pm
by AshmenGlue
You should search the forums more carefully. I posted a thread exactly on this topic not long ago. If you're using DirectX or OpenGL as your renderer your image size has to be something to the power of 2.

For example:

64 x 32
128 x128
512x1024

Posted: Fri Dec 30, 2005 9:49 am
by bearSoft
to avoid confusions : not 'power of 2'
u need 2^n for all textures, -except- maps for heightfields! They need to be 2^n+1