Sat, Nov 30, 3:05 PM 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 Sep 18 2:50 am)

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: Moving character with Python?


Shadowy_Mike ( ) posted Fri, 01 June 2007 at 1:10 PM · edited Sat, 30 November 2024 at 7:39 AM

file_379061.gif

Hi,

I built some different models (walls, doors, gangways… examples) with whom you can put rooms together very variably. With DAZ|Studio, postponing and linking of these models work, however in Poser, the units of measurement (metric) are not correct. There, only very crooked values come out which the precise linking unnecessarily impedes.
(The objects (models) have the correct measurements, also after the import in Poser. Only with the moves the models the units of measurement are not correct.)

Now my question:

Does it give a python to Script with which I character models as well as probs can move and link?

**Following example should clarify my idea (see picture):
**
Two cubes has both the measurement 100x100x100 centimeters. Both stand on the base. The cube (red) to be postponed is at the position X=0, Z=0. He should be postponed exactly matching to the cube (green) so that the impression of a Quaders originates (yellow indicated). The green cube is at the position X = 400, Z=200.

Consequently, the red cube would have to be postponed about Z=200. (Then, the two front-surfaces are on a height.) He would also have to be postponed about X=300 next. Then, the right side-surface of the green die and the left side-surface of the red cube touch.

Is there a script, which can something similar?

How much works, it would be to be written something similar? (With python, I don't have yet any experience)

Or does somebody have another solution for the problem?

I thank for your effort already once

Greeting

Martin


adp001 ( ) posted Fri, 01 June 2007 at 4:33 PM

Did you change Posers measurement to centimeters? Poser works in  "Poser-Units" by default.




Shadowy_Mike ( ) posted Fri, 01 June 2007 at 6:30 PM

Yes, of course. ;-)

I gave a try to also already meter and millimeter. I would have to put in 1,075 m (or 1.075) for a postponement by one meter. With several modules, these deviations would be accumulated for itself and would be no more method-Abel for the user.

Thanks for the attempt ;-)


adp001 ( ) posted Sat, 02 June 2007 at 3:01 PM

Hm. How do you define one centimeter in a wavefront obj-file imported into Poser? Or with any other 3 dimensional object? Such an object consists of values between -1.0 and 1.0 (standard, not only for Poser).

Poser isn't CAD.

With 3D "anything is relative". All 3D-objects are measured relative to a fictional 3D-World (the reaseon why scaling is done in percent; relative to the worlds bounding box). An objects position is relative to it's origin in 3D-space ( measured in values between -1.0 and 1.0).

Perhaps you may look at Dr.Geeps tutorial to find a solution for this well known problem.




Shadowy_Mike ( ) posted Sat, 02 June 2007 at 5:22 PM

file_379137.jpg

I know the difference between 3D Modellern and CAD programs. I work with both.

If I generate a Cube with Wings 3D and export it as an OBJ file (1:1), then, the Cube has after an import (1 unit = 1 m) in DAZ|Studio a crust-length of 2 meters. If I exports this Cube with DAZ|Studio (0.410104987 percent (Poser-Format)), then, this Cube in Poser has also a crust-length of 2 m. I really don't see where the problem now should be.

With the problem portrayed by me, it is about the postponing an object. And there the units of measurement simply are not correct.

"With 3D "anything is relative"."  This statement is, after my conviction, nonsense. - Sorry. ;-)

I know Dr.Geeps tutorial, however this doesn't help me in this case either.

Again to the clarification:

Object 1: A Quader 4 m long, 1 m high and 1 m wide.
Object 2: A Cube with a crust-length of 1 m.
The Cube becomes in DAZ|Studio on the Quader positioniert (sees picture.)

After the ex- and import from DAZ|Studio to Poser is so this as well.
If however, I now want to postpone this Cube in Poser on the other end so, I must input a bigger value than 300 cm (about 320 cm). And that simply is wrong. - And exactly therefore it goes me.

The problem exists. Why it actually doesn't matter to me, I look for an as simple as possible solution. Now, I can say, this problem exists in Poser 6 - With Poser 5 ther is no problem.

Meanwhile, I can say that the problem exists at least with POSER 6. With my tests with POSER 5, it gave no one to such incongruity. With POSER 7, I could not test it since I don't have this version.

 


dennisharoldsen ( ) posted Sun, 03 June 2007 at 9:14 AM

i am new to poser, python, forums, and the whole 3-d art world....
however, i am an experienced software developer.

i appreciate that anyone would care enough to make a response.
thank you "adp001" for what you said & what you do. i have taken it in.

poser & other programs do appear as relative
but internally, it is all mathematics and the numbers are there.

Shadowy_Mike:

i am working on a python way to understand scale and size, etc.
your communication is that you want the most simple solution.
maybe that is not python or even poser.
it would be good to understand what you wish to accomplish. please tell us.
if you have everything working in other programs, why use poser?
maybe there is a more simple solution to do what you want to do.

i have enjoyed your dialogue.


