Save figure/prop sample

I'd like to write a script that reads the targeted character (genesis i.e) and then saves all of the figures fit/parented to it. Say you fit an outfit with a large number of pieces created to V4 and you fitted them to Genesis and want to save the individual pieces seperately.   In order to do this, I need the Save Figure/prop sample, which the link is broken in the documentation.  Now if anyone knows how to do this and wants to volunteer, I won't object, but I'd really like to learn to script myself and this seems like a good project for me.  Any ideas?

Comments

  • djigneodjigneo Posts: 283

    I think the "prop" feature is deprecated. I think you want to save a pose preset:

    http://docs.daz3d.com/doku.php/public/software/dazstudio/4/referenceguide/scripting/api_reference/samples/file_io/save_duf_pose/start

    Algorithm is something like:

    1. Find selected object

    2. Find all objects underneath selected object, save Pose preset for each one

     

    Either that or export scene sub-sets so you can just import the already posed objects.

  • rbtwhizrbtwhiz Posts: 2,267

    Prop is not deprecated.  The support asset saving samples aren't available because I create the samples on "my own time", and I haven't had much in the way of "my own time" for quite a while.  Where I would normally spend time at night and on weekends, I've been otherwise occupied with aggressive deadlines and life events. My lack of responses in the forums of late is due to the same.

    -Rob

  • djigneodjigneo Posts: 283
    edited August 2015

    Oops, sorry for the misinformation.

    You can probably figure out how to save the prop preset from code by referring to the 'pose preset' link above.

    // Get the asset IO managervar oAssetIOMgr = App.getAssetIOMgr();// Define the class name of the asset filter we want to usevar sClassName = "DzPoseAssetFilter";// Find the index of the asset filter with the class name we wantvar nAssetIOFilter = oAssetIOMgr.findFilter( sClassName );// If we've found an asset filter with the class name we wantedif( nAssetIOFilter > -1 ){	print("found");} else {	print("not found");}

    Returns "found" for me. I'd give that a stab.

     

    Post edited by djigneo on
Sign In or Register to comment.