8 Replies Latest reply on Jun 17, 2016 4:28 AM by jk1m2

    custom importer

    jk1m2 Level 1

      We have a custom importer plugin for premiere CS6.

       

      We dont save a custom file on disk, but we render the frames demanded by Premiere framework on the fly and return the data in imImportImageRec in imImportImage call.

       

      1) The sequence when we create a new instance goes like

       

      imGetPrefs8   - we show a custom entry dialog here - store the result in a global variable which is accessed in imGetInfo8.

       

      imGetInfo8     - with private data pointer (where we store pointer to our custom class which actually renders the data( based on the variable set in imGetPrefs8 )

       

      imImportImage - with private data pointer filled in imGetInfo8 - render here based on the frame number received using the private data.

       

       

      2) And when we save and load the instance we get a call to imGetInfo8  with the private data( based on which  we create a instance of our custom class to render data)

      and subsequent calls to imImportImage with the private data filled in imGetInfo8.

       

       

      3) Now the case comes when we modify the existing instance by double clicking it.

      We get a call to imGetPrefs8  but not  imGetInfo8.

       

      but we are not able to modify the private data as per user changes done in imGetPrefs8 , as we dont get a call to imGetInfo8.

      So the subsequent calls to imImportImage work with the old private data, hence the changes dont reflect.

       

      How should we go about it?

      Guide.

        • 1. Re: custom importer
          Rallymax-forum Level 3

          in imGetPrefs8 why don't you check for privateInstance == NULL then create as needed.

          If != NULL call your modification function.

          imGetInfo89 should only populate the selector struct with info from the private data (already allocated by imGetPrefs8).

           

          I've never looked at the synthetic importer example but this is exactly what you're doing so that should be your starting code to hack on.

          • 2. Re: custom importer
            jk1m2 Level 1

            The private data (instance data) pointer has to be allocated in imGetInfo and not imGetPrefs.

            The pointer which is allocated in inGetInfo is only received in imImportImage not which is allocated in imGetPrefs.

             


            • 3. Re: custom importer
              Zac Lam Adobe Employee

              Agreed, it is not ideal that imGetInfo8 is not called (bug # 3010899).  Would you be able to workaround it by checking some basic attributes in imImportImage (perhaps by making some comparisons with the prefs) to make sure that your custom class in privateData is up-to-date?  If the class is out-of-date, you could modify it before returning from imImportImage.

              1 person found this helpful
              • 4. Re: custom importer
                bvjx

                Any progress on bug #3010899?

                • 5. Re: custom importer
                  Zac Lam Adobe Employee

                  Hi William,

                   

                  Yes, this bug was fixed in the 2014 release of Premiere Pro CC.

                  • 6. Re: custom importer
                    bvjx Level 1

                    Thanks, Zac.   I've noticed that with PPro CC 2015, imGetInfo8 is not called following an "edit" via imGetPrefs8.

                    • 7. Re: custom importer
                      Zac Lam Adobe Employee

                      Hi William,

                       

                      Have you tried to reproduce the behavior using the Synth_Import or SDK_Custom_Import samples?  I'm not able to reproduce the problem with either sample in CC 2015.

                      • 8. Re: custom importer
                        jk1m2 Level 1

                        Hi Zac

                         

                        Related to the modification query we initially raised, We checked with Premiere Pro CC2015, that after GetPrefs, GetInfo, imCloseFile

                        is also called which actually closes the instance.

                        I checked it with the sample SDK_Custom_Import also.

                        The sample also crashes Premeire, the second time I modify.

                         

                        Best Regards

                        Jasleen