High resolution texture.

Started by icarusfactor, January 25, 2011, 06:41:21 PM

Previous topic - Next topic

icarusfactor

I was trying to use larger than 256x256 textures on a plane. I normally use gimp to do my graphics which is only 8bpp I use ImageMagick to convert it to 24bpp. but , still just gets scaled down to the 256^2. How do I get a high resolution texture on a single plane.

Can I :
use multiple 256^2 textures on a single plane(face)?
use multiple planes with 256^2 images on each to piece together into a seamless single image. 
have a process or function to automatically format a hi res image to one that is compliant with JPCT
    and remain hi res?

Thomas.

#1
I used 1024x1024 texture for dome (sky) and for all other objects 512x512 withou any problems... if you think tile texture this can help

EgonOlsen

#2
As long as your texture's width and height are both power of 2, there is no limit other than what the hardware permits....and that's for sure more than 256. Do you get any log message regarding the size when loading the texture?

Edit: And make sure not to load your textures from the drawable folder. Some Android versions rescale those images on loading whenever they think that it's a smart idea (which it isn't in this case).

icarusfactor

Thanks everyone , it works now. It was clear as day, but just learning the java /android stuff and was using an example snippet. It was actually scaling down my image to 64x64. Should have known by the name of the function "rescale" what it was doing, just thinking it may have been a limitation of the 3d textures which so far seems to just be the powers of 2 one which is fine. It looks great in 1024x1024 now :)


Texture periodic_table = new Texture( BitmapHelper.rescale(BitmapHelper.convert(getResources().getDrawable(R.drawable.periodictable)), 64, 64)  );