POV-Ray : Newsgroups : povray.windows : Can POV SDL read system time? Server Time
26 Jun 2024 03:43:38 EDT (-0400)
  Can POV SDL read system time? (Message 1 to 4 of 4)  
From: Severi Salminen
Subject: Can POV SDL read system time?
Date: 4 Jan 2004 19:29:40
Message: <3ff8aff4@news.povray.org>
Can I fetch system time anyhow in Windows version of POV-Ray? I have a 
clock in my scene and I'd like it to show the start of rendering but I 
have to do it manually now :)

Severi S.


Post a reply to this message

From: Hughes, B 
Subject: Re: Can POV SDL read system time?
Date: 4 Jan 2004 22:32:11
Message: <3ff8dabb$1@news.povray.org>
"Severi Salminen" <sev### [at] NOT_THISsibafi> wrote in message
news:3ff8aff4@news.povray.org...
> Can I fetch system time anyhow in Windows version of POV-Ray? I have a
> clock in my scene and I'd like it to show the start of rendering but I
> have to do it manually now :)

I had posted a file here at the povray newsgroups years ago... found it:

http://news.povray.org/povray.binaries.scene-files/14604/

If you haven't been to the web-based newsgroups yet you'll need to set it up
first before going in.

-- 
Bob H.
http://www.3digitaleyes.com


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: Can POV SDL read system time?
Date: 23 Apr 2004 19:30:52
Message: <4089a72c@news.povray.org>
I saw (I don't remember where) that this will be available in future versions of
POV-Ray.

Reading system clock would be also useful in sunpos.inc (that returns the
position of the sun, for a given date, time, and location on earth). It would be
useful to use actual time rather than changing parameters on each render
(briefly, I have the same problem as you).


news:3ff8aff4@news.povray.org...
> Can I fetch system time anyhow in Windows version of POV-Ray? I have a
> clock in my scene and I'd like it to show the start of rendering but I
> have to do it manually now :)
>
> Severi S.


Post a reply to this message

From: Mike Williams
Subject: Re: Can POV SDL read system time?
Date: 24 Apr 2004 04:45:26
Message: <fk4LXAAUjiiAFwqB@econym.demon.co.uk>
Wasn't it Nicolas Alvarez who wrote:
>I saw (I don't remember where) that this will be available in future versions of
>POV-Ray.
>
>Reading system clock would be also useful in sunpos.inc (that returns the
>position of the sun, for a given date, time, and location on earth). It would be
>useful to use actual time rather than changing parameters on each render
>(briefly, I have the same problem as you).

The date() facility is available in the unofficial MegaPOV. This returns
various components of the date and time as a string. If you need to
perform arithmetic on the date/time information, then you'll need to
convert the individual components to floats, something like this:

#version unofficial megapov 1.0;        // Needed for date()

#include "strings.inc"                  // Needed for Parse_String

#declare Hours = date("%H");            // Get time component strings
#declare Mins  = date("%M");
#declare Secs  = date("%S");

#declare H = Parse_String(Hours);       // Convert strings to floats
#declare M = Parse_String(Mins);
#declare S = Parse_String(Secs);

-- 
Mike Williams
Gentleman of Leisure


Post a reply to this message

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