[java]
SkyFactory.createSky( assetManager, pTexture, true )
[/java]
When running on PC it’s ok, but when run it on Android:
WARNING Material parameter being set: Texture with type Texture2D doesn't match definition types TextureCubeMap
How to create Sky using SkyFactory and what i did wrong ?
Why was nowhere written that the texture should be multiples of 2!
When i changed resolution from 256x512 to 256x256 it worked
nehon
January 3, 2014, 8:27am
3
JME resizes the image on android so it match a power of 2 (not multiple btw).
I guess it doesn’t with cube maps though, hence your error.
pspeed
January 3, 2014, 11:56am
4
Well, 256x512 is a power of two… but it’s not square.
Does android require it to be square, too?
nehon
January 3, 2014, 12:15pm
5
uh true
It shouldn’t…maybe on some device…
1 Like
my phone is Sony Xperia L Android 4.2.2, updated yesterday
I dont think changing the resolution and the original error are related.
Due to some internal changes to the material system, the “sphereMap” parameter in SkyFactory is now broke … It probably should be deleted entirely since sphere maps are ugly and totally useless for skies. Cubemaps are the way to go.
1 Like
i already using SkyBox, it’s a lot easier, but it’s take a bit more memory for textures, but it’s fine though