Saturday, September 13, 2014

Tileland+ code

Tileland+ interface
Along with an interface update, I added a some language extras.  The native Tileland instructions remain (polygons, colours, and turning) but now I have added the environment instructions to the language.  In particular, I have added clipboard manipulation instructions. Although somewhat hidden, this addition is a metalanguage or a preprocessing language.

It's actually pretty simple when you see an example.  An orange hexagon with a blue square would be 6 o 4 b.  The picture below is a that with a right turn or 6o4b>.  The colour follows the shape so that it has something to colour. Doing that 4 times is just 6o4b>6o4b>6o4b>6o4b>.  Another way to make the pattern is to use the clipboard.  I haven't yet introduced a concept of a cursor yet so the clips come from the entire current code. There are 5 instructions that affect the clipboard: x, v, n, m, and q.  The first, x, simply transfers the current code into the clipboard.  The second, v, adds the first clip to the current code. The next two n and m roll the clips left and right. The final one, q, clears all the clips.  The other letter instruction, z, removes the last chunk from the current code (only really useful in an immediate situation).  So, to make the loop of squares and hexagons using the clipboard you could type 6o4b>xvvvv or cut and paste that into the code textbox. The result of either action is [6o4b>][6o4b>][6o4b>][6o4b>] -- the brackets chunk the code but do not affect the resulting picture.

The code in the Tileland+ image was produced by using 2 different clips -- this required using the n and m instructs to change the first clip back and forth.  For instance, in this code, "6o4>6p>>>4o>x 6o4>x  vvvnvmvnvmvnvv", the first two chunks make the clips and the third chunk use the two clips.  In terms of cutting and pasting sometimes it's best to start with a fresh clipboard so an initial q can make a fresh start -- so q6o4>6p>>>4o>x6o4>xvvvnvmvnvmvnvvmvnvvmvnvvv so  makes the pattern in the image.

Play around with this version of Tileland and tell me what you think.

Wednesday, August 27, 2014

New TileLand prototype

This thing is "alpha" code.  It's hot off the press with enough functionality to do interesting things but it's not very polished.  I added the link on the side bar so it'll be easy to access.  The programs come in graphical and textual forms which currently allows you to save your programs by cutting and pasting the text into a place to use later. I stripped down the instructions to one letter to make it more compact and uniform and ease of coding with a keyboard.  I'm sure things will change when I get the time.
There are some annoying bugs that I will fix soon: the one the is most irksome is that my collision detection has some issues that I believe are mainly occurring with triangles but I really haven't done any extensive testing...  

Saturday, June 07, 2014

Revisiting an unravelling

This is based on an old pattern where I took a clockwise loop of 6 pentagons and combined them with two counter clockwise loops of 3 hexagons resulting in a clockwise loop of pentagons and hexagons. One way to think about the process is to imagine unravelling the loop of pentagons. I used this pattern back in back in 2007 and 2006 but this one has a bit more of a twist.
Perhaps I should come up with a visual of this unravelling. I was hoping I would find one in my blog but I didn't. I should make a better index for this thing...done. In this screen capture, you can see that the outside of the original pentagon loop is now the inside of the composed shape and the inside of the original loop corresponds to the 4 sides of the pentagons the are on the outside of the composed shape. Perhaps I'll play some more with this ‡(double dagger shape which I found its html code here).

Sunday, June 01, 2014

Zig, Zag, Zog

Here's just a bit of play before I head to Basketball. I call it zig, zag, zog because there are 3 chunks to the code. Usually, I have a standard zig-zag pattern alternating between to 2 chunks of code. But there are three loops: one if made of zig and zag, another is made from zig and zog, and the final is made of zag and zog. Not too deep but still nice with my new SVG output.
This picture of the code shows a as zig, b as zag, and c as zog. It's pretty clear that a calls b which calls a making a zig-zag loop; and similarly that b calls c which calls b making the zag-zog loop. But the zig-zog loop takes a bit of though--in the code for b since it calls both an a and a c. But essentially c results in a cbcbcb loop with that last b also calling an a so the first c essentially calls an a. Similarly a essentially calls an c thus resulting in the zig-zog loop. There's a bit of twisting calling going on.

Saturday, May 17, 2014

Google driving...

This apparently won't work by September 2016--so I'm migrating my files to dropbox... Well, I think I finally worked out how to easily get my files in my blog. It was a bit hairy to find the magic link I should have guessed, right? My problem was playing with, fileview, #folder, file/d and many other combinations. But probably most of my issues were related to picassa web not storing my svg files... Now I can get to what I actually want to about polygons!!!
For simple patterns like these, I'll start including the PolygonR&D programs along side. This quilt like pattern has only one chunk of code. I used a few colours so that it would be easier to unravel how it works. Although it is constructed with hexagons, squares, and triangles, the white spaces are probably the more interesting features. The Xs and the compass-like (called compass rose or windroses) gaps probably offer more interest than the polygons. Tracing the code chunks means follow the "a" in clock-wise motion around the Xs and counter clock-wise motion around the windroses. The branching nature of the codes makes up for it's simplicity.
I'm always enjoy playing with the odd-sided polygons. This pattern requires a branching factor of 3. The reason is that each of the olive triangles has more 6 paths going through it rather than only 3--so there is a bit of duplication required. Sometimes the evolution of a pattern comes from different ideas: here I started with combining 3 heptagons to make a sequence of edges to make a 180 rotation and undoing that rotation with 3 triangles to produce straight line. These "straight lines" are essentially the code chunk seen on the side. Although, you see the PolygonR&D code on the side, most of my play with local patterns come occurs in Tileland...I guess this means I may have to eventually either provide a bridge from Tileland to PolygonR&D or simply make PolygonR&D's interface a bit better at the intermediate...

I call this last pattern Bugs. I figure that even though it's a fairly simple pattern it has an interesting twist: it's has what I call a zig-zag. Imagine you have grid of squares that are separated by "spacers. These spacers have 2 hexagons and a square which have a slight twist--call is a zig. So to make the grid fit together, you need to undo that twist with a zag (the mirror action). This can be seen in the code by alternating from "a" to "b" and from "b" to "a".
Now that I know how to easily insert my SVG files into my blog entries, I will be making a few more entries. The SVG files look so much better than my screen captures of the past...I may have to revisit a few of my favourite patterns from before... As well, I should make a better index so that I can find my patterns more easily. Perhaps this is just a matter of updating my style preferences...

Popular Posts