How to get the texture's tiling and offset variables?


(Madalin Berechet) #1

I am using setMatrix() to scale a MatrixTransform node. To get the matrix transformation I am using glmatrix mat4.fromScaling(outmatrix, scalevector).
How can I control UV tiling to correctly display the scaled node?

I tried updating the material by setMaterial(), even create and assign a new material after scale operation. I get no results.

The textures are wrapped as REPEAT. https://help.sketchfab.com/hc/en-us/articles/202600873-Materials-and-Textures#textures-uv-channels-offset

All attempts are commented here: http://estudio3d.eu/matrixop/

Thanks.


(Klaasnienhuis) #2

I don't think you can control UV's through the API. Though this would be very useful @james!
You can however upload the model with multiple UV's and pick the best fitting channel as you scale your model.


(Madalin Berechet) #3

Multiple UV's It's a great idea, as long I'm interested in scaling only on the X axis. Thank you. At least it is a good temporary solution.


(Mauricesvay) #4

Hi @MadalinBerechet,

we don't support UV Tiling at the moment. I've added a +1 for you in our feature request tracker.


(Madalin Berechet) #5

Thanks Maurice.