Texture alignment…

Published on

in

If you build a lot you will found almost impossible to align those damn textures when you resize or move your pieces.
Surely you can try offset and repeats per face parameters, but how to do that in a “safe” and exact way?

So I rezzed up a 10x10x.5 box and tried to get the magical numbers you must use when aligning textures.

I call SizeX the size on X and ShrinkX the coefficient of shrinking on X, so that .1 means you shrinked th box on the X axis to be 1 m only.

So almost obviously the RepeatPerFace x must be multiplied by ShrinkX.

OffsetX depends on where you moved you piece, but if you want to put at the higher X you should apply the following formula:

OffsetX=( 1 – ShrinkX) / 2

For example:

if you shrinkX by .1, you have to
– offsetX add .45
– changeX by .45*LX=4.5

If you have a strange size box, say 3.5 x 3.5 and you want to put it to 3 x 3.5, than shrinkX is
3 / 3.5 = .857,

offset will be (1-.857)/2=.0715

and changeX will be .715*3.5=.250

🙂

NB: if instead of aligning the box exactly to other boxes you are further offsetting of a small amount, you just have to offset the textures of the further/originalsize so that it will fully aligned.

Leave a comment


Benvenuto su Salahzar.com

Qui trovi analisi critiche sull’intelligenza artificiale e le sue implicazioni sociali, scritte da chi viene da una impostazione umanistica e ha passato vent’anni a costruire mondi virtuali prima che diventassero “metaverso”.

Niente hype da Silicon Valley o entusiasmi acritici: sul tavolo ci sono le contraddizioni dell’innovazione tecnologica, i suoi miti fondativi, le narrazioni che usiamo per darle senso. Dai diari ucronici (storie alternative come strumento per capire i nostri bias cognitivi) alle newsletter settimanali sugli sviluppi dell’AI che richiedono aggiornamenti continui perché i trimestri sono già preistoria.

Se cerchi guide su come “fare soldi con ChatGPT” o liste di prompt miracolosi, sei nel posto sbagliato. Se invece ti interessa capire cosa sta succedendo davvero – tra hype, opportunità concrete e derive distopiche – sei nel posto giusto.

Umanesimo digitale senza retorica, analisi senza paternalismi, ironia senza cinismo.


Join the Club

Stay updated with our latest tips and other news by joining our newsletter.