Rotate texture on spatial

hi all

i’d like to rotate the image texture on spatial but not the spatial is it possible?

You mean animate the rotation of the texture or just rotate it once and for all?

if it’s once and for all rotate it in an image editor.

if it’s animation you’ll have to rotate texture coordinates.

So you have two options :

  1. Doing it on the mesh level, by directly rotating the coords in the textureCoord buffer, wich i don’t recommend
  2. Doing it at render by using a custom shader.

is there any example? in the tutorial ?

Not that I know of.

I know there are some thread on the subject on the forum though

look at this http://hub.jmonkeyengine.org/groups/graphics/forum/topic/how-to-animate-textures-in-jme3/#post-108786

@tehflah made a scrolling texture shader, maybe you can start from there