I made a typo and wrote 'variable.t' instead of 'variable.z' (on a qwertz keyboard that is... i'm not that bad of a writer ) and was baffled that this isn't an error as I'm only aware of the '.rgba' and '.xyzw' indices. That made me curious and it seems like '.stp' is the same as '.rgb' and it is also possible to use '.q'. Is there some meaning to this or is it just some leftover from writing the new compiler?
Correct. There are three types of swizzle sets which can be used in different scenarios to make it cleaner what your swizzle accomplishes:
xyzw = geometry vectors
rgba = colors
stpq = texture coordinates
They are just syntactic sugar of course, so you don't have to use them for rhese purposes (it is common that xyzw is used for almost everything).
Cheers, crosire =)
The administrator has disabled public write access.