Page 1 of 1

Output not tiling

Posted: Sat Mar 21, 2020 5:16 am
by flembobs
An image I made tiles fine inside Context Free but when save output it no longer does.

Here's a gallery with screenshot and image:

https://imgur.com/a/vRtTChP

Here's the code:

Code: Select all

CF::Background = [ h -99.43 sat 0.1373 b -0.7370 ]

CF::Tile = [ s 1 skew 15 15 r 15 ]

L1 =  0.01 + ( 0.45*rand_static() )
L2 = -0.01 - ( 0.45*rand_static() )

startshape H ( randint ( 3 )+3 ) []

shape H ( natural n )
{
    if( n > 0 ) 
    {
        loop 6 [ r 60 h 180 ] L [ x n b 1 h 80 sat 0.6 ]
        H ( n--1 ) [ h ( 30*randint()) ]
    }
}

path L
{
    MOVETO (    0,  L1 )
    LINETO (    0,  L2 )
    
    STROKE ( 0.005,  CF::RoundCap) []
}
I set the border to none on image output.

Using Windows Context Free 3.2 ( v44 )

Re: Output not tiling

Posted: Sat Mar 21, 2020 5:20 am
by flembobs
I think I have a tile size wrong somewhere - I don't know.

Re: Output not tiling

Posted: Sat Mar 21, 2020 5:39 pm
by MtnViewJohn
There is nothing wrong with your tiling size. Context Free supports non-rectangular tiling grids. The only requirement is that the tiling grid either have a vertical axis or a horizontal axis. Your hexagonal tiling has a vertical axis, but not a horizontal axis. All other tools that I know of only tile on rectangular grids.

If you look at your design in Context Free you see that the basic rectangle does not have rectangular tiling, it has hexagonal tiling. But if you consider a rectangle that is twice as wide as the basic rectangle, that wider rectangle does have rectangular tiling.

Context Free has the ability to save an output PNG file that is larger than the basic rectangle that it normally saves. In the Save Output dialog there is a pair of controls called Output Multiplier Width and Height. If you set the width to 2 and leave the height at 1 then Context Free will output a PNG file that is twice as wide and tiles on a rectangular grid.

Re: Output not tiling

Posted: Sun Mar 22, 2020 11:22 am
by flembobs
Thanks so much for your help.

I'm having a lot of fun experimenting with tiling shapes that are larger than the tiling bounds.