POV-Ray : Newsgroups : povray.binaries.images : Looking at cities again Server Time
1 Nov 2024 16:23:20 EDT (-0400)
  Looking at cities again (Message 1 to 10 of 19)  
Goto Latest 10 Messages Next 9 Messages >>>
From: Bill Pragnell
Subject: Looking at cities again
Date: 2 Dec 2012 19:05:01
Message: <web.50bbec4030457a1e51586490@news.povray.org>
Not posted any images for a while, so here's a current intermittent work in
progress that's just about worth sharing.

Cities are largely defined by their street plans, so I thought it would be nice
to be able to intersect a list of lines to produce city blocks.

So far I have a fairly inelegant macro to find triangles and quads from an
arbitrary list of lines, an incomplete set of macros to make city blocks from
arbitrary polygons, and the beginnings of some macros to make buildings from
arbitrary polygon floorplans. If any block polygons are too small, they are
either filled with a single building or omitted entirely (useful for plazas and
suchlike). I really need an intermediate option, to fill a medium-sized block
with 3 or 4 buildings instead of looping around the edges.

I've also plotted the lines to make the process clear.

As always with such things, most of the fun is in the coding, so I fully
anticipate to never fully finish this project, but hopefully it should produce
some interesting images along the way :-)

Bill


Post a reply to this message


Attachments:
Download 'city_blocks.jpg' (145 KB)

Preview of image 'city_blocks.jpg'
city_blocks.jpg


 

From: Christian Froeschlin
Subject: Re: Looking at cities again
Date: 2 Dec 2012 19:48:30
Message: <50bbf6de$1@news.povray.org>
Bill Pragnell wrote:

> Cities are largely defined by their street plans, so I thought it
> would be nice to be able to intersect a list of lines to produce city
> blocks.

that is very neat!

> I really need an intermediate option, to fill a medium-sized block 
> with 3 or 4 buildings instead of looping around the edges.

you might also consider merging narrow blocks with a neighboring
block. In effect this means two streets are getting so close to
one could simply end at a T-junction.


Post a reply to this message

From: Kenneth
Subject: Re: Looking at cities again
Date: 3 Dec 2012 00:15:00
Message: <web.50bc344b6615d26dc2d977c20@news.povray.org>
Very nice work!


Post a reply to this message

From: Thomas de Groot
Subject: Re: Looking at cities again
Date: 3 Dec 2012 02:52:11
Message: <50bc5a2b$1@news.povray.org>
<drool> That is coming along nicely indeed. What obvious question of 
course is: could you also use splines for the street plan? That would 
generate the pre-modern cities nicely I guess. [obsessive thought: I 
could use such a thing for Gancaloon] ;-)

Thomas


Post a reply to this message

From: Paolo Gibellini
Subject: Re: Looking at cities again
Date: 3 Dec 2012 03:27:45
Message: <50bc6281$1@news.povray.org>
>Bill Pragnell  on date 03/12/2012 1.03 wrote:
> Not posted any images for a while, so here's a current intermittent work in
> progress that's just about worth sharing.
>
> Bill
>
Really nice, expecially I like the generated courtyards within groups of 
small houses.
;-)
Paolo


Post a reply to this message

From: Jaime Vives Piqueres
Subject: Re: Looking at cities again
Date: 3 Dec 2012 03:31:49
Message: <50bc6375@news.povray.org>

> So far I have a fairly inelegant macro to find triangles and quads
> from an arbitrary list of lines, an incomplete set of macros to make
> city blocks from arbitrary polygons, and the beginnings of some
> macros to make buildings from arbitrary polygon floorplans. If any
> block polygons are too small, they are either filled with a single
> building or omitted entirely (useful for plazas and suchlike). I
> really need an intermediate option, to fill a medium-sized block with
> 3 or 4 buildings instead of looping around the edges.

   Looking very promising, indeed, and the approach seems to make sense
(just needs a way to add irregular lines, like Thomas said).

> As always with such things, most of the fun is in the coding, so I
> fully anticipate to never fully finish this project, but hopefully it
> should produce some interesting images along the way :-)
>

   A city generator is indeed a very fun project... but if I were you, I
would be already teaching POV-Ray to my children, so they can continue
the work... ;)

   Regards,

--
Jaime


Post a reply to this message

From: clipka
Subject: Re: Looking at cities again
Date: 3 Dec 2012 04:00:13
Message: <50bc6a1d@news.povray.org>
Am 03.12.2012 01:03, schrieb Bill Pragnell:

> Cities are largely defined by their street plans, so I thought it would be nice
> to be able to intersect a list of lines to produce city blocks.

I totally agree with the other posters. This project's drool factor is 
tremendously high indeed.


Post a reply to this message

From: Bill Pragnell
Subject: Re: Looking at cities again
Date: 3 Dec 2012 04:25:00
Message: <web.50bc6fb16615d26d5b7d07940@news.povray.org>
Christian Froeschlin <chr### [at] chrfrde> wrote:
> that is very neat!

Thanks :) It's also been deceptively elusive - this image is an example which
worked quite well, others do not look so natural :\

> you might also consider merging narrow blocks with a neighboring
> block. In effect this means two streets are getting so close to
> one could simply end at a T-junction.

Good idea, I'll definitely consider it. Although it's worth noting that
t-junctions are already allowed for by simply ending lines at random places
rather than driving them all the way through.


Post a reply to this message

From: Bill Pragnell
Subject: Re: Looking at cities again
Date: 3 Dec 2012 04:35:01
Message: <web.50bc71616615d26d5b7d07940@news.povray.org>
Thomas de Groot <tho### [at] degrootorg> wrote:
> <drool> That is coming along nicely indeed. What obvious question of
> course is: could you also use splines for the street plan? That would
> generate the pre-modern cities nicely I guess. [obsessive thought: I
> could use such a thing for Gancaloon] ;-)

True splines might be quite a bit of work, but if I improve the polygon-finding
to handle (N>4) sides then I could approximate curves using straight segments,
which would be handled automagically by the block macros. (Any future roads or
street furniture could use the true splines to hide the approximation).

Your Gancaloon city was one of the things that put me on this path, although as
yet it only works on a plane. Projecting the buildings up to a surface should be
straighforward, however. :-)

Don't drool too much, I have no civil amenities yet ;-)


Post a reply to this message

From: Bill Pragnell
Subject: Re: Looking at cities again
Date: 3 Dec 2012 05:00:01
Message: <web.50bc78036615d26d5b7d07940@news.povray.org>
Jaime Vives Piqueres <jai### [at] ignoranciaorg> wrote:
>    Looking very promising, indeed, and the approach seems to make sense
> (just needs a way to add irregular lines, like Thomas said).

Indeed, see my reply to Thomas.

>    A city generator is indeed a very fun project... but if I were you, I
> would be already teaching POV-Ray to my children, so they can continue
> the work... ;)

I don't have any children to teach (yet!), but it's definitely worth planning
for!


Post a reply to this message

Goto Latest 10 Messages Next 9 Messages >>>

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.