Zaslat SMS: Theory of textile structure