POV-Ray : Newsgroups : povray.general : IO restrictions when calling POV-Ray from .Net : IO restrictions when calling POV-Ray from .Net Server Time
26 Apr 2024 02:31:01 EDT (-0400)
  IO restrictions when calling POV-Ray from .Net  
From: Cypherspaceman
Date: 18 Nov 2016 08:45:00
Message: <web.582f04a1eccad996e7ad11040@news.povray.org>
Hi,

I'm creating a text file in POV, which works fine when I run from within the
Windows IDE.

When I try to call from c#, the render happens correctly, but the file is not
written to. The text file is in the same directory as the pov source file. Are
there any differences in IO restrictions when running from the IDE and being
called by an external program (effectively a command line call).




c# code:

System.Diagnostics.Process.Start(@"C:\Program
Files\POV-Ray\v3.7\bin\pvengine.exe", " \"" + @"B:\My
Pictures\POV\source\StructureSensor.pov" + "\" " + "/EXIT");




POV-Ray Code ("StructureSensor.pov")

#version 3.7;
text { ttf "arial.ttf", datetime(now), 0.02, 0.0  pigment{ color rgb<1,1,1> }
translate <-5,0,10>}
#fopen MyFile "depth.txt" write
#write (MyFile,datetime(now))
#fclose MyFile



pvengine.ini

[Permitted Output Paths]
1=%PROFILEDIR%\Insert Menu
2="B:\My Pictures\POV\source"





Running from the IDE, the datetime shown in the image is the same as that shown
in depth.txt.
Running the c# code rerenders the image with the current time, but does not
update the text file.

Any thoughts would be appreciated.

Thanks on advance.


Post a reply to this message

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