[Bf-committers] Re:Yafray exec fails on OSX

car bf-committers@blender.org
Thu, 29 Jan 2004 09:14:54 -0500


I know it is not an answer Ton, But this Yafray export script does send 
the file straight to a render.
It has always worked for me. Maybe you can take something out of it and 
make Yafray work now.

http://www.gvc.net/~jmatthews/extractor/index.php


On Jan 29, 2004, at 6:00 AM, bf-committers-request@blender.org wrote:

> Hi,
>
> The code as is now in yafray/intern/export_File.cpp doesn't work on
> OSX. The weird thing is that it behaves different when you try 'Render'
> a 2nd time. Then it clearly starts yafray up to the rendering phase,
> giving progress print ending with:
>
> [############............................] first render pass
>
> (I call blender from Terminal, with
> /blender.app/Contents/MacOS/blender -p 200 200 800 700)
>
> With help from Zr, I tried the more 'official' unix method for this,
> using fork() and execv().
>
> pid= fork();
> if(pid==0) {	// child process
> 	char *args[5];
> 	args[0]= "/usr/local/bin/yafray";
> 	args[1] = "-c";
> 	args[2]="0";
> 	args[3]="/tmp/YBtest.xml";
> 	args[4]= NULL;
> 	execv(args[0], args);
> }
> else {
> 	waitpid(pid, &res, 0);
> }
>
> This doesn't work either.
>
> Calling yafray from commandline works OK:
>> /usr/local/bin/yafray -c 0 "/tmp/YBtest.xml"
>
> Starting Blender with Finder makes no difference.
>
> I am clueless!
>
> -Ton-
>