Page 1 of 1

Realflow crash when trying to load scene

Posted: Sun Oct 01, 2017 10:52 am
by motoyuki
Hi,

I'm trying to do the "render batch script" from waterline magazine 01.
I have the problem, that both on mac and on PC it crashes Realflow (10.01).
I narrowed it down to the scene.load command not working in a for loop.

also when I add

scene.setCommandLineSimulation(True)

it doesn't simulate in commandline, but in the GUI.
is that a bug or am I doing something wrong here?

here the full script for you to test:
the problem occurs in the last for loop

numberOfFields = 10
projectFiles = []

guiForm = GUIFormDialog.new()

for fieldNumber in range(1, numberOfFields + 1):

if (fieldNumber < 10):
fieldName = "Project file 0" + str(fieldNumber)
guiForm.addFileField(fieldName)

else:
fieldName = "Project file " + str(fieldNumber)
guiForm.addFileField(fieldName)

if (guiForm.show() == GUI_DIALOG_ACCEPTED):

for fieldNumber in range(1, numberOfFields + 1):

if (fieldNumber < 10):
fieldName = "Project file 0" + str(fieldNumber)

else:
fieldName = "Project file " + str(fieldNumber)
fieldEntry = guiForm.getFieldValue(fieldName)
projectFiles.append(fieldEntry)

for currentProject in projectFiles:
if (currentProject!= ""):
scene.load(currentProject)
scene.setCommandLineSimulation(True)
scene.simulate()
scene.message("Simulating " + currentProject+ "Ö")

else:
scene.message("Script cancelled by user.")

Re: Realflow crash when trying to load scene

Posted: Mon Oct 02, 2017 6:40 am
by tsn
Ho motoyuki,

Thanks for pointing me to this issue. I'll give it a try today to see if the script can be fixed or if it's a RF thing.

Cheers,
Thomas

Re: Realflow crash when trying to load scene

Posted: Mon Oct 02, 2017 9:39 am
by tsn
I've tested the script and you're right: RF 10.1 crashes when the second scene is loaded. This is most probably a RF bug, because the script works with RF2016. I've checked most of the magazine's scripts with RF10, but I've obviously missed that one.

Thanks for letting me know!

Cheers,
Thomas

Re: Realflow crash when trying to load scene

Posted: Sat Oct 14, 2017 12:58 am
by motoyuki
Thomas, thanks for checking!

And thanks for doing the waterline magazine, it's very well done and helps me a lot!!!

cheers,

Marcus

Re: Realflow crash when trying to load scene

Posted: Fri Oct 27, 2017 12:01 pm
by tsn
Good news Marcus! The latest version, available in the customer portal, has this bug fixed and the script is working again.