Mon, Jan 27, 6:53 AM CST

Renderosity Forums / Poser Python Scripting



Welcome to the Poser Python Scripting Forum

Forum Moderators: Staff

Poser Python Scripting F.A.Q (Last Updated: 2024 Dec 02 3:16 pm)

We now have a ProPack Section in the Poser FreeStuff.
Check out the new Poser Python Wish List thread. If you have an idea for a script, jot it down and maybe someone can write it. If you're looking to write a script, check out this thread for useful suggestions.

Also, check out the official Python site for interpreters, sample code, applications, cool links and debuggers. This is THE central site for Python.

You can now attach text files to your posts to pass around scripts. Just attach the script as a txt file like you would a jpg or gif. Since the forum will use a random name for the file in the link, you should give instructions on what the file name should be and where to install it. Its a good idea to usually put that info right in the script file as well.

Checkout the Renderosity MarketPlace - Your source for digital art content!



Subject: FaceRandomizer


bushi ( ) posted Wed, 07 February 2001 at 4:55 PM · edited Sat, 16 November 2024 at 1:16 PM

Attached Link: http://bushi3d.com/PythonScripts/FaceRandomizer2.py

I took the face randomizer script and wrapped some TkInter code around. You can now randomize the figure's face multiple times without having to restart the script. Not the best example of structured programming since there is a lot of code re-use but a reasonable example of using TkInter with PoserPython. The buttons: Go! - Randomize the figure's face MTs Increment - Add 0.05 to all the face MT values. Try clicking this one several times. Decrement - Sub 0.05 from all the face MT values. Reset - Sets all the face MTs back to 0.0 Quit - kills the pop-up window. I've also added a feature that copys the Left Blink value to the Right Blink. This gives a better result on the face overall.


JeffH ( ) posted Thu, 08 February 2001 at 11:05 AM

Thanks.


Mason ( ) posted Thu, 08 February 2001 at 11:21 AM

Cool idea.


poserpro ( ) posted Thu, 08 February 2001 at 1:50 PM

This py is cool, better than mine:)


Colm_Jackson ( ) posted Thu, 08 February 2001 at 7:39 PM

This is totally excellent. With a bit of time and tweaking you can get some very 'real' faces... Faces you have seen before. One thing though... I have to quite the script before I can adjust anything or it crashes. Well done Bushi... Colm...


bushi ( ) posted Thu, 08 February 2001 at 11:22 PM

Thanks! I'm still tinkering with it so I expect it to improve with age. grins pro - The next feature will be that 'undo' you asked about earlier. Colm - I'm not certain yet if that's a limitation in the script or just something to live with in PoserPython. I'd also like to figure out how to get the dials to update automatically.


poserpro ( ) posted Fri, 09 February 2001 at 9:26 AM

Thanks for the promising "undo". One more thing, can we expand the PythonScript's panel so that more ( like 20 )buttons can be accessible in the panel, no need to clear all the buttons entirely and retrive the ones we need again.


bushi ( ) posted Sun, 11 February 2001 at 12:47 AM

pro - Can you explain this a bit more? I'm not certain about what you're asking?


poserpro ( ) posted Sun, 11 February 2001 at 3:46 AM

Thanks Bushi despite PPP's PythonScript panel is small, one can use only 10 *py in the panel, I know now we can use Alt+click to change the button and Ctrl+click to edit. And I understand now we don't have to clear all to retrieve the ones we need, just Alt+click for the one we don't need to replace with new one. I just thought if we can make it contain more ( like 20 ) buttons in the little panel, so as to expand it.


gryffnn ( ) posted Sun, 11 February 2001 at 10:18 AM

Looks to me, at least on the Mac, like to you can add a sub-folder, which then shows up as a button that opens up a sub-menu of scripts, so you could organize a stucture that keeps more at hand.


bushi ( ) posted Mon, 12 February 2001 at 11:00 PM

pro - You should be able to just add another line in the script with a new button number. All this stuff is dynamic so it should work fine. If you have any problems let me know and I'll check it out.


poserpro ( ) posted Tue, 13 February 2001 at 10:09 AM

Right, Bushi I see we can add more line in numeric order in mainScript.py, I tried to add up to 14 buttons as this is valentine day. but it told me "buttonIndex must be 1 to 10" ?


Privacy Notice

This site uses cookies to deliver the best experience. Our own cookies make user accounts and other features possible. Third-party cookies are used to display relevant ads and to analyze how Renderosity is used. By using our site, you acknowledge that you have read and understood our Terms of Service, including our Cookie Policy and our Privacy Policy.