POV-Ray : Newsgroups : povray.programming : CONNECTING POVRAY WITH DELPHI Server Time
3 Jul 2024 05:48:30 EDT (-0400)
  CONNECTING POVRAY WITH DELPHI (Message 1 to 5 of 5)  
From: ilker yigit
Subject: CONNECTING POVRAY WITH DELPHI
Date: 26 Sep 2003 04:59:06
Message: <3f73ffda@news.povray.org>
We are trying to connect povray just like moray and do our renderings
with it. Can you help about this. Especially we are interested in how to
send commands and data to povray. How to communicate with pov dlls(Start
render. Get result. Get percentage of render. etc)
    If you can send us some examples related we will be gratefull.

best regards,


Post a reply to this message

From: ABX
Subject: Re: CONNECTING POVRAY WITH DELPHI
Date: 26 Sep 2003 05:40:21
Message: <i628nvcc9tbpm9dbd9k2ils1celf8qudgk@4ax.com>
On Fri, 26 Sep 2003 11:56:05 +0300, "ilker yigit" <ilk### [at] 2noktacom>
wrote:
>    We are trying to connect povray just like moray and do our renderings
> with it. Can you help about this. Especially we are interested in how to
> send commands and data to povray. How to communicate with pov dlls(Start
> render. Get result. Get percentage of render. etc)
>    If you can send us some examples related we will be gratefull.

http://www.imp.org/guiext/cookbook.asp
http://throwable.com/dreampeach/html/quietpov.html

ABX


Post a reply to this message

From: ilker yigit
Subject: Re: CONNECTING POVRAY WITH DELPHI
Date: 26 Sep 2003 10:13:18
Message: <3f74497e@news.povray.org>
I am try the GuiDemo (delphi version) and its success loaded povray.
But how to access another program to my gui extension ?




"ABX" <abx### [at] abxartpl> wrote in message
news:i628nvcc9tbpm9dbd9k2ils1celf8qudgk@4ax.com...
> On Fri, 26 Sep 2003 11:56:05 +0300, "ilker yigit" <ilk### [at] 2noktacom>
> wrote:
> >    We are trying to connect povray just like moray and do our renderings
> > with it. Can you help about this. Especially we are interested in how to
> > send commands and data to povray. How to communicate with pov dlls(Start
> > render. Get result. Get percentage of render. etc)
> >    If you can send us some examples related we will be gratefull.
>
> http://www.imp.org/guiext/cookbook.asp
> http://throwable.com/dreampeach/html/quietpov.html
>
> ABX


Post a reply to this message

From: ABX
Subject: Re: CONNECTING POVRAY WITH DELPHI
Date: 26 Sep 2003 10:26:19
Message: <30j8nv80memc37aoo7q1gm5la9b31a1ld3@4ax.com>
On Fri, 26 Sep 2003 17:10:11 +0300, "ilker yigit" <ilk### [at] 2noktacom>
wrote:
> I am try the GuiDemo (delphi version) and its success loaded povray.
> But how to access another program to my gui extension ?

I do not know much but isn't it what QuietPOV does? Check its sources.

ABX


Post a reply to this message

From: Chuck S 
Subject: Re: CONNECTING POVRAY WITH DELPHI
Date: 26 Sep 2003 16:16:42
Message: <3f749eaa$1@news.povray.org>
ilker yigit wrote:

>     We are trying to connect povray just like moray and do our renderings
> with it. Can you help about this. Especially we are interested in how to
> send commands and data to povray. How to communicate with pov dlls(Start
> render. Get result. Get percentage of render. etc)
>     If you can send us some examples related we will be gratefull.

Here is how I do it. 

- I made a POV file to display a preview scene. My external program is a texture
editor so I apply my texture to the object in the preview scene. I wrote my texture to
a .INC file before doing this. 
gPrefs.POVBin contains the path to pvengine.exe, such as "c:\povray\bin\pvengine.exe".

- Then I call POV with 
if ShellExecAndWait(gPrefs.POVBin, ' scene.ini', '',SW_HIDE)=false then
//if ShellExecAndWait(gPrefs.POVBin, ' +Iscene.pov', '',SW_HIDE)=false then
//if ShellExecEx(gPrefs.POVBin, ' scene.ini','',l)=False then
    begin
    Showmessage('Error after ShellExecAndWait running POV for preview.');
    Screen.cursor:=crDefault;
    exit;
    end;

Note how I call pov with an INI file in the command line. Do not call POV with the POV
file in the command line. 

Also note, ShellExecAndWait does not seem to wait for POV to finish before returning
to my program. I have been trying to fix this for 2 years but have gotten nowhere. 

Basically, if ShellExecAndWait worked properly on my Win2000 system then I wouldn't
care about the percent that the image is rendered. I just wait until POV is done, then
I load my preview image into my program's image box. 

My other problem is POV always becomes the top window. I don't want that, I just want
it to run in the background, then return to my program when it's done making the
image. 
The SW_HIDE is supposed to hide the POV window when it is running.

-- 
Freezone Freeware and Free Delphi Components
http://freezone.darksoft.co.nz http://chuckr.bravepages.com
http://www.bdsg.com/resources


Post a reply to this message

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