POV-Ray : Newsgroups : povray.general : Problem with multiple f_hetero_mf isosurfaces Server Time
16 Nov 2024 19:17:08 EST (-0500)
  Problem with multiple f_hetero_mf isosurfaces (Message 1 to 4 of 4)  
From: Alun
Subject: Problem with multiple f_hetero_mf isosurfaces
Date: 10 Sep 2003 10:00:01
Message: <web.3f5f2d3e6dc97f052667dc700@news.povray.org>
I'm creating a scene with two isosurface objects that use similar
f_hetero_mf functions - one for a jagged looking mountain range
in the distance, and one for some smoother rolling hills in the
foreground.

I'm happy with the function for the mountains, so I copy it to use
as the basis for the hills. At this point I've got a scene with 2
identical isosurfaces.

So far so good :-)

To make the hills smoother than the mountains, I change the number
of octaves in the f_hetero_mf function in the hills isosurface,
and re-render...

This is where it all goes wrong :-(

The hills isosurface changes correctly, but the mountains one also
changes - and not always in the same way, for some hills_octaves
values it changes to a copy of the hills, for others it fills its
container volume, and for others it doesn't change at all.

I know this sounds like I'm doing something daft, but I've
simplified the scene right down, and I can't see anything wrong
with it.

Could someone out there have a look at this and let me know if I
am doing something daft ?

Here's my cut down scene:
---------------
#version 3.5;

#include "functions.inc"
//
---------------------------------------------------------------------------------------

#declare mountain_octaves=12;
#declare hills_octaves=12;     // Try changing this to 4 ...

//
---------------------------------------------------------------------------------------

camera {
  right x*image_width/image_height
  location  -10*z
  look_at   -y/2
  angle 30
}


light_source { 2*y-z rgb 1 }

//
---------------------------------------------------------------------------------------

isosurface {
  function { 2+y - f_hetero_mf(0.2+x,0,z, 0.9, 1.7, mountain_octaves, 0.5,
0.9, 3 ) }
  contained_by { sphere {0 1} }
  evaluate 5, 1.2, 0.95
  pigment { rgb <0.7,0.8,0.9> }
  translate x*1.2
}

//
---------------------------------------------------------------------------------------

isosurface {
  function { 2+y - f_hetero_mf(0.2+x,0,z, 0.9, 1.7, hills_octaves, 0.5, 0.9,
3 ) }
  contained_by { sphere {0 1} }
  evaluate 5, 1.2, 0.95
  pigment { rgb <0.5,0.8,0.6> }
  translate -x*1.2
}

//
---------------------------------------------------------------------------------------


Post a reply to this message

From: Tom Melly
Subject: Re: Problem with multiple f_hetero_mf isosurfaces
Date: 10 Sep 2003 11:12:32
Message: <3f5f3f60$1@news.povray.org>
"Alun" <tho### [at] lineonenet> wrote in message
news:web.3f5f2d3e6dc97f052667dc700@news.povray.org...

<snip>

Weird - very much looks like a bug.

You can 'fix' it by adding "translate y*1/750" to the hills (oddly, translating
the mountains up by 1/750 doesn't fix the problem - it creates a slightly
different one).

The problem only seems to occur when you render the iso - by this I mean that if
you declare both isos as objects, you then have to use both objects in the
scene.

Here's the scene I played with (just the modified bits):

#declare mountain_octaves=12;
#declare hills_octaves=4;     // Try changing this to 4 ...

#declare IS1 =
isosurface {
  function { 2+y - f_hetero_mf(0.2+x,0,z, 0.9, 1.7, mountain_octaves, 0.5,0.9,
3 ) }
  contained_by { sphere {0 1} }
  evaluate 5, 1.2, 0.95
  pigment { rgb <0.7,0.8,0.9> }
  translate x*1.2
}

//

#declare IS2 =
isosurface {
  function { 2+y - f_hetero_mf(0.2+x,0,z, 0.9, 1.7, hills_octaves, 0.5,
0.9,3 ) }
  contained_by { sphere {0 1} }
  evaluate 5, 1.2, 0.95
  pigment { rgb <0.5,0.8,0.6> }
  translate -x*1.2
}

object{IS1}
object{IS2 translate -y*1/750} //this is okay!


Post a reply to this message

From: Mike Williams
Subject: Re: Problem with multiple f_hetero_mf isosurfaces
Date: 10 Sep 2003 14:14:21
Message: <dAcLeBATh2X$Ew$L@econym.demon.co.uk>
Wasn't it Alun who wrote:
>I'm creating a scene with two isosurface objects that use similar
>f_hetero_mf functions - one for a jagged looking mountain range
>in the distance, and one for some smoother rolling hills in the
>foreground.

It looks like a really weird bug to me.

One unusual feature of the effect is that if you re-render the unchanged
scene, you get a different result most of the time. If you don't spot
that fact (it took me a while) then it's easy to make a small change to
the source and think that you've found a workround.

-- 
Mike Williams
Gentleman of Leisure


Post a reply to this message

From: Tom Melly
Subject: Re: Problem with multiple f_hetero_mf isosurfaces
Date: 10 Sep 2003 15:40:19
Message: <3f5f7e23@news.povray.org>
"Mike Williams" <mik### [at] econymdemoncouk> wrote in message
news:dAcLeBATh2X$Ew$L@econym.demon.co.uk...

> One unusual feature of the effect is that if you re-render the unchanged
> scene, you get a different result most of the time. If you don't spot
> that fact (it took me a while) then it's easy to make a small change to
> the source and think that you've found a workround.
>

Ah - that rings a bell (a presumably unrelated bug in a pov .35 beta).

How does Alun report this as a bug?


Post a reply to this message

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