Forum Moderators: Staff
Poser Python Scripting F.A.Q (Last Updated: 2024 Sep 18 2:50 am)
Ok, just few questions for clarification: 1) By 'transfer' or 'copy' morphs, are you envisioning something like Daz's Tailor program? Or is it more like, transfer or copy the value of the dials from the base figure to equivalent dials on the clothes? (I think you mean the second, but I just want to make sure.) 2) I assume this is for P5, because FBMs between parent figure and the clothes in PP would have crosstalk, so part of this hypothetical python script wouldn't be needed in PP. 3) I don't have any Megianstorm products, but it just comes with pbms but no fbms? FWIW, I think the autoconform script you're referring to is the one that I wrote. I did follow up that script with a P5 version that also introduced some (limited) crosstalk between figure and clothes in P5. I'll post a link if you're interested.
Here is a snippet from his readme:
Example: Breastsize5 = 0.75
Set the dial value from the lcollar/breastsize5, rcollar/breastsize5,
chest/pbmbreastsize5_lc and chest/pbmbreastsize5_rc to the same value as you used in
your character.
Why must i set the pbm-morphs too ?
The influence reaches from the collars into the chest !
Example: You used barbarian1 = 0.5 and muscular2 = 1 in your character
It's necessary that you set all barbarian1 morph dials in the different clothing
parts to 0.5 and all muscular2 morph dials to 1.
It's not necessary to set the pbm-morphs too !
I hope you understand the different between situation 1) and 2) !
Message edited on: 03/15/2005 08:47
miked123, this brings to mind something I was playing with when looking at ockham's jiggles script. At one point, a body part morph value is modified by a little bit to determine the average direction the morph moves and then set back to its previous value. Unfortunately, what Poser Python (at least in P5) gives you for the morph.Value() is NOT that body part's morph dial setting, but the accumulated effect of PBM and JCM influences in addition to the local dial setting. If you have any active PBM or JCM effects, a loop getting and setting the morph value for the body part repeatedly will exponentially increase the effect. To try and counteract this, I developed a little function which takes a morph (actor.parameter), gets its current value and splits that into PBM/JCM (delta) and local dial parts and returns them, resetting the value without modification. def DialAndDelta(Morph): val1 = Morph.Value() # read value Morph.SetValue(val1) # set same value val2 = Morph.Value() # get new value delta = val2 - val1 # find FBM or JCM delta influence val0 = val1 - delta # find original parameter dial value for this actor Morph.SetValue(val0) # reset to original value return (val0, delta) example using DialAndDelta: for OneMorph in TheActor.Parameters(): if OneMorph.IsMorphTarget(): (dial, delta) = DialAndDelta(OneMorph) OneMorph.SetValue(-delta+0.001) # Set morph upward a bit without delta influence ... For a given body part, you could traverse back up the actor parent chain collecting all the PBM dial values for a given morph. Hope this is useful :-)
Verbosity: Profusely promulgating Graham's number epics of complete and utter verbiage by the metric monkey barrel.
gwhicks:
That's one excellent explanation for something that's always puzzled me -- up until now, I've just assumed Value() had a bug in it. Thanks for posting.
Ok, thinking out loud, I was going to modify my Autoconform script to copy the appropriate dial settings from figure to clothes while conforming them -- that's not too tricky. If it's only a one-time copy (ie. the user never changes the figure's FBMs), I probably wouldn't have to worry about these delta influences.
However, I also wanted to loop so that if the user spun the figure FBMs dials, the clothes dials would also appropriatedly change ... OK, I probably do need to track these deltas. Yep, very interesting.
I'll try to post something Sunday night/Monday morning.
I wanted to make sure this is what you had in mind before I added part 2 of your request, which will be to set PBM dials in the clothes if it doesn't have the FBM dial.
I haven't added gwhick's tip yet, but that's on the to-do list.
I tried the script and it seems to work, but I really need the lower level morphs. I loaded V3 and added some FBM's. I then activated the script and loaded some clothing that also had the same FBM's (V3 bikini). The bikini acquired the same morphs. I believe that it does this already though due to cross talk. What I really need is for when there is no morph at the body level to propagate the target body morph down to the individual parts of the clothing that have the same morph. I really appreciate your efforts and think maybe you should contact Megaionstorm as well because this script could greatly enhance his products.
Howdy miked123: I was writing this while you posted: I picked up a megaionstorm product (for a BillyT swimsuit) from the Rendo marketplace because I didn't own any pbm-only clothes that could be used for testing purposes. Well, after following his/her readme and making the new cr2 with the pbm morphs, I'm seeing a problem. Basically, for any body part, there are more similiarly named morph dials than I anticipated. For example, in the chest, there's a pbmBreastSize5_rc and a pbmBreastSize5_lc, which of course is mentioned in the readme you posted. However, there's also a third dial that's simply named BreastSize5, which frankly, I didn't expect to see. So, following megaionstorm's readme, the script will have to ignore the dial whose name matches the FBM in the figure and find the pbm dials. However, for the Barbarian1 morph, in the chest there's dials named 'Barbarian1', 'pbmBarbarian1_rC' and 'pbmBarbarian1_ab'. (There's probably a 'pbmBarbarian1_lc' as well.) Anyway, again according to the readme, the script is now supposed to find the Barbarian1 dial and ignore the pbm dials -- pretty much the opposite of the BreastSize5 morph. So basically, I didn't expect these excess dials in the body parts -- you don't see these things in the Daz's morphing clothes that I own. I was anticipating a script that only needed some simple matching and copying between the figure's FBM dial name and the clothes PBM dial name; now it's "well, if the FBM has 'breast' in it, follow rule 1; else, follow rule 2". The upshot of this is : 1) Since megaionstorm products actually don't have any FBMs in the clothes, the beta I posted won't do anything on them. But, FWIW, it's works great in P5 on clothes with matching FBMs to the figures. 2) Is some sort of fitting script for megaionstorm products still doable? Sure, but it'll be only useful for that merchant's product line, and as long as the merchant maintains the morphing/naming conventions. The script is going to look more like a kludge, but it's still doable. 3) Honestly, I started to think that I'd drop this script and leave this problem for megaionstorm. (No, I haven't contacted him.) But you know, since I'm extremely skeptical that anything I write will have any impact on anyone's buying decisions, and since I'm just killing time until my P6 arrives, I think I'll still work on it. Have a good one...I'll post something if it looks promising.
Most of the megaionstorm morphs that I have do not have the multiple versions like the BillyT swimsuit one obviously does. What I have seen mostly is just the standard morph name and possibly one with pbm as prefix. Probably could have a very useful script that didn't bother with the alternative morphs like you mentioned. Anyways thanks a lot, and I hope you see something positive in this. If megaionstorm's sales are high there could be a lot of people who could use this script.
Ok ! In the chest you can found three morphs: Breastsize6, pbmBreastSize6_lC, pbmBreastSize6_rC. For the 'BreastSize6' morph you can found a 'pbmBreastSize6_lC' morph, in the left collar, and a 'pbmBreastSize6_rC' morph, in the right collar. The 'pbmBreastSize6_lC' morph is for the 'BreastSize6' morph in the left collar. The 'pbmBreastSize6_rC' morph is for the 'BreastSize6' morph in the right collar.
Megaionstorm:
I don't model clothes, so forgive my ignorance, but I hope you can clarify a few things:
Why do you have a specific 'Breastsize6' dial in the chest bodypart if user is instructed to ignore it and just spin the two pbm Breastsize6 dials instead? Or am I confused on your readme instructions? (See post 3 above -- I'm referring to your readme snippet #1)
Also, how many breast morphs does snippet #1 apply to? Breastsize1 through Breastsize8, I assume, but what about morphs like 'BreastDiameter'? Can I assume that snippet #1 applies to all morphs with the word 'breast' in them?
Thanks
Message edited on: 03/24/2005 11:05
Not all poser user used a poser version who can use phyton scripts.
Poser 4.03 and lower can't used this scripts !!!
And this poser users can i help with my 'clothing morph' sets !
And a price $5.- is the lowest price who is posible in the renderosity marketplace.
Message edited on: 03/24/2005 11:30
Message edited on: 03/24/2005 11:31
megaionstorm: I certainly wasn't complaining about the price you charge for your products. I was just mulling over whether I wanted to write a script that focused exclusively on a single merchant's product line. And the short answer is: sure, why not? I think it's analogous to people who create free textures for someone else's clothing sets. Nothing wrong with that. And, of course, you are right -- a python script is only useful to those with PP, P5 or P6. mike: I should have something new posted this weekend.
Is this script working? Any updates?
JohnJDesigns - Digital Fabrics for 3D
Commercial
Portfolio
Poser Art
Portfolio
Renderosity
Store
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.
I have been using the autoconform script to add clothes to selected figure and it works very nicely, but is it possible to transfer body morphs (full or partial) to the clothes appropriately. I assume that the clothing has the required morphs but may only have pbms where the main figure has fbms. This would essentially remove all the tedium of using clothing enhanced by Megianstorms products for example. If a full body morphs exists on the parent then if exist on it would be copied to the clothes fbm if it exists. Otherwise it would be copied to pbms for each part that contains the named morph. I don't know if this is possible but if so it would come in very handy. Thanks.
Message edited on: 03/14/2005 17:00