Two problems: skyfactory and water

Okay Ive tried searching everywhere for help on this problem, and I can’t any problem like mine.

So here it is:

The skyfactory warps the pictures I give it. Ive given it all kinds of pictures of all types and sizes and it does the same thing to all of them. In the picture Im posting, you can kind of see what I mean, but it makes the sky look like an inflated balloon. pointed at one end and flat at the other.

The water also makes strange reflections. It puts a black dot everywhere. I had the game print out everything thats on the node that it casts reflections from and its just:

“Tomcat-objnode (Node) Sky (Geometry) terrain (TerrainQuad) water (Geometry)” Nothing unusual. The Tomcat is the plane btw.

Can I please get any help?


Is this SimpleWater or the WaterFilter?

A test case would be helpful.

nehon said:

Is this SimpleWater or the WaterFilter?

A test case would be helpful.

Not sure exactly how to make a test case for you :/ I did my best.
its SimpleWater. Check it out:

public void simpleInitApp()

jet = assetManager.loadModel("Models/Tomcat.j3o");

jet.scale( .05f, .05f, .05f );
jet.setLocalTranslation(0f, 250f, 0f);
Node mainScene = new Node();



private void createLight(Node mainScene)
assetManager, "Textures/Sky/hemispherical.png", true));
DirectionalLight dl = new DirectionalLight();
dl.setDirection(new Vector3f(-0.1f, -0.7f, -1).normalizeLocal());
dl.setColor(new ColorRGBA(1f, 1f, 1f, 1.0f));
private void initWater(Node mainScene)

SimpleWaterProcessor waterProcessor = new SimpleWaterProcessor(assetManager);

Vector3f waterLocation=new Vector3f(20,40,0);
waterProcessor.setPlane(new Plane(Vector3f.UNIT_Y,;

waterProcessor.setWaterDepth(30); // transparency of water
waterProcessor.setDistortionScale(0.06f); // strength of waves
waterProcessor.setWaveSpeed(0.01f);// speed of waves
Quad quad = new Quad(40000,40000);
quad.scaleTextureCoordinates(new Vector2f(6f,6f));

Geometry water=new Geometry("water", quad);
water.setLocalRotation(new Quaternion().fromAngleAxis(-FastMath.HALF_PI, Vector3f.UNIT_X));
water.setLocalTranslation(-4000, 38, 4000);


private void createTerrain(Node mainScene) {
matRock = new Material(assetManager, "Common/MatDefs/Terrain/Terrain.j3md");
matRock.setTexture("m_Alpha", assetManager.loadTexture("Textures/Terrain/colors2.png"));
Texture heightMapImage = assetManager.loadTexture("Textures/Terrain/terrainmap.png");
Texture grass = assetManager.loadTexture("Textures/Terrain/splat/grass.jpg");
matRock.setTexture("m_Tex1", grass);
matRock.setFloat("m_Tex1Scale", 64f);
Texture dirt = assetManager.loadTexture("Textures/Terrain/splat/dirtv1.jpg");
matRock.setTexture("m_Tex2", dirt);
matRock.setFloat("m_Tex2Scale", 32f);
Texture rock = assetManager.loadTexture("Textures/Terrain/splat/pavement.jpg");
matRock.setTexture("m_Tex3", rock);
matRock.setFloat("m_Tex3Scale", 128f);
AbstractHeightMap heightmap = null;
try {
heightmap = new ImageBasedHeightMap(ImageToAwt.convert(heightMapImage.getImage(), false, true, 0), 0.25f);
} catch (Exception e) {
terrain = new TerrainQuad("terrain", 80, 513, heightmap.getHeightMap());
List cameras = new ArrayList();
TerrainLodControl control = new TerrainLodControl(terrain, cameras);
terrain.setModelBound(new BoundingBox());

terrain.setLocalScale(new Vector3f(6, 5, 6));



thanks i’ll look into it asap

thanks. Im quite a noob at this, so any advice or help you could give me would be very helpful

Okay, I got the water reflections to work properly. I just assigned everything to a new node, then added it to the rootnode.

Still can’t figure out the sky warp. I’ve tried all kinds of pictures and none of them work…

oh sorry i forgot to answer.

I didn’t manage to run your test since it uses a lot of unprovided assets.

maybe a test case with JME assets or a zip of your assets could help

hmmm… not sure how to upload a zip here… :frowning:

Let me at least link you to the sky picture I used. That way you can at least see what its doing.

were you able to test it? :confused:

Thats the point, if you make a testcase (read the description by hovering the mouse over the word “testcase”) you can post it just as code in code tags here.

@randomrocket it’s not to annoy you really, we have a lot of requests like yours, and we spend a lot of time on them. We can’t spend more time to make the test cases work.

So if you provide a working testcase that demonstrate the issue, we will gain some time, and you’ll have your answer faster.

If you think the sky image is the issue why don’t you test with the sky images provided with the test case, this could help to track the issue.