|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Hi,
I'm using the following code to produce sun-light in a povray scene:
// distance: 150.000.000km, diameter 1.932.000km
//Declare variables so you won't have mysterious numbers all over your code:
#declare V_SUN = <3000, 3000, 3000>; //Not necessarily overhead.
#declare dSun = vlength (V_SUN) * (1390000/150000000);
light_source
{ V_SUN, color White
area_light dSun * x, dSun * z, 5, 5 adaptive 1 jitter
circular orient //Using this, the Sun doesn't have to be overhead.
parallel point_at 0
looks_like
{ sphere
{ 0, dSun //Location is relative to the light_source, not the origin.
pigment { color rgb <1, 1.0, 0.85> }
//Give the Sun a glowing appearance:
finish { diffuse 0 ambient 1 } //POV-Ray 3.6.
//or
finish { diffuse 0 ambient 0 emission 1 } //POV-Ray 3.7.
}
}
}
This works very well.
I'm now trying to simulate night and day. I thought I just could add a
rotate<clock, 0, 0> just before the last line and control that using +Ksomevalue
on the commandline (which works fine for rotating other objects). For this
sunlight it does not have any effect.
What am I doing wrong?
regards
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
At a quick glance, I'm not sure what's wrong with that.
Also, are you aware of sunpos.inc?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Bald Eagle" <cre### [at] netscapenet> wrote:
> At a quick glance, I'm not sure what's wrong with that.
>
> Also, are you aware of sunpos.inc?
Yes but it only calculates the position?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"folkert" <fol### [at] vanheusdencom> wrote:
> "Bald Eagle" <cre### [at] netscapenet> wrote:
> > At a quick glance, I'm not sure what's wrong with that.
> >
> > Also, are you aware of sunpos.inc?
>
> Yes but it only calculates the position?
Well, yes, but if you change the "time" with the clock value, then the sun goes
around...
http://news.povray.org/povray.binaries.animations/thread/%3Cweb.584ff182dc625f27c437ac910%40news.povray.org%3E/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
I put a simple box object into a scene to check the effect, with my camera near
the origin. Try using a backwards rotation-- I do see the changing light effect
then.
Like, +K-30 on the command line.
....
finish { diffuse 0 ambient 1 } //POV-Ray 3.6.
//or
finish { diffuse 0 ambient 0 emission 1 } //POV-Ray 3.7.
}
}
rotate <clock,0,0>
}
I do notice that, past some some positive rotation angle, the light looks like
it disappears(?). Maybe the Sun is moving below the horizon, based on V_SUN's
original position?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
By the way, your looks_like sphere seems to be HUGE-- almost like a sky_sphere.
Its radius is scaled up by d_sun. Did you mean to do that?
> looks_like{
> { sphere
> { 0, dSun //Location is relative to the light_source, not the origin.
> pigment { color rgb <1, 1.0, 0.85> }
> //Give the Sun a glowing appearance:
> finish { diffuse 0 ambient 1 } //POV-Ray 3.6.
> //or
> finish { diffuse 0 ambient 0 emission 1 } //POV-Ray 3.7.
Maybe that's causing the problem. I would suggest something like...
looks_like{sphere{0, --some other smaller radius?---
(or maybe some fraction of d_sun)
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Kenneth" <kdw### [at] gmailcom> wrote:
> By the way, your looks_like sphere seems to be HUGE-- almost like a sky_sphere.
> Its radius is scaled up by d_sun. Did you mean to do that?
Yes :-)
I wanted it to be as real as the real sun.
> > looks_like{
> > { sphere
> > { 0, dSun //Location is relative to the light_source, not the origin.
> > pigment { color rgb <1, 1.0, 0.85> }
> > //Give the Sun a glowing appearance:
> > finish { diffuse 0 ambient 1 } //POV-Ray 3.6.
> > //or
> > finish { diffuse 0 ambient 0 emission 1 } //POV-Ray 3.7.
>
> Maybe that's causing the problem. I would suggest something like...
> looks_like{sphere{0, --some other smaller radius?---
> (or maybe some fraction of d_sun)
Hmmm but with the experiment you did it worked fine? The one with the box.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
I suddenly realised what the issue is: the sun does rotate but...there's a
sky_sphere as well. So it always looks like day-time.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"folkert" <fol### [at] vanheusdencom> wrote:
> I suddenly realised what the issue is: the sun does rotate but...there's a
> sky_sphere as well. So it always looks like day-time.
Glad you worked it out.
Sorry, I misread your dsun equation, thinking it was a HUGE value (which got me
off-track.) But it's only 48.15 units, with the resulting looks_like sphere
positioned at your light source at <3000,3000,3000>.
My box experiment showed only the shadow effects FROM your light source, onto a
plane; I didn't think to aim the camera *at* your Sun, to see its visible sphere
shape.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |