Author Topic: TextureInfo multi-texture question  (Read 1707 times)

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11777
    • View Profile
    • http://www.jpct.net
Re: TextureInfo multi-texture question
« Reply #15 on: April 12, 2016, 07:43:59 am »
I know what you mean. IIRC, I've already changed that behaviour in the latest beta: http://jpct.de/download/beta/jpct_ae.jar.

Offline AeroShark333

  • long
  • ***
  • Posts: 152
    • View Profile
Re: TextureInfo multi-texture question
« Reply #16 on: May 29, 2016, 08:39:44 pm »
Is it possible to shift the pixels in a texture like in the picture in the attachments?
It would be nice if there was some way to 'rotate' the texture in the horizontal direction. (rotate -> imagine the texture in a cylinder-shape)
So basically I'd need something like Texture.rotateHorizontally(float angle); [angle of the pixelshift in the right direction -> imagine the cylinder-shape with the texture applied to it again)
So yeah, if it was a cylinder, I could just rotate the cylinder object itself... using Object3D.rotateY(float angle);
But that's a bit different in my case... Imagine the cylinder having two texture layers. I'd like one texture to rotate with the object (so with Object3D.rotateY(float angle);) but I want the second texture to rotate at another angle.
I hope my explanation was clear enough :p

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11777
    • View Profile
    • http://www.jpct.net
Re: TextureInfo multi-texture question
« Reply #17 on: May 30, 2016, 09:25:12 am »
You can set a texture matrix: http://www.jpct.net/jpct-ae/doc/com/threed/jpct/Object3D.html#setTextureMatrix(com.threed.jpct.Matrix)

If you are using your own, custom shaders, they have to support it though.