POV-Ray : Newsgroups : povray.animations : POV Seems to Parse Everything for Every Frame Server Time
23 Nov 2024 21:46:45 EST (-0500)
  POV Seems to Parse Everything for Every Frame (Message 1 to 7 of 7)  
From: Bret
Subject: POV Seems to Parse Everything for Every Frame
Date: 13 May 2004 19:20:01
Message: <web.40a4021df8bc680b6ea6436d0@news.povray.org>
I'm currently running an animation that (so far) has taken 23 hours to parse
and 1.5 hours to render.  It seems to be parsing everything for every
frame.  Is there anyway to convince POV to just read the files in once?


Post a reply to this message

From: Warp
Subject: Re: POV Seems to Parse Everything for Every Frame
Date: 13 May 2004 19:25:07
Message: <40a403d2@news.povray.org>
Bret <nomail@nomail> wrote:
> I'm currently running an animation that (so far) has taken 23 hours to parse
> and 1.5 hours to render.  It seems to be parsing everything for every
> frame.  Is there anyway to convince POV to just read the files in once?

  Nope.

  At least the old MegaPOV has persistent variables which could be used
for this purpose, so you should take a look at that.

-- 
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -


Post a reply to this message

From: ABX
Subject: Re: POV Seems to Parse Everything for Every Frame
Date: 14 May 2004 03:55:08
Message: <1ju8a05k3mbhopkl24ulu2396kfmkhk75o@4ax.com>
On Thu, 13 May 2004 19:17:49 EDT, "Bret" <nomail@nomail> wrote:
> I'm currently running an animation that (so far) has taken 23 hours to parse
> and 1.5 hours to render.  It seems to be parsing everything for every
> frame.  Is there anyway to convince POV to just read the files in once?

Not in general, but it's possible that you can prepare your data for renderer
yourself. Does parsing mean reading file with pure objects (large meshes,
unions of objects etc, etc) or is there some programming like conditions,
loops, macros ? If yes you can think about rewriting your scene generation
from POV-SDL to some other language which can make it better. Specific
solution depends on your programming experience and content of your scene.

There are also other technics which can work in your case like ignoring
objects which are outside of visible space, variation of details depending on
distance to camera, etc, etc.

ABX


Post a reply to this message

From: Mike Williams
Subject: Re: POV Seems to Parse Everything for Every Frame
Date: 14 May 2004 16:12:00
Message: <lGflvBAlZQpAFwWk@econym.demon.co.uk>
Wasn't it Bret who wrote:
>I'm currently running an animation that (so far) has taken 23 hours to parse
>and 1.5 hours to render.  It seems to be parsing everything for every
>frame.  Is there anyway to convince POV to just read the files in once?

If it's taking that long to parse, then I guess that you're doing an
awful lot of actual calculation in your POV code. You might consider
performing these calculations only in the first frame, writing the
calculated data out to a file, and coding subsequent frames to read the
file instead of repeating the calculations.

#if (frame_number = initial_frame) 
  . . . do the calculations
  #fopen F "temporary.dat" write
  #write(. . .)
  #fclose F
#else
  // don't do the calculations
  #fopen F "temporary.dat" read
  #read(. . .)
  #fclose F
#end

-- 
Mike Williams
Gentleman of Leisure


Post a reply to this message

From: Bret
Subject: Re: POV Seems to Parse Everything for Every Frame
Date: 14 May 2004 18:55:00
Message: <web.40a54d29f7ca22606ea6436d0@news.povray.org>
ABX <abx### [at] abxartpl> wrote:
> On Thu, 13 May 2004 19:17:49 EDT, "Bret" <nomail@nomail> wrote:
> > I'm currently running an animation that (so far) has taken 23 hours to parse
> > and 1.5 hours to render.  It seems to be parsing everything for every
> > frame.  Is there anyway to convince POV to just read the files in once?
>
> Not in general, but it's possible that you can prepare your data for renderer
> yourself. Does parsing mean reading file with pure objects (large meshes,
> unions of objects etc, etc) or is there some programming like conditions,
> loops, macros ? If yes you can think about rewriting your scene generation
> from POV-SDL to some other language which can make it better. Specific
> solution depends on your programming experience and content of your scene.
>
> There are also other technics which can work in your case like ignoring
> objects which are outside of visible space, variation of details depending on
> distance to camera, etc, etc.
>
> ABX
The input .pov files are almost exclusively enormous meshes.  It's a grove
of orange trees based on real trees with 50,000 to 100,000 leaves each (not
to mention thousands of branches and oranges).

If I convert the meshes to mesh2's would that help significantly?


Post a reply to this message

From: Warp
Subject: Re: POV Seems to Parse Everything for Every Frame
Date: 14 May 2004 21:54:12
Message: <40a57844@news.povray.org>
Bret <nomail@nomail> wrote:
> If I convert the meshes to mesh2's would that help significantly?

  Yes.

-- 
#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}//  - Warp -


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: POV Seems to Parse Everything for Every Frame
Date: 3 Jun 2004 19:08:01
Message: <40bfaf51@news.povray.org>

news:lGf### [at] econymdemoncouk...
> Wasn't it Bret who wrote:
> >I'm currently running an animation that (so far) has taken 23 hours to parse
> >and 1.5 hours to render.  It seems to be parsing everything for every
> >frame.  Is there anyway to convince POV to just read the files in once?
>
> If it's taking that long to parse, then I guess that you're doing an
> awful lot of actual calculation in your POV code. You might consider
> performing these calculations only in the first frame, writing the
> calculated data out to a file, and coding subsequent frames to read the
> file instead of repeating the calculations.
>
> #if (frame_number = initial_frame)
>   . . . do the calculations
>   #fopen F "temporary.dat" write
>   #write(. . .)
>   #fclose F
> #else
>   // don't do the calculations
>   #fopen F "temporary.dat" read
>   #read(. . .)
>   #fclose F
> #end
>
> --
> Mike Williams
> Gentleman of Leisure

Another way to do that:

#if (frame_number = initial_frame)
    . . . do the calculations
    #fopen F "temporary.inc" write
    #write(. . .) //in pov's format
    #fclose F
#end
#include "temporary.inc"


...


Post a reply to this message

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