5 Replies Latest reply on Nov 23, 2012 8:50 AM by Rick Gerard

    How to save effect specific data while open/close progect?

    lahmatuk_petruk

      I am trying to develop custom effect. I have list of values (int) which I want to save them on project close and retrive them while reopening  project.

      These values are unique for every instance of plugin. It must be the same as UI PARAMETERS. It should work for several plugins in one project.

       

      Thanks

        • 1. Re: How to save effect specific data while open/close progect?
          Dave LaRonde Level 6

          All changes to an effect applied to a layer are saved when you save the AE project.  They will be there when you open the project again.

           

          Do you actually mean something else?  If so, please elaborate.

          • 2. Re: How to save effect specific data while open/close progect?
            marky_

            As I wrote I need to save some variables . let it be some struct

             

            typedef struct {

                 int foo1;

                 double foo2;

            }

             

            I tried to save this struct in sequence data. And everythin works. I can close project then open and read values from sequence data in this struct.

             

            But as I tested that data is same for every instance of my effect (maybee layer as I used only one - I am not sure).  I've placed on layer two instances of rectangle and put my effect on both rectangles. So these two instances of effect use the same sequence data. This is not what I need.

             

            Also I found that sets of parameters which I add using PF_ADD_SLIDER and so .. are different for two instances. So I think my data should be placed in the same place. This memory should be different for every instance of my effect.

             

            My question is what memory or variable or param should I use for such purpose?

            • 3. Re: How to save effect specific data while open/close progect?
              Dave LaRonde Level 6

              You're trying to save a "one size fits all" expression.  If you standardize your variable nomemclature for a specific animated property, the expression can be saved in a layer in an AE comp, or in a text file from which you can copy and paste.

              • 4. Re: How to save effect specific data while open/close progect?
                marky_ Level 1

                It's not clear for me "one size fits all".

                 

                I can make an example with slider param. I put create two inctances of effect , in first instance user set slider equal 7 and in second set slider equal to 4.

                After user close project and then open it first will be 7 and second 4.

                 

                In my case value should be array of 100 integers instead of int(slider value). Such array can be saved in a layer in an AE comp?

                 

                Another question there is "arbitrary param" . For me sound likely what I need . Can it be used for array or it is just for 8 bytes value?

                 

                I am really new in this )

                 

                Thanks

                • 5. Re: How to save effect specific data while open/close progect?
                  Rick Gerard Adobe Community Professional & MVP

                  Save each element of your expression as an animation preset and you should end up with what you want.