POV-Ray : Newsgroups : povray.newusers : A few problems Server Time
25 Nov 2024 11:30:09 EST (-0500)
  A few problems (Message 1 to 10 of 11)  
Goto Latest 10 Messages Next 1 Messages >>>
From: Nexus
Subject: A few problems
Date: 31 Dec 2005 00:35:00
Message: <web.43b6177e25bf7649bdc77bf40@news.povray.org>
I've just created my first non-tutorial-related scene and I think it's OK
for a first attempt but there's a few things I'd like help on.


The scene is the view from the surface of a small, gray, rocky planet
(modelled with a height field I generated with Fractint). There's also a
yellowish star and a big blue gas planet with a dust ring.

Here's my problems:

1) There's black triangular shadowy bits on the height field that just don't
look right. How do I get rid of them?
2) The star is right in the top right hand corner of the picture and it
looks squashed. I think that's got something to do with the camera but I
have no idea how to fix it.
3) The blue planet has a thin "atmosphere" that I made with a thin spherical
shell containing blue-colored scattering media. The trouble is that the
atmosphere cuts off abruptly and looks awful. How do I get spherical
density_maps to work with scattering media so that the atmosphere drops off
gradually? I can't get them to work at all; POVRay keeps complaining at me
if I try.
4) This one's kind of subtle. The dust ring is also made of scattering media
and circles the entire planet. There is a small region near the night side
of the planet where light scatters from the ring and passes through the
atmosphere but it ends up brown instead of blue. It's as if the atmosphere
is absorbing the blue light from the scattered rays instead of scattering
them again. Is that supposed to happen? and how do I fix it?



Thanks a lot for your time.

Nexus


Post a reply to this message

From: Nexus
Subject: Re: A few problems
Date: 31 Dec 2005 05:00:00
Message: <web.43b656098c0fdebede75dfa0@news.povray.org>
My image in all its n00by glory can be found at

http://news.povray.org/povray.binaries.images/attachment/%3Cweb.43b65316182a5f79ede75dfa0%40news.povray.org%3E/scenea.p
ng

if it's not clear from my descriptions what the problem is.


Post a reply to this message

From: Chris B
Subject: Re: A few problems
Date: 31 Dec 2005 05:29:07
Message: <43b65d73@news.povray.org>
"Nexus" <nomail@nomail> wrote in message 
news:web.43b6177e25bf7649bdc77bf40@news.povray.org...
> .. snip ..
> 2) The star is right in the top right hand corner of the picture and it
> looks squashed. I think that's got something to do with the camera but I
> have no idea how to fix it.
>  .. snip ..
>
> Nexus
>

It's not just that it's a sphere illuminated on one side is it?

Regards,
Chris B.


Post a reply to this message

From: Nexus
Subject: Re: A few problems
Date: 31 Dec 2005 05:40:00
Message: <web.43b65f6b8c0fdebede75dfa0@news.povray.org>
>
> It's not just that it's a sphere illuminated on one side is it?
>
> Regards,
> Chris B.

Nope. It's actually a light source that looks_like a yellowish sphere. And
if I move it to near the middle of the view it looks fine.




N.


Post a reply to this message

From: Chris B
Subject: Re: A few problems
Date: 31 Dec 2005 06:03:04
Message: <43b66568$1@news.povray.org>
"Nexus" <nomail@nomail> wrote in message 
news:web.43b65f6b8c0fdebede75dfa0@news.povray.org...
>
>>
>> It's not just that it's a sphere illuminated on one side is it?
>>
>> Regards,
>> Chris B.
>
> Nope. It's actually a light source that looks_like a yellowish sphere. And
> if I move it to near the middle of the view it looks fine.
>
> N.
>

You could try reducing the angle on the camera which should reduce this 
distortion.
You'll need to shift your objects around to compensate.
Try an angle of 20  e.g.   camera {location <0,0,-100> look_at <0,0,0> angle 
20}

Regards,
Chris B.


Post a reply to this message

