Texture with type Texture2D doesn't match definition types TextureCubeMap

[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

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.

Well, 256x512 is a power of two… but it’s not square.

Does android require it to be square, too?

uh true :stuck_out_tongue:
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