tiling mirroring and rotating. addition to surface mapping, part 2

Next thing we could consider is having our source texture (which now is all rotated and nicely distributed along
our wall or whatever surface) flipped or mirrored in each triangle. here I guess I should add an image to show what I mean.


orientation. flipping mirroring and so on...
orientation. flipping mirroring and so on...

So if u see 1 image shows our source texture, second one is nice hexagon, which we created by rotating our source texture.
now third one is more complex. as second one we get its shape and structure by rotating original source texture, but in addition
to that we mirror, flip, and rotate the source texture after it is already in its correct position. meaning, only after we rotate it.
well, again, hard to explain here using words, just have a closer look at third image and try to imagine what actions must be taken in order to get this
result using only source image.
Ok, so lets imagine our new tool is already capable of achieving what we described above. why to stop, lets add some more cool stuff.
next thing would be more textures. in this case we used one source texture and we created triangle out of it, then we rotated and copied it, and we have
all our imaginary surface nicely covered.
now we see that all elements of our surface, meaning original texture is same everywhere. it is rotated, flipped, mirrored, but essentially it
is same texture, and we don’t need lots of time to spot that. fells so unreal right?
so imagine now we have set of original textures. they are same in shape (image in bitmap forms same triangles) presumably also image is same,
but with slightly different coloring, or some of source textures have some cracks, some dirt or might be they are just made out of different glass,
therefore they reflect light in different way, or might be some of them has mirrors where the color is in others.

hexagon. with same..or different triangles wich form it?
hexagon. with same..or different triangles wich form it?

So we need an ability to have different source textures used in our final image generation. it might be random (for forming cracks) or very precise and
deliberate (say for constructing other patterns with different materials, while preserving original image)
Now interface for this is still quite a question. any input?
After we implement such an option to our generator, next logical step would be context awareness. what I mean by that. well we sed that
possibly we want cracks or dirt. and we achieve that by randomly adding some individual tiles which have some dirt applied in source image.
next step would be that our generator would recognise the world. it should assume rain direction (from up towards down along z coordinate with some random directional shifts)
And this is all because we see that dirt does not appear on a walls in totally random places we can distinguish areas where we will have more of it.
that would be where wall reaches ground, for one. also all sorts of dirty water forms nice patterns beneath windows. And so on. so I will discuss
something very similar in next post. (can’t link to it before I actually wrote next post, can I :) )

more coming in part 3, very soon :)

tiling mirroring and rotating. addition to surface mapping, part 1

Oh, i have a blog? seems I forgot it for a while :)  So some ideas on textures.

We use different textures for creating all kinds of materials for our 3D models.
In some cases we use tiling and mirroring for different ways to apply textures on existing 3D objects with uv coordinates.
But in some cases we use textures in architectural situations where we have, say, couple of tiles to cover whole wall. while having a nice texture of say one tile by tilling and mirroring we can,
make it cover whole wall.  To achieve some more variable results we use brick procedural map generator (in 3D max) which basically helps us to put our
tile image in more variable fashion.
But if you ever looked at islamic art and architectural tradition, you will see that some parts of ornaments and tilling can blow your mind with its complexity.

Here I add some articles, which are very interesting regarding this topick.

Geometry feat cloaked in medieval Islamic tile,
“Cintamani” and Islamic Tiles,
A Discovery in Architecture: 15th Century Islamic Architecture Presages 20th Century Mathematics,
Q1 Project – Islamic Tiles,
The Art of Mathematics Islamic patterns,
Sometimes you would look at the wall but fail to see contours of single pattern which is repeated.
tower decoration pattern

To some extent same can be said about baroque wallpapers in Europe. And probably in any culture and time period you could find very complicated pattern arrangements.

Vintage Wallpaper

So while analysing couple of arabic patterns I thought why do i have to spend hours tilling and mirroring and rotating stuff in Photoshop, if it theoretically
could be done directly in material editor.
Many patterns have a basic triangle shape. So if we have correct texture which contains our desired basic pattern element in triangle shape, we could
instead of tilling or mirroring it rotate it. Sins all bitmaps, as far as i know, are rectangle in shape, we would need to find and identify our triangle element wich we
would use for rotation. technically I guess we could develop a type of bitmap which is a triangle in its shape. I guess its resolution would be defined not as
say 640×480 but i don’t know, 1 pixel at top row, 640 at bottom row, 480 pixels height or something like that.
But we will try to work with traditional bitmaps here.  So say we open a texture in our brand new material editor. then we should define a triangle in
one or another way. i guess our material editor should let draw a triangle on top of texture, something like guidelines in Photoshop. We would
make sure these guidelines matches our triangle shape in bitmap as close as possible. next step would be to chuse which corner of triangle is our pivot point,
or in other words where will be its rotation centre.
rotation of images
according to angles of our triangle new material editor should copy and rotate texture in a number of times which is closest to full circle.
(say our pivot point of triangle is 45 degrees, therefore material editor would copy/rotate our original image exactly 8 times, if i am still able to count :) )

So next thing, after we have nice circle with texture which repeats itself not by tiling or mirroring but by rotation, we would need to describe how to make many such
circles to cover our full wall with new pattern.
Here I discovered there are 3 types of triangles. perfect ones, good ones and bad ones.
perfect triangle is the one wich has 60 degrees angle in each corner (picture bee hive)
good one is when the degree of its pivotal angle is such number that after dividing 360 from that number u get something like: 1,2,3,4,5 .. 25…5356544444 – a whole number,
and not 5.22321445524… and this is also a description of bad triangle. what i mean is that the number to form a full circle should be always a whole number.

hexagon is formed out of 6 tryangles which have 60 degrees corners
hexagon is formed out of 6 tryangles

anyways. so a triangle with 60 degrees corners can cover any surface. all other “good”triangles also cover whole surface, but with some gaps between themselves.

good and bad triangles
good and bad triangles

this is also ok. but we should have an option to export this “gap”to a bitmap file, so user could draw what he or she wants there in Photoshop, and import
it back to our map generator. so basically if we use any other than 60 degree triangle, we need two textures, not one, to form our surface.

more, coming soon.