From: Chris B
Subject: Re: A few problems
Date: 31 Dec 2005 06:14:23
Message: <43b6680f$1@news.povray.org>
"Nexus" <nomail@nomail> wrote in message 
news:web.43b6177e25bf7649bdc77bf40@news.povray.org...
> .. snip ..
> 1) There's black triangular shadowy bits on the height field that just 
> don't
> look right. How do I get rid of them?
> .. snip ..
> Nexus
>

Would I be correct in thinking you've got a normal pattern on the height 
field and ambient turned right down?
My first guess would be that, where the light hits a triangle at a very 
slight angle, the normal pattern adjusts and makes it look relatively 
bright.
A couple of degrees more on the next triangle means no light hits it at all 
and with no ambient it just turns black.
If I'm right, then the options are to
  o  tilt the asteroid more towards the light
  o  adjust the height field so that no triangles are in shadow
  o  add a little ambient to the height field object so that the effect 
isn't so obvious (e.g. finish {ambient 0.1})

Regards,
Chris B.


Post a reply to this message

From: Roman Reiner
Subject: Re: A few problems
Date: 31 Dec 2005 08:10:00
Message: <web.43b682b38c0fdeb36af16e70@news.povray.org>
> 1) There's black triangular shadowy bits on the height field that just don't
> look right. How do I get rid of them?

I guess this is caused by "the shadow line artifact". see 2.4.8  in the
docs.

> 2) The star is right in the top right hand corner of the picture and it
> looks squashed. I think that's got something to do with the camera but I
> have no idea how to fix it.

i do also guess this is camera distortion. smaller viewingangle recommended
as already has been mentioned.

> 3) The blue planet has a thin "atmosphere" that I made with a thin spherical
> shell containing blue-colored scattering media. The trouble is that the
> atmosphere cuts off abruptly and looks awful. How do I get spherical
> density_maps to work with scattering media so that the atmosphere drops off
> gradually? I can't get them to work at all; POVRay keeps complaining at me
> if I try.

spherical densitymaps are some kind of tricky. it is useful (or necessary?)
to create the mediacontaining sphere with a radius of one at the origin and
scale and translate it afterwards. for example when your planet has a
radius of 99 and the athmosphere has a thickness of 1 you should do

<code>
sphere {
  0, 1
  ...
  density {
    spherical
    density_map {
      [0.00 rgb 0]//outside
      [0.99 rgb <.5,.75.,1>]//this is where the planet ends
      [1.00 rgb 0]//inside
    }
  }
  ...
  scale 100
  translate <somevector>
}
</code> (uncomplete and untested)

> 4) This one's kind of subtle. The dust ring is also made of scattering media
> and circles the entire planet. There is a small region near the night side
> of the planet where light scatters from the ring and passes through the
> atmosphere but it ends up brown instead of blue. It's as if the atmosphere
> is absorbing the blue light from the scattered rays instead of scattering
> them again. Is that supposed to happen? and how do I fix it?

I'm not sure but i think this is supposed to be. see at reality. our
athmosphere scatters the blue light and appears therefore blue but when you
look at light that has travelled a long way through it the remaining light
is red and causes a beautiful sunset :-)

> Thanks a lot for your time.

never mind


btw: nice image for your first one

Regards Roman


Post a reply to this message

From: Thomas de Groot
Subject: Re: A few problems
Date: 31 Dec 2005 08:56:11
Message: <43b68dfb@news.povray.org>
"Nexus" <nomail@nomail> schreef in bericht
news:web.43b6177e25bf7649bdc77bf40@news.povray.org...
>
> 1) There's black triangular shadowy bits on the height field that just
don't
> look right. How do I get rid of them?

you may try also to add double_illuminate to the height_field in case you
have smoothed it.

Thomas


Post a reply to this message

From: Abe
Subject: Re: A few problems
Date: 1 Jan 2006 16:30:01
Message: <web.43b845d28c0fdebea1533070@news.povray.org>
> 3) The blue planet has a thin "atmosphere" that I made with a thin spherical
> shell containing blue-colored scattering media. The trouble is that the
> atmosphere cuts off abruptly and looks awful. How do I get spherical
> density_maps to work with scattering media so that the atmosphere drops off
> gradually? I can't get them to work at all; POVRay keeps complaining at me
> if I try.

