POV-Ray : Newsgroups : povray.binaries.images : #read: why is the second variable undeclared? : #read: why is the second variable undeclared? Server Time
31 Jul 2024 04:20:50 EDT (-0400)
  #read: why is the second variable undeclared?  
From: Jörg 'Yadgar' Bleimann
Date: 21 Apr 2010 11:05:48
Message: <4bcf144c$1@news.povray.org>
High!

As rendering Ghurghusht scenes using an isosurface for the planetary 
terrain, I decided to use meshes generated from it in the future. First, 
I have to find out most accurately the minimum and maximum elevations of 
the isosurface terrain by probing altitude with trace(). To get a really 
accurate representation, I divided the whole surface in 2592 (72 by 36) 
tiles, each covering 5 x 5 degrees by 1800 x 1800 pixels (o.k., each 
tile takes about 40 minutes, so the whole probing and afterwards, the 
creation of heightfields would be done after eight months, assuming that 
the computer runs 14 hours/day on average - but I hope this effort will 
pay off later when rendering surface animations!). While running through 
them using the clock variable, after each "frame" the current minimum 
and maximum values are stored in a tiny ASCII file just conisting of 
these two values separated by a tab.

Here is the code for the read routine:

       #fopen mm "minmax" read
       #while (defined(mm))
         #read (mm, min_file, max_file)
       #end
       #fclose mm
       #declare min_el=min_file;
       #declare max_el=max_file;

...but now I always get the error message "Cannot assign uninitialized 
identifier." Why? According to the manual, it's legal to read more than 
one variable from an ASCII file...

See you in Khyberspace!

Yadgar


Post a reply to this message

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