![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
On 09-Sep-08 21:44, Tek wrote:
> I had a bit of a play with a function to create this pattern. Obviously I'm
> cheating and not using rectangular blocks. Here's the code:
>
> #declare Wrap = function(a) { (a/2-floor(a/2))*2-1 }
> #declare Feeder = function(x,y) { Wrap( (y -
> sqrt(1-pow(Wrap(x*sqrt(2))/sqrt(2),2)))*8 ) }
> #declare Tiles =
> pigment { function {
> min(
> 1-abs(Feeder(x,y))
> ,
> abs(Wrap(8.8*(-Feeder(x,y)*.1+.9)*Wrap(x*sqrt(2))))
> )
> } }
>
>
If this were a short code contest, I would say that
pow(Wrap(x*sqrt(2))/sqrt(2),2)) is equivalent to
pow(Wrap(x*sqrt(2)),2)/2)
other than that, I am baffled.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
While I prefer ChrisB's solution as being closer to the original idea (and
purpose), your variation is very nice indeed introduces an interesting
modulation of the pattern from rectangular to diamond-shaped. I love it!
Thomas
"Tek" <tek### [at] evilsuperbrain com> schreef in bericht
news:48c6d20f@news.povray.org...
>I had a bit of a play with a function to create this pattern. Obviously I'm
>cheating and not using rectangular blocks. Here's the code:
>
> #declare Wrap = function(a) { (a/2-floor(a/2))*2-1 }
> #declare Feeder = function(x,y) { Wrap( (y -
> sqrt(1-pow(Wrap(x*sqrt(2))/sqrt(2),2)))*8 ) }
> #declare Tiles =
> pigment { function {
> min(
> 1-abs(Feeder(x,y))
> ,
> abs(Wrap(8.8*(-Feeder(x,y)*.1+.9)*Wrap(x*sqrt(2))))
> )
> } }
>
>
> --
> Tek
> http://evilsuperbrain.com
>
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Jim Charter" <jrc### [at] msn com> schreef in bericht
news:48c49700$1@news.povray.org...
>>
> This is pretty close to what I did with the circular mosaic patterns on
> the table tops I posted recently.
> The code is real messy, it probably would be more work for you to try and
> read it than to write your own but I will try to annotate it if you are
> interested.
> Basically what I contrived, was a set of concentric bands or rings of a
> preset width. Since the tiles were considered squares the width of the
> band determined the number of tiles along the inner circumference. But
> each sucessive band, as you expand from the center, does not add enough
> circumference to accommodate a whole new tile along it each time. So what
> I did was average the growing discrepency across the gaps of all the
> tiles, rather than leave a gap or try to make a partial tile at the end.
> Then when the circumference had expanded enough, I added a new tile. Also
> I randomized the 'starting' point for each ring of tiles.
Thank you Jim! I shall have to read this very carefully. Unfortunately, my
math is a bit below average which is why I could not find a way out of this
conundrum. However, there are great minds here (yours, and Chris' and Tek's)
who readily find a solution. I am truly deeply impressed.
Thomas
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Thomas de Groot wrote:
> "Jim Charter" <jrc### [at] msn com> schreef in bericht
> news:48c49700$1@news.povray.org...
>
>>This is pretty close to what I did with the circular mosaic patterns on
>>the table tops I posted recently.
>>The code is real messy, it probably would be more work for you to try and
>>read it than to write your own but I will try to annotate it if you are
>>interested.
>>Basically what I contrived, was a set of concentric bands or rings of a
>>preset width. Since the tiles were considered squares the width of the
>>band determined the number of tiles along the inner circumference. But
>>each sucessive band, as you expand from the center, does not add enough
>>circumference to accommodate a whole new tile along it each time. So what
>>I did was average the growing discrepency across the gaps of all the
>>tiles, rather than leave a gap or try to make a partial tile at the end.
>>Then when the circumference had expanded enough, I added a new tile. Also
>>I randomized the 'starting' point for each ring of tiles.
>
>
> Thank you Jim! I shall have to read this very carefully. Unfortunately, my
> math is a bit below average which is why I could not find a way out of this
> conundrum. However, there are great minds here (yours, and Chris' and Tek's)
> who readily find a solution. I am truly deeply impressed.
>
> Thomas
>
>
Well Chris's solution is more comprehensive so I will leave it at that!
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
#include "shapes.inc"
#declare S=seed(0);
#local Scale = .375;
#local StartRing = 5;
#local NumberOfRings=10;
#local TileSize = .48*Scale; //set the space for grout
#local Ring=StartRing;
//circular grid
#while(Ring<NumberOfRings)
//#debug #concat ("\n Lat ",str(Lat,0,0 ))
#local Circum = 2*3.1416*Ring*Scale;
#local NumberOfTiles = int(Circum/Scale);
#local Remainder = mod(Circum/Scale,1);
#local Adj = 1+Remainder/NumberOfTiles;
#local Offset=60*rand(S);
#local Tile=1;#while(Tile<NumberOfTiles+1 )
object {
Round_Box_Merge (
<-TileSize,0,0>,
<TileSize,-.5,2*TileSize>,
TileSize/20
)
translate <0,0,Ring*Scale>
rotate y*(Offset+(360*(Tile*Adj)/(Circum/Scale)))
pigment { rgb .5}
}
#local Tile=Tile+1;#end
#local Ring=Ring+1;#end
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
>> "Thomas de Groot" <t.d### [at] inter nlDOTnet> wrote in message
>> news:48c3964b@news.povray.org...
>>>
>>> How would one model this pavement in POV-Ray?
> Below is a simple POV-Ray encapsulation of this. There are lots of things
> you can play with, ...
I've tidied this macro up, written it up and added it to the Object
Collection. at
http://lib.povray.org/collection/curvedpaving/chrisb%201.0/curvedpaving.html
It's probably too late to be of use to Thomas, but maybe someone else can
make use of it.
Regards,
Chris B.
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Chris B" <nom### [at] nomail com> schreef in bericht
news:49259471$1@news.povray.org...
>
>
> I've tidied this macro up, written it up and added it to the Object
> Collection. at
> http://lib.povray.org/collection/curvedpaving/chrisb%201.0/curvedpaving.html
>
> It's probably too late to be of use to Thomas, but maybe someone else can
> make use of it.
>
Thanks a lot Chris! I had no immediate use for this pavement when I started
the thread. It had been playing in my mind for quite a long time and it just
came up again. However, I am sure I shall find use for it sooner or later.
Thomas
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |