Yafaray4tS v0.9.0

LightWorks, VRay, Dribble, YafaRay and more..
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

With the included YafaRay4tS scene I just did a test and changed to color for both Spot lights, 140 140 140. Does not seem to change the render so much but that is pretty close to what tS looked like before. Less bright.

Just noticed the several lights are still messed up. I will fix it with the next update.
I guess my changes did not get saved. Errrrr

With the Yaf Sphere light and Yaf Point light, does the Sphere mesh's attribute need to be exported and does the size matter?
Size is connected to the color multiplier too, is that necessary?
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 13 Jun 2018, 01:06 With the included YafaRay4tS scene I just did a test and changed to color for both Spot lights, 140 140 140. Does not seem to change the render so much but that is pretty close to what tS looked like before. Less bright.

Just noticed the several lights are still messed up. I will fix it with the next update.
I guess my changes did not get saved. Errrrr

With the Yaf Sphere light and Yaf Point light, does the Sphere mesh's attribute need to be exported and does the size matter?
Size is connected to the color multiplier too, is that necessary?
I dont see any included YafaRay4tS scene. Where do I find it.
All tS lights, not just Yaf lights have their mesh exported.
Size of the sphere light is used in the render.
Don't know about the size connection to the color multiplier. I can only image it's there for a reason. Bigger==Brighter? If so then it needs to be connected to reflect the changes in the preview. Only way to tell is if you do some renders with different values and see if it's needed or not.
The mesh of the sphere is written to the renderer to make the light visible. It's an option in Blender. In tS it always makes a mesh.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

BlenderSphereLight.jpg
Shot from Blender sphere light.
I will be adding an option to the light for exporting the mesh or not after you get the update squared away with the lost changes etc.

Edit: My mistake, there is already an option to render the mesh or not.

Edit: Did some test renders and it does get brighter when it gets bigger.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

I know the mesh is exported as an output. I was referring to Latitude, Longitude, and Size that are exported out as inputs. I will not mess with the Sphere light. I was wanting to change the Point light's shape though. It is not hooked up to anything except like mentioned above. Makes no sense that they are of any value other letting a user change it's size. But I am not sure.
I have fixed the Light's matrix values.
Also changed the Shapes for the Sun, Directional, IES Spot, and Spot. Same as the new tS lights.


The scene should be in the YafaRay4tS Setup library
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

I'm setting up a web page for the samples scenes. Has temp content now.

http://clintons3d.com/plugins/truespace ... faray.html
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 13 Jun 2018, 02:52 I know the mesh is exported as an output. I was referring to Latitude, Longitude, and Size that are exported out as inputs. I will not mess with the Sphere light. I was wanting to change the Point light's shape though. It is not hooked up to anything except like mentioned above. Makes no sense that they are of any value other letting a user change it's size. But I am not sure.
I have fixed the Light's matrix values.
Also changed the Shapes for the Sun, Directional, IES Spot, and Spot. Same as the new tS lights.


The scene should be in the YafaRay4tS Setup library
Ok I see it.
Did you change the mesh for the area light? If so the export will need to be redone to match it.

Edit: Yafaray doesn't care about the point light mesh or mesh inputs. So you can do whatever you want to it's shape.
Last edited by clintonman on 13 Jun 2018, 03:06, edited 1 time in total.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

No.
Edit: Okay Ill upload the changes in a few.
Edit2: Just so you know incase you want to advise users that they may have to change the settings in Setup.
All three scenes are same absorbscatter.
Attachments
Capture.PNG
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Update v5
viewtopic.php?t=5446&p=52492#p52492
Dam! Forgot to save the lights in the Library. Edit: Fixed and uploaded again.
Lights in the primitives are good to go.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

Web page has temporary content until the next release with the new lights etc.
2 changes required by users is change yararay folder and render location. will be sure to note it.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Just realized I did not save the scene and ight setup with the new lights.
Basically they are just missing the new mesh for the spot lights.
User avatar
the_ant
Chief Petty Officer
Posts: 155
Joined: 02 Jun 2009, 09:26
Type the number ten into the box: 0
Location: Perugia - Italy

Re: Yafaray4tS v0.9.0

Post by the_ant »

Help me!...little confuse in the maze of upgrades...how can i set tsp761 with UnoffUpg by TrueBlue within vRay and YafaRay last functions ? :roll: :bananatyping:
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Just noticed two things with the Update v5
Yafaray scene and light setup.
The first spot light is messed up, not sure why that happened. Still investigating why.
The Material Editor was saved with Vray enabled. That is fixed. Not released yet.
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

the_ant wrote: 13 Jun 2018, 14:51 Help me!...little confuse in the maze of upgrades...how can i set tsp761 with UnoffUpg by TrueBlue within vRay and YafaRay last functions ? :roll: :bananatyping:
As for the Unofficial Update 4, I would wait until it is released with the YafaRay4tS. I will post when it is ready and upload it here :
viewforum.php?f=55
User avatar
the_ant
Chief Petty Officer
Posts: 155
Joined: 02 Jun 2009, 09:26
Type the number ten into the box: 0
Location: Perugia - Italy

Re: Yafaray4tS v0.9.0

Post by the_ant »

Thanks treuBlue...i'll wait for that.. :worship: :bananahi:
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Misc aspect - Restore Defaults
Changes Yafaray install path to:
C:\Program Files\YafaRay\yafaray-xml.exe
Up to you, but my thought is to not change that as it creates an Alert "Unable to find YafaRay. Is it installed?"
Or change it to the Standalone path?
C:\Program Files\yafaray_v3\bin\yafaray-xml.exe


Kind of a pain to always have to change that path with old scenes etc...
To the left of the insatll path is a > text control "Yaf_Path", if you right click it select Reset does the same thing as above.
Could make that a Bitmap Button Control - LMB = Standalone path / RMB = Blender path

Or add a Combo Control underneath
Capture.PNG
Capture.PNG (16.22 KiB) Viewed 5098 times
Your Update YafaRay Render Node script
The Alert reads:
System.Alert("Conversion to YafaRay4tS v0.8.0 complete.");
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Yafaray toolbar - Yafaray Settings
This is not working for me and I remember bringing this up before.
It looks like a Watch Dog problem.
When I select the above icon it does not run:

Code: Select all

Activity.Run(Space.CurrentScene() + "/YafaRay4tS/Lighting Method Switch")
portion of the command.

Wondering if it would be better to run:

Code: Select all

UserInterface.OpenToolPanelViewEx2("" , "" ,Space.CurrentScene()+"/YafaRay4tS", 10, 1, 0);
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

I have made these changes if you are interested:

YafaRay4tS panel
Yaf_Path - Additional Combo Control for entering Blender and Standalone paths.

Libraries
Added version "Y4tSv.0.9.0" to the library Discriptions for all nodes.
YafaRay4tS scene and light setup - Changed the Spot light's color to 140 140 140

Update YafaRay Render Node script
Changed the Alert to "Conversion to YafaRay4tS v0.9.0 complete."
Incorporated it into a Popup.

Render node
Changed defauts:
params.Param('vtData') = "C:" + "\\" + "Program Files" + "\\" + "yafaray_v3" + "\\" + "bin" + "\\" + "yafaray-xml.exe";
params.Param('vtData') = "C:" + "\\" + "Temp" + "\\" + "yaf_test.png";

Lighting Method Switch
Disconnecting/Reset the 'Change detect'/Reconnecting the Watch Dog before saving the Yafaray Folder seems to help.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 13 Jun 2018, 19:14 Yafaray toolbar - Yafaray Settings
This is not working for me and I remember bringing this up before.
It looks like a Watch Dog problem.
When I select the above icon it does not run:

Code: Select all

Activity.Run(Space.CurrentScene() + "/YafaRay4tS/Lighting Method Switch")
portion of the command.

Wondering if it would be better to run:

Code: Select all

UserInterface.OpenToolPanelViewEx2("" , "" ,Space.CurrentScene()+"/YafaRay4tS", 10, 1, 0);
Like you said the problem is the watchdog. The script that gets called does run the Userinterface... command.
I think the easiest solution is to have an extra button to push for when it gets stuck. The button would just run the command directly or actually maybe better to run the watchdog which would "wake it up" for future use.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

I think the yafaray and render paths should not have a default value. There is no installer for Yafaray so it can potentially be anywhere. even Blender comes with installer and not installer options so can't depend on the blender scripts location either.

The sharing of scenes is a pain. I think add a button that will read the render path and yafaray path from the saved yafaray4ts node would make it easier.

For rendering maybe we have it default to a folder inside truespace if the path is blank or does not exist.

another option maybe read some kind of path from the registry.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 13 Jun 2018, 21:37
trueBlue wrote: 13 Jun 2018, 19:14 Yafaray toolbar - Yafaray Settings
This is not working for me and I remember bringing this up before.
It looks like a Watch Dog problem.
When I select the above icon it does not run:

Code: Select all

Activity.Run(Space.CurrentScene() + "/YafaRay4tS/Lighting Method Switch")
portion of the command.

Wondering if it would be better to run:

Code: Select all

UserInterface.OpenToolPanelViewEx2("" , "" ,Space.CurrentScene()+"/YafaRay4tS", 10, 1, 0);
Like you said the problem is the watchdog. The script that gets called does run the Userinterface... command.
I think the easiest solution is to have an extra button to push for when it gets stuck. The button would just run the command directly or actually maybe better to run the watchdog which would "wake it up" for future use.
Lighting Method Switch
Disconnecting/Reset the 'Change detect'/Reconnecting the Watch Dog before saving the Yafaray Folder seems to help.
I have tested this several times today by Reseting the Context after performing the above. So far it works everytime.
You know best, so whatever you decide. Not working sometimes is not good.
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 13 Jun 2018, 21:51 I think the yafaray and render paths should not have a default value. There is no installer for Yafaray so it can potentially be anywhere. even Blender comes with installer and not installer options so can't depend on the blender scripts location either.

The sharing of scenes is a pain. I think add a button that will read the render path and yafaray path from the saved yafaray4ts node would make it easier.

For rendering maybe we have it default to a folder inside truespace if the path is blank or does not exist.

another option maybe read some kind of path from the registry.
Well as you know, presently it is set to a path from a previous version.
Folder inside tS sounds great. Easy to get to. One for Animation and one for Images. Even better would be like tS's Render to File

It is possible to create a Popup panel just like this.
Attachments
Capture.PNG
Capture.PNG (7.66 KiB) Viewed 4427 times
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 13 Jun 2018, 22:06 ...
Lighting Method Switch
Disconnecting/Reset the 'Change detect'/Reconnecting the Watch Dog before saving the Yafaray Folder seems to help.
I have tested this several times today by Reseting the Context after performing the above. So far it works everytime.
You know best, so whatever you decide. Not working sometimes is not good.
Watch dogs have given me troubles in the past but it looks like it effects you even more. Can you try this script to see if it switches the stubborn lighting model?
Also the script reads special folders for desktop and documents, maybe we default renders to the users documents, or use that path to get to the users pictures folder.
Attachments
some tests.RsObj
(5.52 KiB) Downloaded 221 times
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Did not know you could run the Watch Dog like that.
Your script works, but as said it has been working all morning since I saved the Yafaray Folder.
I see the paths in the Console too.
Personally I would not want save images or a sequence of images to those two paths.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 13 Jun 2018, 22:34 Did not know you could run the Watch Dog like that.
Your script works, but as said it has been working all morning since I saved the Yafaray Folder.
I see the paths in the Console too.
Personally I would not want save images or a sequence of images to those two paths.
It would be only as a default for blank or non-existent folder choice, but I agree a default somewhere inside the truespace install would be best.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 13 Jun 2018, 22:13
clintonman wrote: 13 Jun 2018, 21:51 I think the yafaray and render paths should not have a default value. There is no installer for Yafaray so it can potentially be anywhere. even Blender comes with installer and not installer options so can't depend on the blender scripts location either.

The sharing of scenes is a pain. I think add a button that will read the render path and yafaray path from the saved yafaray4ts node would make it easier.

For rendering maybe we have it default to a folder inside truespace if the path is blank or does not exist.

another option maybe read some kind of path from the registry.
Well as you know, presently it is set to a path from a previous version.
Folder inside tS sounds great. Easy to get to. One for Animation and one for Images. Even better would be like tS's Render to File

It is possible to create a Popup panel just like this.
That looks easier said than done. If you make a popup panel I'll link the renderer to it. We might be able to make it use the same values saved in the render to file except for the file extension. render to file bmp, dds, dib, pfm won't render with yafaray and yafaray exr, tga and tif wont work with render to file.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

As an example if possible, can you show me how to get a Folder path and enter it into the Folder attribute from a button script? Using your plugin or by other means. I see how you did in Yafaray but you are also getting the file + extension IE .tga. which is not what I was wanting to do.
Having a user to enter the path manually like \\Rs Main Libraries\\My Scene\\ is not very user friendly.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

One thing I should mention for your input. The render object button does not do anything since yafaray does not have a render object, it only renders scenes. So we have a free button to play with. This is only left click since the right click for all buttons is already defined as open render settings.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 13 Jun 2018, 22:53 As an example if possible, can you show me how to get a Folder path and enter it into the Folder attribute from a button script? Using your plugin or by other means. I see how you did in Yafaray but you are also getting the file + extension IE .tga. which is not what I was wanting to do.
Having a user to enter the path manually like \\Rs Main Libraries\\My Scene\\ is not very user friendly.
From http://clintons3d.com/plugins/truespace ... index.html

Code: Select all

pathdata = System.CreateDO("Clintons3D Package/Utility functions");
thedata = pathdata.GetFolderDialog();
System.Alert(thedata); 
It does require the plugin, but you already have it included.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Thanks I will give that a try.
Here is the beginning of the panel.
No attributes yet.
Should I do Input, Output, or both Yaf attributes?
Thought you could place this script inside the YafaRay4tS panel and call it like the Display is being called.
After thought but maybe I should used an Object instead of a Script
Thoughts?
Attachments
Capture.PNG
Capture.PNG (8.18 KiB) Viewed 4432 times
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 00:05 Thanks I will give that a try.
Here is the beginning of the panel.
No attributes yet.
Should I do Input, Output, or both Yaf attributes?
Thought you could place this script inside the YafaRay4tS panel and call it like the Display is being called.
After thought but maybe I should used an Object instead of a Script
Thoughts?
That looks good. "Should I do Input, Output, or both Yaf attributes?"
They should all be inputs. This node you create will live inside the yafaRay4tS node and it's inputs will be connected to the existing inputs. The Save Settings button will update the Yafaray4ts node values. The names and types on this new panel should match the existing names, like "Yaf_ResX" is the Width.

Your panel has an extra render button.

Do you plan to add the presets resolutions drop down list? If so it will need one more string input.

I think a script would be better so we could have the save settings code inside it.

I looked at the Display as you suggested and I think we can make it work the same.

Edit: The node will not be directly connected to the yafaray4ts node. When called it will copy the values from the yafaray4ts node and if save settings is pressed the values will be copied from the node to the yafaray4ts node.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Okay so...
Yaf attributes - Inputs
Render button's commands for the Image and Animation or different according to what you have now.
Wondering now if you need two file dialogs?

I was coping from the Render to File and the Yafaray panels for inspiration

I was thinking that Save Settings button, if you choose to do so, could be like the Render to File. Optional.
It's up to you with regards to the Presets.
Just let me know and or if this has any added value, as I am not sure.
I want to add the attributes all at one time, so need to know what's in and what's out first
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 01:10 Okay so...
Yaf attributes - Inputs
Render button's commands for the Image and Animation or different according to what you have now.

I was coping from the Render to File and the Yafaray panels for inspiration

I was thinking that Save Settings button, if you choose to do so, could be like the Render to File. Optional.
It's up to you with regards to the Presets.
Just let me know and or if this has any added value, as I am not sure.
OK, if you have 2 render buttons then you don't need the checkbox for "save sequence". Also if you keep the 2 buttons make the separation between still and animation sections more obvious so the 2 buttons don't get mixed up or change the wording on the buttons to make it more obvious, "Render Still", "Render Animation".
Thinking about the presets it would require a watchdog and some node to store the data all inside an encapsulating node that would have the controls, so maybe just skip it. I only mentioned it because it's in the Render to File dialog.
I'm having second thoughts about the Save Settings button. The renderer can only get the values from one place, so there should be no save settings button, because it would be mandatory to place the values on the yafaray4ts node before rendering.
How do you envision the save settings would work?
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Save Settings button writes to an xml file to save the Render to File setting's as I understand it.

Code: Select all

<?xml version="1.0" encoding="UTF-16" ?>
<D3DVIEW_RENDERTOFILE_SETTINGS>
    <!--  This file contains the configuration settings for Render To File tool in Player -->
    <D3DVIEW_RENDERTOFILE_CURRENT CHOSENPRESET="VGA 4:3 (1.33:1) - 640 x 480" WIDTH="500" HEIGHT="500" FILENAME="C:\Users\David A Egan\Desktop\Volume.png" SAVEINSEQUENCE="1" SEQUENCESTART="2" SAVEINANIMATION="0" ANIMATIONSTART="0" ANIMATIONEND="0" />
</D3DVIEW_RENDERTOFILE_SETTINGS>

Not necessary really and that would give me room for the Render Animation button.
Dam! Now you know how I created the Volume icon. ;)
Attachments
Capture.PNG
Capture.PNG (6.11 KiB) Viewed 4259 times
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

Looks good, just one more request. Can you make the panel wide to give plenty of room for the file name? It's a floating view so it doesn't have to skinny enough to fit in the panel view.

Edit:
One more question, what is "Shrink Play Range"? Does it do the same thing as "Set Range From Timeline" button?
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Shrink Play Range does the same thing as "Set Range From Timeline" button, as is my understanding.
Same as tS's Animation panel.
Should there be a separate file dialog for the Image?
Attachments
Capture.PNG
Capture.PNG (6.65 KiB) Viewed 4252 times
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 02:35 Shrink Play Range does the same thing as "Set Range From Timeline" button, as is my understanding.
Should there be a separate file dialog for the Image?
Ah, ok so it shrinks or grows depending on how you change the timeline.
It will work the same as the Render to File dialog, 1. choose image via file dialog, 2. press the render button.

Come to think of it, maybe this should just be another panel on the yafaray4ts and the panel opens as a floating window when you press the render button that exists on the other panels. The new panel would have to be at the end of the list of panels or the misc panel could be used with it's controls moved to the default panel.

I'll check to see if I can float the panel.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Set Range from Timeline

Code: Select all

s = RsAnimPref.PlayRangeStart;
e = RsAnimPref.PlayRangeEnd;
Node.Value("%THIS_NAME%" , "Start Frame") = s;
Node.Value("%THIS_NAME%", "Number Start") = s;
Node.Value("%THIS_NAME%", "End Frame") = e;
Shrink Play Range

Code: Select all

try
{
{
RsTime.AnimStart = RsTime.EvalAnimStart('')
RsTime.AnimEnd = RsTime.EvalAnimEnd('')
Node.Value("/Preferences/AnimPref", "PlayRangeStart") = Node.Value("/AnimMng", "AnimStart")
Node.Value("/Preferences/AnimPref", "PlayRangeEnd") = Node.Value("/AnimMng", "AnimEnd")
}

}
catch (e)
{
}
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Sounds like this is not helping and just becoming a duplication of what is already available on the YafaRay4tS panel.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 03:23 Set Range from Timeline

Code: Select all

s = RsAnimPref.PlayRangeStart;
e = RsAnimPref.PlayRangeEnd;
Node.Value("%THIS_NAME%" , "Start Frame") = s;
Node.Value("%THIS_NAME%", "Number Start") = s;
Node.Value("%THIS_NAME%", "End Frame") = e;
Shrink Play Range

Code: Select all

try
{
{
RsTime.AnimStart = RsTime.EvalAnimStart('')
RsTime.AnimEnd = RsTime.EvalAnimEnd('')
Node.Value("/Preferences/AnimPref", "PlayRangeStart") = Node.Value("/AnimMng", "AnimStart")
Node.Value("/Preferences/AnimPref", "PlayRangeEnd") = Node.Value("/AnimMng", "AnimEnd")
}

}
catch (e)
{
}
In that case we'll need both buttons, Set Range reads the anim prefs and shrink play sets the anim prefs.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

I got a yafaray4ts panel to display floating after some failed attempts and tS crashes.
Steps I took was:
1. drag yafaray4ts out of the panel view
2. copied the resulting window frame into the yafaray4ts node
3. added a script

Code: Select all

	if(Node.Exists("/Project/Windows Manager Space/YafarayRenderPanelFrame"))
		WindowsManager.CloseWindow("/Project/Windows Manager Space/YafarayRenderPanelFrame");

	Node.Value(System.ThisOwner() + "/YafarayRenderPanelFrame", "RootNode") = System.ThisOwner();
	Node.Value(System.ThisOwner() + "/YafarayRenderPanelFrame/Panel Node", "PanelEditorNode") = System.ThisOwner();

	var popup = Node.Copy(System.ThisOwner() + "/YafarayRenderPanelFrame", "/Project/Windows Manager Space");

	WindowsManager.Activate();
	WindowsManager.UpdateWindowsStructure();
 
	UserInterface.SetAspect(System.ThisOwner(), 15);
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

No, I was not suggesting that you add Shrink Play Range. I was just renaming your Set Range from Timeline to Shrink Play Range. Sorry for the confusion!
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 04:05 No, I was not suggesting that you add Shrink Play Range. I was just renaming your Set Range from Timeline to Shrink Play Range. Sorry for the confusion!
ah, ok. Still on a side note for the animation preferences panel I would rename it to something like "fit to keyframes" since it can either shrink or grow.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Well I just had an experience that was not to pleasant.
Curiously I wondered if YafaRay4tS 0.9.0 was using the tS Render Animation icon.
So I selected it, and it starting rendering 300 images and xml files.
Mind you this was with the default YafaRay4tS settings and the defaults in the Animation Editor.
Could not stop it by selecting the Escape key.
ts crashed at 239 files.
Yikes! :o
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 13:57 Well I just had an experience that was not to pleasant.
Curiously I wondered if YafaRay4tS 0.9.0 was using the tS Render Animation icon.
So I selected it, and it starting rendering 300 images and xml files.
Mind you this was with the default YafaRay4tS settings and the defaults in the Animation Editor.
Could not stop it by selecting the Escape key.
ts crashed at 239 files.
Yikes! :o
Yep, that's pretty serious oversight. I see a function for user cancel that never gets called.
On the other point are you saying that the default YafaRay4tS settings and the defaults in the Animation Editor need to be different?
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 14 Jun 2018, 14:11
trueBlue wrote: 14 Jun 2018, 13:57 Well I just had an experience that was not to pleasant.
Curiously I wondered if YafaRay4tS 0.9.0 was using the tS Render Animation icon.
So I selected it, and it starting rendering 300 images and xml files.
Mind you this was with the default YafaRay4tS settings and the defaults in the Animation Editor.
Could not stop it by selecting the Escape key.
ts crashed at 239 files.
Yikes! :o
Yep, that's pretty serious oversight. I see a function for user cancel that never gets called.
On the other point are you saying that the default YafaRay4tS settings and the defaults in the Animation Editor need to be different?
Maybe not the Animation Editor as that can change by the user.
Not sure about the defaults for animation, certainly you will want the tS Render Animation icon to work.
Can anything be done with your plugin? Like maybe calling the Render to File that we were contemplating?
Definantly do not think that the xml files are needed for animation.
Not sure what Vray does or does not do, presently do not have it installed.
Edit:
This is what happens in Vray
Using Vray's render display's toolbar:
Vray save from render window toolbar.PNG
Using tS Render Animation icon:
Vray Render Animation.PNG
Note that it reads the timeline, as I changed it from the default 300 to 10
And the render is paused, from what I can tell by the white background.
Seems Vray is using Render to File. Guessing.
This is from the Vray log after canceling the Render Animation:

Code: Select all

LOG: Player Anim Vray Rendering, CRcVrayRenderRAnim::Execute(197)
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Uploaded a new version:
viewtopic.php?t=5446&start=70#p52492
Edit6:
tS7.61B8.4_YafaRay4tS9_6

YafaRay4tS panel
Animation - Added Width and Height

Libraries
Added version "Y4tSv.0.9.0" to the library Descriptions for all nodes.
YafaRay4tS scene and light setup - Changed the Spot light's color to 140 140 140

Update YafaRay Render Node script
Changed the Alert to "Conversion to YafaRay4tS v0.9.0 complete."
Incorporated it into a Popup.

Render node
Changed defauts:
params.Param('vtData') = "C:" + "\\" + "Program Files" + "\\" + "yafaray_v3" + "\\" + "bin" + "\\" + "yafaray-xml.exe";
params.Param('vtData') = "C:" + "\\" + "Temp" + "\\" + "yaf_test.png";

Lighting Method Switch
Disconnecting/Reset the 'Change detect'/Reconnecting the Watch Dog before saving the Yafaray Folder seems to help.

Update tS7.61B8.4:
Add Render Scene icon to the Material Editor.
Changed loading the Tube object to a primitive. Only for loading, does not work like other widgets.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 14:38 ...
Can anything be done with your plugin? Like maybe calling the Render to File that we were contemplating?
...
No, can't do that. Would require a knowledge of c++ and windows dialogs that I don't have and no way to hijack a dialog for own use.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Ouch, this must be disheartening!
Only thing I can think of is do something similar that I did with the Offline Render icons for Vray.
In CustomCommands you find RenderAnimation.xml

Code: Select all

function Execute(params)
{
if (Node.Exists(Space.CurrentScene() + "/Vray"))
{
Width = Node.Value(Space.CurrentScene() + "/Vray", "Image Width")
Height = Node.Value(Space.CurrentScene() + "/Vray", "Image Height")
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 1/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 1", -1, -1, Width, Height, -1, -1, -1)
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 2/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 2", -1, -1, Width, Height, -1, -1, -1)
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 3/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 3", -1, -1, Width, Height, -1, -1, -1)
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 4/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 4", -1, -1, Width, Height, -1, -1, -1)
}
OfflineRender.RenderAnimation('')
}
Edit that file in Notepad outside of tS and Save it. Reset tS.
Do something like, if Yafaray render node exist, Call your Render Animation code or the Render to File panel that we are contemplating. Some how stop the OfflineRender.RenderAnimation('')
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 13 Jun 2018, 23:01
trueBlue wrote: 13 Jun 2018, 22:53 As an example if possible, can you show me how to get a Folder path and enter it into the Folder attribute from a button script? Using your plugin or by other means. I see how you did in Yafaray but you are also getting the file + extension IE .tga. which is not what I was wanting to do.
Having a user to enter the path manually like \\Rs Main Libraries\\My Scene\\ is not very user friendly.
From http://clintons3d.com/plugins/truespace ... index.html

Code: Select all

pathdata = System.CreateDO("Clintons3D Package/Utility functions");
thedata = pathdata.GetFolderDialog();
System.Alert(thedata); 
It does require the plugin, but you already have it included.
Thanks again! I getting closer but can not figure out how to add a backslash between the Folder path and the File

Code: Select all

//Button script
Dialog = System.CreateDO("Clintons3D Package/Utility functions");
GetFolder = Dialog.GetFolderDialog();
Node.Value('%THIS_NAME%', 'Folder') = GetFolder
 
//My script
Space.SaveScene( Folder + Scene_Name + Increment + '.RsScn');
//Folder attribute value
//C:\trueSpace761\tS\Rs Main Libraries\My SceneMy  Scene2.RsScn
// Missing a back slash and possibly an additional space

// Trying this throws a tS error
Space.SaveScene( Folder + "\" + Scene_Name + Increment + '.RsScn');

// Trying this does not throw an error but adds two quotes
Space.SaveScene( Folder + '"\"' + Scene_Name + Increment + '.RsScn');
//Folder attribute value
//C:\trueSpace761\tS\Rs Main Libraries\My SceneMy "" Scene2.RsScn
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 17:28 Ouch, this must be disheartening!
Only thing I can think of is do something similar that I did with the Offline Render icons for Vray.
In CustomCommands you find RenderAnimation.xml
...
Edit that file in Notepad outside of tS and Save it. Reset tS.
Do something like, if Yafaray render node exist, Call your Render Animation code or the Render to File panel that we are contemplating. Some how stop the OfflineRender.RenderAnimation('')
Actually we change the offline render buttons to do the same as the other buttons 1. open panel with render settings 2. press the render button to start
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

Try using double backslash
Space.SaveScene( Folder + '"\"' + Scene_Name + Increment + '.RsScn');
Space.SaveScene( Folder + '"\\"' + Scene_Name + Increment + '.RsScn');
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 14 Jun 2018, 17:56
trueBlue wrote: 14 Jun 2018, 17:28 Ouch, this must be disheartening!
Only thing I can think of is do something similar that I did with the Offline Render icons for Vray.
In CustomCommands you find RenderAnimation.xml
...
Edit that file in Notepad outside of tS and Save it. Reset tS.
Do something like, if Yafaray render node exist, Call your Render Animation code or the Render to File panel that we are contemplating. Some how stop the OfflineRender.RenderAnimation('')
Actually we change the offline render buttons to do the same as the other buttons 1. open panel with render settings 2. press the render button to start
Are you talking about the Render Animation toolbar command?

Code: Select all

OfflineRender.OpenView('',0,0);Activity.Run('/Scripts/Commands/RenderAnimation');
How is that going to coexist with Vray?

I added this to the top portion in the /CustomCommands/RenderAnimation.xml script

Code: Select all

if (Node.Exists(Space.CurrentScene() + "/YafaRay4tS"))
{
UserInterface.OpenToolPanelViewEx2("" , "" ,Space.CurrentScene()+"/YafaRay4tS", 8, 1, 0);
return;
}
That stops Vray from running.
Problem with that is if the YafaRay4tS.RsObj is in the scene it stops Vray from opening it's Dialog.
So there needs to be more code to the above.
Problem is if Vray is installed/loaded it always creates a invisible Vray node in the scene.
And there is the possibility, even if Vray is not loaded, that a user opens a Vray scene which will have the Vray node.
Unless you can come up with a better solution, I am thinking that when a user wants to use YafaRay4tS, they will have to Unload Vray from the Package Manager, reboot tS, and generate a New scene.
Note to that even if Vray is unloaded and uninstalled, the Vray photo renderer node is still in the Offline Renderers.
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 14 Jun 2018, 17:59 Try using double backslash
Space.SaveScene( Folder + '"\"' + Scene_Name + Increment + '.RsScn');
Space.SaveScene( Folder + '"\\"' + Scene_Name + Increment + '.RsScn');
This creates a tS error too.
Is there something in your plugin that can add a backslash?
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 14 Jun 2018, 18:03 ...

I added this to the top portion in the /CustomCommands/RenderAnimation.xml script

Code: Select all

if (Node.Exists(Space.CurrentScene() + "/YafaRay4tS"))
{
UserInterface.OpenToolPanelViewEx2("" , "" ,Space.CurrentScene()+"/YafaRay4tS", 8, 1, 0);
return;
}
That stops Vray from running.
...
If it stops vray what is the purpose of adding it in?
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Here is a Yafaray Folder that includes a Render to File panel and R2F_PanelFrame.
There is no code in the script except Attributes and Defaults.
It actually works, as is, for rendering an animation.
I removed the Image part shown previously, this is just animation.
The code to call the panel is:

Code: Select all

if (Node.Exists(Space.CurrentScene() + "/YafaRay4tS/R2F_PanelFrame"))
{
Node.Copy(Space.CurrentScene() + "/YafaRay4tS/R2F_PanelFrame", "/Project/Windows Manager Space");
WindowsManager.Activate();
WindowsManager.UpdateWindowsStructure();
}
Was thinking about creating a toolbar button that calls this panel.
That is of course if you want to use it or not.
Removed due to update
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 14 Jun 2018, 22:25
trueBlue wrote: 14 Jun 2018, 18:03 ...

I added this to the top portion in the /CustomCommands/RenderAnimation.xml script

Code: Select all

if (Node.Exists(Space.CurrentScene() + "/YafaRay4tS"))
{
UserInterface.OpenToolPanelViewEx2("" , "" ,Space.CurrentScene()+"/YafaRay4tS", 8, 1, 0);
return;
}
That stops Vray from running.
...
If it stops vray what is the purpose of adding it in?
It only stops Vray's Render Animation if the YafaRaytS.RsObj is in the scene.

If you want to try calling the panel from the /CustomCommands/RenderAnimation.xml

Code: Select all

function Execute(params)
{
if (Node.Exists(Space.CurrentScene() + "/YafaRay4tS"))
{
Node.Copy(Space.CurrentScene() + "/YafaRay4tS/R2F_PanelFrame", "/Project/Windows Manager Space");
WindowsManager.Activate();
WindowsManager.UpdateWindowsStructure();
return;
}
if (Node.Exists(Space.CurrentScene() + "/Vray"))
{
Width = Node.Value(Space.CurrentScene() + "/Vray", "Image Width")
Height = Node.Value(Space.CurrentScene() + "/Vray", "Image Height")
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 1/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 1", -1, -1, Width, Height, -1, -1, -1)
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 2/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 2", -1, -1, Width, Height, -1, -1, -1)
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 3/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 3", -1, -1, Width, Height, -1, -1, -1)
}
if (Node.Exists("/Project/Windows Manager Space/Frame Window, 4/VrayView Node"))
{
WindowsManager.MoveWindow("/Project/Windows Manager Space/Frame Window, 4", -1, -1, Width, Height, -1, -1, -1)
}
OfflineRender.RenderAnimation('')
}
Theres is another issue using the above, if the Yafaray4ts.RsObj and the Vray.RsObj is in the scene and Yafaray is selected as the Renderer, the Vray view is opened. That's because the button command has OfflineRender.OpenView('',0,0);Activity.Run('/Scripts/Commands/RenderAnimation');
The OfflineRender.OpenView('',0,0) command can be removed from the toolbar because it is in the RenderAnimation.xml
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

So you're trying to call the yafaray panel from the button? There is no need for that.
The offline render buttons uses plugin calls to control everything, which is why you had to alter the buttons to make vray do what you wanted.
The yafaray offline render plugin calls scripts and doesn't do anything else, so you want to alter the scripts not the buttons.

the command scripts are found inside /Scripts/CustomCommands/YafarayScripts and are a direct translation of offline render system:
When you press a render button it calls the OpenView script then it calls one of the render scripts depending on which button you pressed. Right click on any of the buttons calls the EnumPropertiesPanel script.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

No problem just thought it would be an additonal way to call Yafaray animation.

I agree calling them how you are suggesting, in fact thought that is how you would want to in the first place.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

After seeing your panel I suggest it works this way:

Render Animation - opens the animation Render to File panel
Render Scene - opens a similar panel without the animation controls.
Render Object - renders to a fixed file with no dialog, like lightworks render to screen on model side
Render Area - defaults to the fixed file with an option on the YafaRay4tS panel for no dialog, render scene dialog or animation dialog
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Sounds good!
Let me ask you a question first.
How do you render just one D3D image in trueSpace761?
Using Render to File, right?
Using tS's Render to File as an example, you can render 1 image or several.
R2F.PNG
R2F.PNG (8.81 KiB) Viewed 3943 times
This is why I removed the Image part from the panel.
Even using the Animation aspect in YafaRay4tS, you can render 1 image as shown:
Capture.PNG
Capture.PNG (11.75 KiB) Viewed 3950 times
Edit: 6/15/2018
I have discovered something while creating this panel, the RenderAnim node's attributes do not look right to me because they are missing an underscore between the names. Not sure how this is even working but does. Except I can not update these values because of this. I have tested fixing this and it seems to work.
Do you want me to fix this?
Start Frame attribute.PNG
What is and how does Zero Padding and Number Start work?
Should these be included on the Render to File panel?
I was trying to keep it as simple as possible.
This Render to File is a WIP, and is not finished , as it is not connected to the YafaRaytS panel yet.

I was toying with the idea to use your Zoom 2 Selection for the Render Object, but it zooms to close.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

Render Animation and Render Image can be the same panel by adding an Animation checkbox. When Animation it defaults to on and when render image it defaults to off.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

I updated the plugin file so that the save as file dialog can be pre-populated with a full file path. It won't have a blank file name when opened. I also changed the procedural textures so their preview appearance matches the rendered appearance.

Just found out can't upload rsx files to the forum.
Attachments
Clintons3dPlugin62e4.zip
(1.22 MiB) Downloaded 169 times
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

attached is YafaRay4tS with some updates.

new file dialog that doesn't have a blank filename to start - requires new Clintons3dplugin plugin from previous post
animation can be cancelled by pressing the esc key
buttons just in case the Lighting Method watchdog falls asleep

yafaray install default checks 2 locations:
"C:\\Program Files\\Blender Foundation\\Blender\\2.79\\scripts\\addons\\yafaray_v3\\bin\\yafaray-xml.exe";
"C:\\Program Files\\yafaray_v3\\bin\\yafaray-xml.exe"

temp location default checks for
"C:\\Temp"
if that does not exist it uses the system temp folder for the user

I imagine we will change the temp folder to somewhere inside the trueSpace folders
Attachments
YafaRay4tS3728.RsObj
(693.32 KiB) Downloaded 170 times
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Thanks Clinton!
I imagine we will change the temp folder to somewhere inside the trueSpace folders
Image Folder and Animation Folder added to the main directory for rendering images, both include an Image.png.

New update:
viewtopic.php?t=5446&p=52492#p52492

tS7.61B8.4_YafaRay4tS9_7
Updated Clintons3dPlugin.rsx v.1638412
Image Folder and Animation Folder added to the main directory for rendering images, both include an Image.png.
D3DView.RenderToFile.Settings.xml added that is set to the Image Folder
YafaRay4tS panel updated 6/15/2018
Image Folders with ImagePNG.PNG
Image Folders with ImagePNG.PNG (11.02 KiB) Viewed 3912 times
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

clintonman wrote: 15 Jun 2018, 03:43 attached is YafaRay4tS with some updates.

new file dialog that doesn't have a blank filename to start - requires new Clintons3dplugin plugin from previous post
animation can be cancelled by pressing the esc key
buttons just in case the Lighting Method watchdog falls asleep

yafaray install default checks 2 locations:
"C:\\Program Files\\Blender Foundation\\Blender\\2.79\\scripts\\addons\\yafaray_v3\\bin\\yafaray-xml.exe";
"C:\\Program Files\\yafaray_v3\\bin\\yafaray-xml.exe"

temp location default checks for
"C:\\Temp"
if that does not exist it uses the system temp folder for the user

I imagine we will change the temp folder to somewhere inside the trueSpace folders
If the Output Render File string is empty I notice 4 problems.
Error.PNG
Error.PNG (10.23 KiB) Viewed 3899 times
Error2.PNG
Error3.PNG
Error3.PNG (2.65 KiB) Viewed 3899 times
I also got an error using the file button about the script GetFileRender. But I can not replicate.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 15 Jun 2018, 18:01 ...
If the Output Render File string is empty I notice 4 problems.
Error.PNG
Error2.PNG
Error3.PNG
I also got an error using the file button about the script GetFileRender. But I can not replicate.
Ok I see it.
Steps are to reproduce are
1. empty the file name
2. render - gives blank render
3. render - get error shown

Also I need to make another change to the plugin file. The new file save as only works properly in winxp and needs an adjustment to work in win7 and up. In xp it defaults to the folder in win10 it defaults to the last folder opened.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Here is an update for the YafaRay4tS.
Changes:
Start Frame.png
Start Frame.png (45.83 KiB) Viewed 3957 times
YafaRay4tS panel
RenderAnim - Added an underscore to Start_Frame, End_Frame, Number_Start, and Zero_Padding. Re exported and re linked all attributes to the front panel. Changed them in ALL scripts and buttons in the YafaRaytS.RsObj where they were being used without the underscore.
R2File.PNG
Render to File has been updated and runs from the Render Animation icon.
Need to add the following command to the YafarayScripts/RenderAnimation

Code: Select all

//	Activity.Run(Space.CurrentScene()+"/YafaRay4tS/RenderAnim2");
Activity.Run(Space.CurrentScene()+"/YafaRay4tS/Open R2File");
Here is a scene with a built in Sequence Viewer into the YafaRay4tS/tSDisplay and exported out to the Animation aspect.
Create an animation.
Select the File Dialog and then select the first image in the rendered sequence.
Left click the display to Play and Right click to Pause.
Right click the Sequence Viewer button to Reset
Capture.PNG

Removed the YafaRay4tS Sequence Viewer.RsScn 6/19/2018 due to update
Removed the YafaRay4tS.RsObj due to update
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

Once the animation playback starts it never ends. It stops updating the image but the looping code goes on forever. I had to disconnect the input to the Run activity to make it stop.
You can see in the output console window all the timer events.

let me know when you reach a point of no changes to the yafaRay4tS node. after that I'll add the fix for the file dialog and look into the blank filename errors.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

Sequence viewer is a nice touch btw. :bananathumb:
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

I do not have any problems with it stopping here.
Did you right click to stop it?
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 15 Jun 2018, 22:18 I do not have any problems with it stopping here.
Did you right click to stop it?
Looks like it doesn't happen the first time you click. If you left right click a couple of times it gets stuck and won't stop.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

There might be a missing node. Second line of stop script is
Node.Value('%THIS_NAME%/tSDisplay/Sequence Player', 'Activate') = 0;
but the Activate doesn't hookup to anything inside the Sequence Player node.

Edit: nevermind looks like it has some button associated with it that runs script
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

If you left click the button twice, that's when it gets stuck.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Ah, I see. Must be a sticky check box. Took me clicking like a mad man but I finally seen it stuck.
If you remove all the lines except these two in the Script on Right Click, it works without getting stuck.

Code: Select all

Activity.Stop('%THIS_NAME%/tSDisplay/Sequence Player/Run Activity');
Node.Value('%THIS_NAME%/tSDisplay/Sequence Player', 'Activate') = 0;
The Active is for the button to be depressed/not depressed, when at one point I was showing it in the stack.
I will test it thoroughly.
Would be nice to include it if works good.
What do you think?
I could also just use a Popup for the Sequence Player and not incorporate into the YafaRaytS panel.

Are you okay with the Render to File?
IMHO, It gives some safety to the Animation Render icon. Less you want to automatically create 300 + images by a click of a button.

If so:
Render Animation = Finished 'Able to create One or more images.'
Render Scene = Finished 'Able to create One image.'
Render Area = Have not tested this, I assume it works good?
Render Object = Thought I had a solution using your Zoom to Selection script by changing the ddist to /4. That worked pretty good except the object was not centered most of the time.
The other solution works great but I can not figure out how to end it by script, which is using the Zoom widget.
Possibilities. Make it into a scene widget, which I am not sure how to do. Or a hack with a triggered timer that deletes the widget after a set time. KaBooom! :shock:
Come to think about it you are able to load and unload your Cube widget. Maybe make an additional Zoom widget by another name?


Then there is the Default Temp folder you were talking about inside tS. Did you notice I created an Image Folder and Animation Folder in the Update 4 ? Did you want to incorporate that into YafaRay4tS?

IMHO, it would be great if you could have a default folder for scene images and one for sequence images, and have separate File Dialogs
Also the xml files make it a pain for sequence images. BTW...I forgot that I edited the Restore Defaults button script and added two lines at the bottom.

More Importantly is the compatibility with YafaRaytS and Vray.
Easiest solution is just make it a requirement that you should Uninstall Vray when using YafaRay4tS.
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

trueBlue wrote: 16 Jun 2018, 00:15 ...

Are you okay with the Render to File?
IMHO, It gives some safety to the Animation Render icon. Less you want to automatically create 300 + images by a click of a button.

...

More Importantly is the compatibility with YafaRaytS and Vray.
Easiest solution is just make it a requirement that you should Uninstall Vray when using YafaRay4tS.
I get an error when I press the offline render animation button
AnimError.jpg
so I don't see it operating. This is what I said a few pages back if that answers the question.
clintonman wrote: 14 Jun 2018, 23:30 After seeing your panel I suggest it works this way:

Render Animation - opens the animation Render to File panel
Render Scene - opens a similar panel without the animation controls.
Render Object - renders to a fixed file with no dialog, like lightworks render to screen on model side
Render Area - defaults to the fixed file with an option on the YafaRay4tS panel for no dialog, render scene dialog or animation dialog
As far as the YafaRay vs VRay problem I don't see it. I can switch back and forth between the 2 and render without any problems. Maybe you can give me some steps so I can reproduce the problem.
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

Looks like there is still a problem with animation cancellation. I had to try several times to cancel it and my attempts kept going to the dos window instead of the truespace window.

Edit: Nevermind, I was trying to use ctrl-c instead of esc for some reason. Animation cancel is good.
Clinton Reese

http://clintons3d.com
User avatar
trueBlue
Captain
Posts: 5548
Joined: 06 Jul 2009, 22:50
Type the number ten into the box: 10

Re: Yafaray4tS v0.9.0

Post by trueBlue »

Yeah the Esc button works like a charm here.
I can run this a million times here with no problem.
Also:

Code: Select all

Activity.Run(Space.CurrentScene() +"/YafaRay4tS/RenderAnim2");
Can you check the YafaryScripts\RenderAnimation script for a misplaced semi-colon ;

Also did not think about backwards compatibility when I added a underscore to the Start Frame attributes along with the other ones. Could that be an issue?


Compatibility with Vray
Are you running this script from YafarayScripts/RenderAnimation ?

Code: Select all

// Execute 
// Called to execute the command 
function Execute(params)
{
	var szViewName = params.ConValue('szViewName');


	System.Trace("render animation");

	if (Node.Exists(Space.CurrentScene()+"/YafaRay4tS")){
	} else {
		if(Node.Exists("/Yafaray Folder")){
			Node.Copy("/Yafaray Folder/YafaRay4tS", Space.CurrentScene());
		}
	}

	Node.Value(Space.CurrentScene()+"/YafaRay4tS", "Yaf_UseAreaRender") = false;

	Node.Value(Space.CurrentScene()+"/YafaRay4tS", "Start_Frame") = RsAnimPref.PlayRangeStart;

	Node.Value(Space.CurrentScene()+"/YafaRay4tS", "End_Frame") = RsAnimPref.PlayRangeEnd;


	Activity.Run(Space.CurrentScene()+"/YafaRay4tS/VersionCheck");

//	Activity.Run(Space.CurrentScene()+"/YafaRay4tS/RenderAnim2");
Activity.Run(Space.CurrentScene()+"/YafaRay4tS/Open R2File");


}
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

This is what I have:

Code: Select all

// Execute 
// Called to execute the command 
function Execute(params)
{
	var szViewName = params.ConValue('szViewName');


	System.Trace("render animation");

	if (Node.Exists(Space.CurrentScene()+"/YafaRay4tS")){
	} else {
		if(Node.Exists("/Yafaray Folder")){
			Node.Copy("/Yafaray Folder/YafaRay4tS", Space.CurrentScene());
		}
	};

	Node.Value(Space.CurrentScene()+"/YafaRay4tS", "Yaf_UseAreaRender") = false;

	Node.Value(Space.CurrentScene()+"/YafaRay4tS", "Start Frame") = RsAnimPref.PlayRangeStart;

	Node.Value(Space.CurrentScene()+"/YafaRay4tS", "End Frame") = RsAnimPref.PlayRangeEnd;


	Activity.Run(Space.CurrentScene()+"/YafaRay4tS/VersionCheck");

	Activity.Run(Space.CurrentScene()+"/YafaRay4tS/RenderAnim2");

}
Clinton Reese

http://clintons3d.com
User avatar
clintonman
Captain
Posts: 5659
Joined: 21 May 2009, 21:08
Type the number ten into the box: 0
Location: California

Re: Yafaray4tS v0.9.0

Post by clintonman »

OK, copy pasted your code and now it works.
Clinton Reese

http://clintons3d.com

Return to “Rendering”