1

I wonder if it is possible to have a progress bar in blender's GUI not in the console to show the progress of my script. For example in my addon I have 3 buttons, 1 of them loads an obj file and do some processing on it, second one does some processing and animation and the third one reads a file. So I want when I press on any of the buttons somehow I will be able to see the % progress of the button script through blender itself not through the console.

Tak
  • 6,293
  • 7
  • 43
  • 85
  • related: http://blender.stackexchange.com/questions/3043/how-can-i-visualize-progress-in-a-panel – Jaroslav Jerryno Novotny Apr 08 '17 at 14:12
  • related: http://blender.stackexchange.com/questions/3219/how-to-show-to-the-user-a-progression-in-a-script – Jaroslav Jerryno Novotny Apr 08 '17 at 14:12
  • I think your best bet is either use the cursor or make your own progress bar with opengl and bgl module. – Jaroslav Jerryno Novotny Apr 08 '17 at 14:15
  • @Jerryno thank you. I followed this: https://blenderartists.org/forum/showthread.php?286682-Setting-progress-bar-values&p=2339247&viewfull=1#post2339247 and it works, but how I can incorporate it with my button operator? like make it works when my button is pressed and then update it's progress to looks realistic and finishes when my button's functions finishes? – Tak Apr 09 '17 at 00:02
  • You can draw from a modal timer operator, then self-terminate that operator when the job is done, or you can use threading and do the job in separate thread updating some property and draw from (for example) app.handler according to the property. – Jaroslav Jerryno Novotny Apr 09 '17 at 15:20
  • @Jerryno Thank you very much, but what about the steps? so I have an operator for a button which imports an obj file then do some processing on the imported object. And I have the other modal time operator drawing the bar. How I can use the modal time operator together in my other operator? – Tak Apr 10 '17 at 00:16

0 Answers0