POV-Ray : Newsgroups : povray.programming : How to define a global fstream object? Server Time
23 Dec 2024 06:58:16 EST (-0500)
  How to define a global fstream object? (Message 1 to 2 of 2)  
From: Wu Yang
Subject: How to define a global fstream object?
Date: 8 Dec 2002 01:29:19
Message: <3df2e6bf@news.povray.org>
Hi, all
   I tried to output all the intersection points to a file. What I do is
defining a fstream object in Trace_Primary_Ray() function in vbuffer.cpp
file. It is too slow. I tried to define a global fstream object, but it can
not be compiled. Can I define a global fstream object? Thanks

Wu Yang


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: How to define a global fstream object?
Date: 8 Dec 2002 05:38:39
Message: <3df3212f@news.povray.org>
In article <3df2e6bf@news.povray.org> , "Wu Yang" <wya### [at] cswrightedu> 
wrote:

>    I tried to output all the intersection points to a file. What I do is
> defining a fstream object in Trace_Primary_Ray() function in vbuffer.cpp
> file. It is too slow. I tried to define a global fstream object, but it can
> not be compiled. Can I define a global fstream object? Thanks

Get a good "Introduction to C++" book in your campus bookstore.  The US$70
it will cost you will, after you read and understood it, cut your the time
you send on figuring something like this out to 1/10.  So it is surely worth
the money.

If you don't know how to do create global variables it will just be
impossible to explain it to you because it is impossible to assume you know
anything about what to do and one would have to write a book to explain it
in the first place.  So you buying the book it really the better alternative
for everybody.

    Thorsten


Post a reply to this message

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