POV-Ray : Newsgroups : povray.binaries.images : Isosurface problem - how to create real ridges? Server Time
26 Dec 2024 14:09:34 EST (-0500)
  Isosurface problem - how to create real ridges? (Message 1 to 3 of 3)  
From: Jörg "Yadgar" Bleimann
Subject: Isosurface problem - how to create real ridges?
Date: 10 Feb 2018 07:31:59
Message: <5a7ee63f@news.povray.org>
Hi(gh)!

Returning to my "Whatmough" project from 2011, I now tried to create the 
entire planet Whatmough as an isosurface in the first place - by 
gleaning parameters from the heightfield generator software "Wilbur", 
which also uses the ridged multifractal function.

But something is strange: the ridges form grooves in the surface rather 
than sticking out as mountain ranges, as you can see in the attached 
image, I tried several combinations of positive and negative function 
parameters, but did not succeed in getting rid of this...

Here is the code:

#include "functions.inc"

#declare sc = 10000; // universal scaling factor

#declare T_Whatmough_Solid =
texture
{
   pigment { color rgb <0, 0.8, 0> }
   finish { ambient 0.05 diffuse 1 brilliance 1.5 }
}

#declare S =
function { x*x + y*y + z*z -1 } // spherical isosurface

#declare Whatmough_Terrain_Function =
function { S(x, y, z) +  f_ridged_mf(-x, -y, -z, 1, 1.9, 7, 1, 2, 1)/50 }

#declare Whatmough =
isosurface
{
   function { Whatmough_Terrain_Function(x,y,z)/2 }
   contained_by
   {
     sphere { 0, 1.2 }
   }
   max_gradient 20
   accuracy 0.00000001
   double_illuminate
   texture { T_Whatmough_Solid }
   scale 5902.45/sc
}

light_source
{
   0
   color rgb 1
   looks_like
   {
     sphere // HD 28185
     {
       0, 723528/sc
       pigment { color rgb 1 }
       finish { ambient 1 }
     }
   }
}

sphere // HD 28185 glow
{
   0, 1
   hollow
   texture
   {
     pigment { color rgbft <1, 1, 1, 0.5, 0.5> }
   }
   interior
   {
     media
     {
       emission rgb <1, 1, 0.82>/(723528*7/sc)
       density
       {
         spherical
         poly_wave 4
       }
     }
   }
   scale 723528*7/sc
}

#declare HD_28185_b =
sphere
{
   0, 1
   texture
   {
     pigment { color rgb <0.6, 0.6, 0.85> }
     finish { ambient 0.05 diffuse 1 brilliance 0.9 }
   }
   scale <68332, 67045, 68332>/sc
}

#declare HD_28185_b_Dist = 154200000/sc;
#declare HD_28185_b_AngPos = 156;
#declare HD_28185_b_Pos = 
HD_28185_b_Dist*<sin(radians(HD_28185_b_AngPos)), 0, 
cos(radians(HD_28185_b_AngPos))>;
#declare Whatmough_Dist = 912580/sc;
#declare Whatmough_AngPos = 254;
#declare Whatmough_Pos = HD_28185_b_Pos + 
Whatmough_Dist*<sin(radians(Whatmough_AngPos)), 0, 
cos(radians(Whatmough_AngPos))>;
#declare camDist = 30000/sc;
#declare cam_AngPos = 16;
#declare camPos = Whatmough_Pos + camDist*<sin(radians(cam_AngPos)), 0, 
cos(radians(cam_AngPos))>;


object
{
   HD_28185_b
   translate HD_28185_b_Pos
}

object
{
   Whatmough
   translate Whatmough_Pos
}

camera
{
   location camPos
   look_at Whatmough_Pos
   angle 40
}

Any suggestions?

See you in Khyberspace!

Yadgar


Post a reply to this message


Attachments:
Download '2018-02-10 whatmough, take 1.png' (80 KB)

Preview of image '2018-02-10 whatmough, take 1.png'
2018-02-10 whatmough, take 1.png


 

From: Bald Eagle
Subject: Re: Isosurface problem - how to create real ridges?
Date: 10 Feb 2018 08:10:01
Message: <web.5a7eee0030e961385cafe28e0@news.povray.org>
Sure, just change it to:

#declare Whatmough_Terrain_Function =
function { S(x, y, z) -  f_ridged_mf(-x, -y, -z, 1, 1.9, 7, 1, 2, 1)/50 }

                      ^ minus


Post a reply to this message

From: Jörg "Yadgar" Bleimann
Subject: Re: Isosurface problem - how to create real ridges?
Date: 10 Feb 2018 18:46:24
Message: <5a7f8450$1@news.povray.org>
Hi(gh)!

On 10.02.2018 14:05, Bald Eagle wrote:
> Sure, just change it to:
> 
> #declare Whatmough_Terrain_Function =
> function { S(x, y, z) -  f_ridged_mf(-x, -y, -z, 1, 1.9, 7, 1, 2, 1)/50 }
> 
>                        ^ minus
> 

Yes, that's the ticket (as you can see in the attached image... thank you!

After that, I started an animation showing the rotating planet 
(technically, it is an almost Earth-sized moon of exoplanet HD 28185 b), 
which will be completed this night (CET) and then published on 
YouTube... watch out!

Then, I plan to generate cylindrical topographic maps of Whatmough like 
I did with Ghurghusht back in 2010, also in very large scales to place 
vegetation, buildings and traffic systems on the planet!

See you in Khyberspace!

Yadgar


Post a reply to this message


Attachments:
Download 'whatmough_planet-.png' (49 KB)

Preview of image 'whatmough_planet-.png'
whatmough_planet-.png


 

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