I've used the following approach in the past:
#include "functions.inc"
#declare Atmos=
sphere {
  0, PlanetSize+AtmosHt
  hollow
  texture {
    pigment {color rgbt 1}
    finish{specular 0  ambient 0 diffuse 0}
  }
  interior{
    media{
      scattering{1 rgb AtmosIntensity*<.4,.5,1>/PlanetSize extinction 0}
      density{
       function{min(1,max(0,f_sphere(x,y,z,PlanetSize)/AtmosHt))}
       poly_wave AtmosFalloff
       color_map{[0 rgb 1][1 rgb 0]}
      }

    }
  }
  translate PlanetPosition
}

Note that the values for PlanetSize, PlanetPosition, AtmosHt, AtmosFalloff
and AtmosIntensity obviosly need to be declared. I was playing with values
of 0.2 and 2 for AtmosFalloff and AtmosIntensity respectively with ok
results under a light_source color of rgb <1,1,1>.

The reason for dividing the media intensity by planet size is to keep the
media "intensity" somewhat constant irrespective of container size.

The function f_sphere is clamped and scaled so as to return 0 at (and below)
the planet's surface increasing to 1 at (and above) a distance of AtmosHt
from the planet's surface.

You could probably also use a tight area light instead of a point light for
the sun to soften the terminator a bit. Remember to take advantage of
circular and orient.

> 4) This one's kind of subtle. The dust ring is also made of scattering media
> and circles the entire planet. There is a small region near the night side
> of the planet where light scatters from the ring and passes through the
> atmosphere but it ends up brown instead of blue. It's as if the atmosphere
> is absorbing the blue light from the scattered rays instead of scattering
> them again. Is that supposed to happen? and how do I fix it?

If you did not explicitly set the extinction value in the scattering
statement for your media then you are using the default extinction value of
1. Set the extinction value to 0 to eliminate the attenuation effect.

Let us know what works for you!

Abe


Post a reply to this message

From: Alain
Subject: Re: A few problems
Date: 1 Jan 2006 21:34:50
Message: <43b8914a$1@news.povray.org>
Nexus nous apporta ses lumieres en ce 2005-12-31 00:31:
> I've just created my first non-tutorial-related scene and I think it's OK
> for a first attempt but there's a few things I'd like help on.
> 
> 
> The scene is the view from the surface of a small, gray, rocky planet
> (modelled with a height field I generated with Fractint). There's also a
> yellowish star and a big blue gas planet with a dust ring.
> 
> Here's my problems:
> 
> 1) There's black triangular shadowy bits on the height field that just don't
> look right. How do I get rid of them?

Normal with a hight field. You can use the soloution given by thers. Another, but
slower, way would 
be to replace the height field by an equivalent isosurface.

> 2) The star is right in the top right hand corner of the picture and it
> looks squashed. I think that's got something to do with the camera but I
> have no idea how to fix it.

Normal distortion. Using a smaler camera angle and tightening the objects placement
can be done.

> 3) The blue planet has a thin "atmosphere" that I made with a thin spherical
> shell containing blue-colored scattering media. The trouble is that the
> atmosphere cuts off abruptly and looks awful. How do I get spherical
> density_maps to work with scattering media so that the atmosphere drops off
> gradually? I can't get them to work at all; POVRay keeps complaining at me
> if I try.

As an alternative to the other suggestions, you can use an onion pattern for your
density.
Note that you don't need to bring the density to zero inside the planet, you don't see
that part and 
unless you specificaly make the planet hollow, the media won't exist inside the
planet.

> 4) This one's kind of subtle. The dust ring is also made of scattering media
> and circles the entire planet. There is a small region near the night side
> of the planet where light scatters from the ring and passes through the
> atmosphere but it ends up brown instead of blue. It's as if the atmosphere
> is absorbing the blue light from the scattered rays instead of scattering
> them again. Is that supposed to happen? and how do I fix it?
> 

You scather off the blue part, so the light that get true is tinted the complementary
colour. It's 
physicaly acurate, even if you find the result surprising.

> 
> 
> Thanks a lot for your time.
> 
> Nexus
> 
> 
> 


Alain


Post a reply to this message

Goto Latest 10 Messages Next 1 Messages >>>

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