PostProcessingPlugin icon indicating copy to clipboard operation
PostProcessingPlugin copied to clipboard

automaticaly add a PostProcessing Script

Open spilz87 opened this issue 8 years ago • 16 comments

hello,

it's not really an issue, but I don't find where to post my request. I wrote a postprocessing script which works well. I want to use it all the time, but I forget sometimes to load it when I open CURA.

How can I modify PostPressingPlugin.py to automatically load my script ?

my script for exemple is name : PH1 key : PH2

I tryed to add at the end off def init(self,parent = None): ... self._script_list.append(self._loaded_scripts"PH2")

but it does not work :(

thanks for your help

regards

spilz87 avatar May 03 '17 13:05 spilz87

But when you add some post-processing scripts by default, what parameters will be supplied to the post-processing script?

I suppose it's possible to add a list of scripts to the preferences menu of Cura, to be executed for every slice.

Ghostkeeper avatar May 05 '17 11:05 Ghostkeeper

my post-processing scripts has default value which are right for my printer. the only thing is I often forget to just seect it in pos-pressing menu :(

spilz87 avatar May 05 '17 12:05 spilz87

What I meant is, if you were to add the new search-and-replace post-processing script for instance to fix some problem with your printer like removing all "G10" from the g-code, then you want to add that to every print you make. But you'll have to set the parameters of the script such that G10 is always removed. Otherwise it does nothing.

The only way I see working is to allow adding post-processing scripts in the machine settings action as well and save those along with the printer somehow.

Ghostkeeper avatar May 10 '17 08:05 Ghostkeeper

and how do you do that ?

spilz87 avatar May 10 '17 08:05 spilz87

Well you can't, currently. There is no mechanism to save the active post-processing scripts at the moment.

Ghostkeeper avatar May 12 '17 08:05 Ghostkeeper

That s why I'm thinking to modify the posprocessingpluging.py to automatically load a post processing script

spilz87 avatar May 12 '17 11:05 spilz87

The postprocessing settings should be saved in the config file so that what you start up cura the postprocessing scripts are loaded from that file with the setting values which were saved.

Would that be the correct way to do it?

BagelOrb avatar May 12 '17 12:05 BagelOrb

Eh, it should be done in such a way that the project loading also takes it into account. The result would be a list of postProcessing scripts with key value pairs.

nallath avatar May 12 '17 13:05 nallath

actually I'm not looking for the correct way to do it, I'm just looking for a way to do it ^^

a quick way to do it, I think, is to "active the postprocessing script after the list is created by postprocessingpluging.py

but I don't know how to do it in python :(

spilz87 avatar May 12 '17 13:05 spilz87

I'd say that it's most logical to save it in the global stack file, or at least link it to the global stack. Then it would also get saved along with project loading.

Ghostkeeper avatar May 15 '17 15:05 Ghostkeeper

Does that mean you couple it to the current machine? That would make a lot of sense.

BagelOrb avatar May 15 '17 18:05 BagelOrb

This feature request was just rejected by our project manager for being inactive for 3 months.

Ghostkeeper avatar Aug 08 '17 07:08 Ghostkeeper

actually I still need it, but I don't find a way to do it :(

spilz87 avatar Aug 08 '17 09:08 spilz87

For me it would be better in profile file than in project

spilz87 avatar Aug 08 '17 09:08 spilz87

hmmm... it depends on the script... if it is a modification usually valid for one situation/project/model, than it should be stpored per project, but if it is a general modification like the "show layer" script which (in my case) shall be applied on profie base in every single gcode exported...

Drayson80 avatar Dec 04 '17 14:12 Drayson80

Actually it is also my case : it is a general modification

spilz87 avatar Dec 04 '17 14:12 spilz87