Shadowy_Mike ( ) posted Sun, 03 June 2007 at 2:37 PM

hm, beautifully that at least you had your fun. ;-)

Therefore again from in the front:

I produced miscellaneous models (OBJ files). Each individual one of this OBJ files forms a module. By the variable putting these modules together, very different rooms can be built. One could look at some examples for these modules if one had followed the Link in my first Posting.
examples :-)

For producing my pictures, I use mainly DAZ|Studio. On my home page and also here in the Free Stuff area, I offer my models as Poser Ready. (free) Because, cr2 files are the most comfortable resolution for the most things. (for Poser & DAZ|Studio)

For what I looked and still seek, answers to following questions are:

  1. If there is a python script with which I two bodies one on top of the other can line up. How Align in Wings 3D or in different 3D CAD programs. (Often at the assembly of parts)
  2. If there is not yet such a program, is it to be possibly written something similar as an Python Script? I am certain, that it (somehow) is possible, the question therefore is more whether the expenditure is worthwhile. Since I have not done yet anything in this direction until now.

The solution-base of this me envisions he/it was independently from the applied units of measurement on PNUs there falls back. I think that it first would have to be determined the respective origins of the two bodies, relatively to the origin. Then, the Boundingbox measurements of the bodies would have to be decided. So one could determine the value of the postponement and executes these then. Surely it would be the simplest on that occasion if I execute this individually for each area-axis. Also the possible rotation of a body probably would have to be taken into account on that occasion.
Since the Script accesses the internal format (PNU) on that occasion, it should not play any role which Display units of the users exactly put in. (inch, feet, meter …)

I hope somewhat more clearly now had expressed me myself. It is not that somebody writes a program for me. Of course, I would not have anything on the other hand. :-)
I only want to know whether it is at all possible with justifiable expenditure.

Because actually I wanted to occupy myself with DAZ|Script soon. However now, since the problem simply is there, I would concern myself with python.

Greeting
Martin


dennisharoldsen ( ) posted Sun, 03 June 2007 at 11:05 PM

you seem angry at those who listen to you and try to help.
i "did" read your first post and went to your website. it is very nice.
i tried a set of stairs in poser. nice work.
i asked you what you wished to accomplish as in your final goal.
i did not ask you to re-explain the technical issues.
i don't require anything of you, i was hoping to help you.
from what i understand, your purpose is to make poser props from your daz.
is that what you wish to accomplish?
that is something that people are already doing. ask them.
writing a python script is not an easy solution, if possible.
when i said i enjoyed your dialogue, that was meant as a compliment.
i offered to share what i learn with you.
you seemed to take offense at my responding to your question.
i promise not to offend you again. this is my last post to you.


Shadowy_Mike ( ) posted Mon, 04 June 2007 at 4:20 AM

Hello again,

Quote - you seem angry at those who listen to you and try to help.

I didn't notice this until now. As this comments? Okay, we forget the question, I read exactly your message at end.

Quote - i "did" read your ridge post and went to your web site. it is very nice.
i tried a set of stairs to poser. nice work.

Thank you, really pleases me.

Quote - i asked you what you wished to accomplish ace in your final goal.
i did of necessary ask you to re-explain the technical issues.

hm, I know, my English is not good. But so I had understood your invitation: > Quote - it would be good to understand what you wish to accomplish. please tell us.

  • Sorry, my mistake.

Quote - i don't require anything of you, i was hoping to help you.

That really is very friendly. I am very pleased about every help. I didn't want to give only any wrong impression. Because I want desires from nobody to solve my problem. . If he nevertheless does it, maybe because it interests him itself, this would be wonderful.

Quote - from what i understand, your purpose is to make poser props from your daz.
is that what you wish to accomplish?

No. – Sorry.

Therefore, I tried explaining on the basis of the more exact description about what goes. However my English seems not to be sufficient for it. I looked for a solution, that worked like "Align Ace" (a Plug In for DAZ|Studio).  With "Align Ace", one can line up Probs and Charater on the basis of their crusts (surfaces) one on top of the other.

Quote - that is something that people are already doing. ask them.

I don't believe that this problem so often appears. Sunbathes there was probably already a corresponding solution. Or not?

Quote - writing a python script is not an easy solution, if possible.

Programs never is really easy, if one makes it serious. But it also can joy does, or approximately not?

Quote - when i said i enjoyed your dialogue, that was meant as a compliment.
i offered to share what i learn with you.

Sorry - however I was somewhat frustrated because solution-suggestions, after my opinion, of my goal continued everything instead of taking further me.

Quote - you seemed to take offense at my responding to your question.
i promise not to offend you again. this is my last post to you.

I am sorry about this, because I didn't want to create this impression.

Meanwhile, I reached also the conviction that it is better to be close this Threat. Obviously it is not possible for me to articulate me so, that nobody offends feels.

This was never my intent. - Sorry

Probably live and good luck
Martin

PS
How can I close this Threat?


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.