Forum Coordinators: RedPhantom
Poser - OFFICIAL F.A.Q (Last Updated: 2024 Nov 11 2:16 pm)
Attached Link: http://ockhamsbungalow.com/Python/CamCircle.zip
Take a look at my CamCircle script. It does nearly what you want, except for the PNG. You'll have to convert the files externally from BMP to PNG. CamCircle as it now stands is set to make 32 steps of 11.25 degrees each. To make 8 steps of 45 degrees, find line 40, and change it from Steps = 32.0 to Steps = 8.0 Before using the script, you'll need to set up Poser so that the render happens in the main (Preview) window. There's no way for Python to handle a "Render In New Window." Try it and see how it works; if it's not right, let me know and I'll make an alternate that serves your purposes better.My python page
My ShareCG freebies
Thanks a million! This is exactly what I needed. Just a few minor tweaks to the code and it does just what I want it to do. If the game is ever completed you'll be mentioned in the credits! One more question though, I want one light to rotate along with the camera, so the person is always highlighted as seen from the camera, what should I add to the code? Thanks again /Dan
I think something like this should do the job (I haven't tried it, so it may be all wrong!) Find the line where the camera is actually moved. In my copy it's at line 151. This line: CamRot.SetValue(Step * 360.0 / Steps) Just after this line, at the same indentation, add these two lines: LiteRot = scene.Actor("Light 1").Parameter("yRotate") LiteRot.SetValue(LiteRot.Value()+(Step * 360.0 / Steps)) If the light is placed properly to begin with, this should make it turn with the camera. You may need a minus sign in the middle of the second line instead of a plus.
My python page
My ShareCG freebies
Hi! Thanks again for the great help. Now I manage to circle the light along with the camera, and the script produces png files instead of bmp files. But I still have a problem when I try to change the output resolution of the images. The images are always 374 x 386 pixels no matter what I have in the Render Options dialogue and it doesn't matter what I write in the function 'scene.SetOutputRes(200,200)'. I would prefer lower resolution output images then 374 x 386 pixels. Any help would be appreciated! /Dan
You're right, SetOutputRes doesn't seem to do anything. I have a solution for this, which requires an external .PYD module written in C. (a DLL, in other words).... Send me the code as it stands, and I'll add the DLL and send it back. The resulting script will be more useful for others as well. (Use email address Cam@ockhamsbungalow.com)
My python page
My ShareCG freebies
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.
Hello.
I'm having problems understanding PoserPython.
I want to create a script that:
sets the main camera and light 1 in front of my character x = -20, y = 0, z = 0
I want the camera and the light to rotate 45 degrees along the y axis 8 times to complete a full circle
3 I want to make a movie of png files, half resolution, for each of the views created in (2), one frame per view, so I get eight images from around the character.
Repeat steps one and two but instead of making movies consisting of one frame I want to make a movie of 19 frames.
I'm making an amature adventure game using the excellent program Adventure Game Studio (www.adventuregamestudio.co.uk) and I need the images to create sprites for my characters in the game. Images created in (3) would be a standing pose used when the character is not moving. Images created in (4) would be used in a loop to animate walking in different directions.
I have basic programming experience but I don't know anything about Pyhton. Any help would be really welcome since this is really time consuming work to do manually.
/Dan