0
$\begingroup$

So I have a script that does a bunch of stuff with and imported STL (It separated it different objects and some other stuff) Right now I'm just manually importing the STL, then manually batch exporting the resulting objects into the same directory.

Is it possible to have python open the Import pop-up window, so that I can select the STL to import from a directory, and have it save the directory of the object so that it can then batch export the resulting objects into that directory?

I'm sure it's possible to do it if the code itself has the directory and I manually change it each time, but that'd take longer than manually exporting them. Opening the Import pop-up doesn't generate any code in the Scripting tab so I'm not sure if this is even possible

Any ideas? Thanks

$\endgroup$
4
  • 1
    $\begingroup$ Yes you can do that with python. Your question needs to be more focused on a step you got stuck at. Maybe present a piece of code. $\endgroup$
    – Harry McKenzie
    Commented Jun 30 at 15:41
  • $\begingroup$ @HarryMcKenzie I don't have any. I normally go to the scripting tab and try to copy paste code and see if it works but nothing comes up in this case when I open the import pop-up window so I don't really know how to even start. It doesn't help that if I look up 'Import' and 'Python' in blender on youtube all the results are about importing code and stuff like that... $\endgroup$
    – Cornivius
    Commented Jun 30 at 18:01
  • $\begingroup$ I'm realizing not that, since I import from the same folder, that folder is the n1 in the Recent folders list. So I only really need code to batch export to that folder. I'll see if I can work with that $\endgroup$
    – Cornivius
    Commented Jun 30 at 18:28
  • $\begingroup$ Do you mean a script that makes importing/exporting faster? $\endgroup$
    – Faris
    Commented Jun 30 at 22:23

0

You must log in to answer this question.

Browse other questions tagged .