Hi all,
I have one texture(.png) and one model, in the model has many faces, but i want set only one texture in all front side the model.
Basically I would like to have the image(texture) of the same form of the model.
When i use the code below, the texture is in the center and small. I'm attaching the files for more details.
TextureState ts = display.getRenderer().createTextureState();
ts.setEnabled(true);
Texture loadTexture = TextureManager.loadTexture(JmeSimpleLite.class
.getResource("/").getPath()
+ "Data/pieces/texture01.png",
Texture.MinificationFilter.BilinearNoMipMaps,
Texture.MagnificationFilter.Bilinear);
loadTexture.setWrap(Texture.WrapMode.BorderClamp);
loadTexture.setApply(Texture.ApplyMode.Decal);
loadTexture.setEnvironmentalMapMode(EnvironmentalMapMode.EyeLinear);
ts.setTexture(loadTexture);
I have tried many options of the EnvironmentalMapMode, Wrap and ApplyMode, but no success.
I hope someone help me. Thanks.