How to use DzInstanceGroupNode Class ?

JPiatJPiat Posts: 70
edited December 1969 in Daz Script Developer Discussion

Using DzInstanceNode sample code from Rbtwhiz, I create a script for duplicate and locate multiple instances but it's slow.
Using my script : 3 secondes for 100 duplications.
Inside daz studio using the "New node instances" function : no waiting time.

The DzInstanceGroupNode class seems to do the job but I really don't understand how to use it.

Any help ?

Julien

Comments

  • rbtwhizrbtwhiz Posts: 2,250
    edited May 2014

    The Create > New Node Instances... action is compiled C++; i.e. a plugin built using the SDK. The Create Instance sample is a script. A script will run slower than compiled C++. Interpreted languages are typically slower than compiled languages in general.

    A DzInstanceGroupNode is designed to reduce consumed system resources. I've added a Create Instance Group sample to show how its used. It will run slower than the compiled C++ equivalent; i.e. Edit > Object > Instances > Group Like Sibling Instances.

    -Rob

    Post edited by rbtwhiz on
  • JPiatJPiat Posts: 70
    edited December 1969

    Thank's a lot. I update my script. It's not faster but it's better.
    I don't know the purpose of sibling instance, Now I understand.

    Next step : Distribute instances over a surface... Like a tiny ecosystem.

    Create a plugin is another adventure. 32/64 bits Windows/Mac...

    Julien

Sign In or Register to comment.