POV-Ray : Newsgroups : povray.general : Planar structures Server Time
4 Dec 2024 21:43:31 EST (-0500)
  Planar structures (Message 1 to 7 of 7)  
From: Thomas Fester
Subject: Planar structures
Date: 8 Nov 2024 05:20:00
Message: <web.672de5a184a429926c6071e48a2a825f@news.povray.org>
Hello everybody,

after your great help with using loops for naming splines, here comes the work I
have been using you advice for (I have been using the for-loop-approach - #for
(I, 0, 3)
  #declare SplineXs[I] = spline {
    cubic_spline
    ...
  }
#end).

It was for naming splines used in defining flat structures, like this sheet
here. I have made a short youtube video on this topic
(https://www.youtube.com/watch?v=wifqzEzXX8o); scripts are available as always
on Github (https://github.com/tjrfester/Modeling-nature-planar-structures).

Best regards,

Thomas


Post a reply to this message

From: Thomas Fester
Subject: Re: Planar structures
Date: 8 Nov 2024 06:35:00
Message: <web.672df66546958d9c848e17d18a2a825f@news.povray.org>
"Thomas Fester" <tfe### [at] scivitde> wrote:
> Hello everybody,
>
> after your great help with using loops for naming splines, here comes the work I
> have been using you advice for (I have been using the for-loop-approach - #for
> (I, 0, 3)
>   #declare SplineXs[I] = spline {
>     cubic_spline
>     ...
>   }
> #end).
>
> It was for naming splines used in defining flat structures, like this sheet
> here. I have made a short youtube video on this topic
> (https://www.youtube.com/watch?v=wifqzEzXX8o); scripts are available as always
> on Github (https://github.com/tjrfester/Modeling-nature-planar-structures).
>
> Best regards,
>
> Thomas

For some reason my attachment was not attached - here it hopefully comes.


Post a reply to this message


Attachments:
Download '02largearea.png' (368 KB)

Preview of image '02largearea.png'
02largearea.png


 

From: Kenneth
Subject: Re: Planar structures
Date: 8 Nov 2024 12:45:00
Message: <web.672e4d2046958d9c91c33a706e066e29@news.povray.org>
"Thomas Fester" <tfe### [at] scivitde> wrote:
>
> after your great help with using loops for naming splines, here comes the work I
> have been using you advice for (I have been using the for-loop-approach - #for
> (I, 0, 3)
>   #declare SplineXs[I] = spline {
>     cubic_spline
>     ...
>   }
> #end).
>

Hmm. I cannot get that to work, in either 'official' v3.7.0 or v3.8 beta 1.

My own variation, which also fails...

#for(I, 0, 3)
  #declare My_Sphere[I] = sphere {0,.2 translate .5*I*x}
#end

The fatal error is: "Expected '=', [ found instead."

It would be great if such a simple construction would work; are you using a
different POV-ray version, for your success?


Post a reply to this message

From: Bald Eagle
Subject: Re: Planar structures
Date: 8 Nov 2024 12:45:00
Message: <web.672e4d8e46958d9c25b4de9225979125@news.povray.org>
Hi Thomas,

Nice job working on some simple "planar" surfaces.

I thought I'd point you to a few links that might help and inspire you in your
future work.
I like the flattened-sphere method that you're using from a simplicity
standpoint, however I would suggest that triangles or smooth_triangles might be
almost as simple, yet give you a smoother, more continuous surface.

Lohmueller nested loops
 https://www.f-lohmueller.de/pov_tut/loop/povlup1e.htm


For your splines going across the surface, perhaps a Bezier patch would work
best, with a sphere sweep for the splines.

BW/TOK stitched Bezier patches
 https://news.povray.org/web.5b788c1c9b869b61458c7afe0%40news.povray.org
Surface normals
 https://news.povray.org/web.6394bb44855140c41f9dae3025979125%40news.povray.org

Considering your interest in modeling nature, I don't think you'd want to miss
out on Friedrich Lohmueller's excellent leaf modeling tutorial.

Lohmueller leaves
 https://www.f-lohmueller.de/pov_tut/tex/tex_887e.htm

.. . . or this amazing render in the Hall of Fame:
HOF forest
 https://hof.povray.org/fallfury.html

Hopefully this will inspire you, and I'm looking forward to seeing what you do
with all of this in your next full-length video.
I think that you could make an excellent lipid bilayer or something similar!

- BW


Post a reply to this message

From: Bald Eagle
Subject: Re: Planar structures
Date: 8 Nov 2024 13:30:00
Message: <web.672e583346958d9c25b4de9225979125@news.povray.org>
"Kenneth" <kdw### [at] gmailcom> wrote:

> Hmm. I cannot get that to work, in either 'official' v3.7.0 or v3.8 beta 1.
>
> My own variation, which also fails...
>
> #for(I, 0, 3)
>   #declare My_Sphere[I] = sphere {0,.2 translate .5*I*x}
> #end
>
> The fatal error is: "Expected '=', [ found instead."

Are you preceding the loop with the necessary:
#declare SplineXs = array [11]; //The array for storing the splines in
x-direction is created.

The array needs to exist before you try to assign a value to an element of it.

- BW


Post a reply to this message

From: Bald Eagle
Subject: Re: Planar structures
Date: 8 Nov 2024 16:10:00
Message: <web.672e7de646958d9c25b4de9225979125@news.povray.org>
You can also use
isosurfaces (with or without Mike Williams' "thickening" trick),

heightfields

https://news.povray.org/povray.general/thread/%3Cweb.63ea928499ce13121f9dae3025979125%40news.povray.org%3E/?ttop=444299
&toff=100&mtop=439826

polynomials,

and parametrics.


Post a reply to this message

From: Kenneth
Subject: Re: Planar structures
Date: 9 Nov 2024 08:30:00
Message: <web.672f636246958d9c91c33a706e066e29@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:
> "Kenneth" <kdw### [at] gmailcom> wrote:
> >
> > My own variation, which also fails...
> >
> > #for(I, 0, 3)
> >   #declare My_Sphere[I] = sphere {0,.2 translate .5*I*x}
> > #end
> >
>
> Are you preceding the loop with the necessary:
> #declare SplineXs = array [11];

Oh. So there is a pre-made *array*. Well, that explains it! My mistake.

I was still wrapped up in Thomas's previous post about auto-creating #declared
variable NAMES; I thought that this #for loop-- by itself-- was another similar
attempt. Duh. :-[


Post a reply to this message

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