3 Replies Latest reply: Aug 4, 2013 12:39 AM by shachar carmi RSS

    AEGP: Finding app version and AEGP_GetDriverSpecVersion

    maxweel Community Member

      Hi guys (Hi Sachar ;-)),

       

      For effects I can get the current version of After Effects from PF_InData but I wanted to know if there was a way of getting it from an AEGP using suite functions.

      The only one I found in the guides (CS5 to CC) that seems to deal with host version is AEGP_GetDriverSpecVersion ... but it doesn't seem to exist. I guess the correct syntax is AEGP_GetDriverImplementationVersion, is that right?

       

      But is this the best way of checking for the host version? It should return the same thing for CS5 and CS5.5 for example.

       

      Thanks

        • 1. Re: AEGP: Finding app version and AEGP_GetDriverSpecVersion
          shachar carmi Community Member

          i checked the two functions you mentioned, and neither (ther are two similar functions in that suite) returned a value that made sense to me as the app version.

           

          you can just pluck that value from java like so:

          suites.UtilitySuite5()->AEGP_ExecuteScript(NULL, "app.version", FALSE, &resultMemH, NULL);

           

          here's the thread that shows how to retrieve a result from AEGP_ExecuteScript():

          http://forums.adobe.com/message/3625857#3625857

          • 2. Re: AEGP: Finding app version and AEGP_GetDriverSpecVersion
            maxweel Community Member

            Thanks Shachar, sorry I misspelled your name in my first post.

             

            So AEGP_GetDriverSpecVersion worked for you? It just doesn't compile if I use this function and I couldn't find its definition (XCode/SDK CS6).

             

            Here's the table of correspondance between the AEGP driver version and the After Effects version, it's given in the SDK guide of CC (Table 2). So it almost allows differenciating versions, but not distinguish CS3/4 and CS5/5.5:

             

            Release

             

            Effect API Version

             

            AEGP API Version

             

            CC (12.0)

             

            13.4


             

            CS6.0.1 (11.0.1)

             

            13.3

             

            111.0

             

            CS6 (11.0)

             

            13.2

             

            111.0

             

            CS5.5 (10.5)

             

            13.1

             

            17.0

             

            CS5 (10.0)

             

            13.0

             

            17.0

             

            CS4 (9.0)

             

            12.14

             

            16.24

             

            CS3 (8.0)

             

            12.13

             

            16.24




             

            Anyway, I had already tried using ExecuteScript but because I wanted to do version-specific stuff in the AEGP's entry point, it didn't work and AE showed a warning saying "Unable to execute script ...".

             

            I gave it another try following your post: funny enough it turns out that for ExecuteScript to work in the entry point, the plugin must be loaded after Scripting.plugin which is inside the Keyframe folder. So the plugin must have a name that comes after Keyframe in the alphabet, or be stored in a folder that comes after Keyframe.

             

            Feels obvious now but I didn't expect that at all! Feels like I've been knocking at an open door now.

            Thanks for your help

            • 3. Re: AEGP: Finding app version and AEGP_GetDriverSpecVersion
              shachar carmi Community Member

              no no no... AEGP_GetDriverSpecVersion, indeed does not exist.

              i used both AEGP_GetDriverPluginInitFuncVersion

              and AEGP_GetDriverImplementationVersion.

              this first of which, gave me number according to the Effect API Version you

              posted. (if memory serves...)

               

              as for running execute_script() from the entry point function, it is indeed

              impossible before the scripting plug-in loads.

              naming it something higher on the naming scheme than the scripting plug-in

              is a bit... unreliable...

              changes in the order of loading, or naming of the plug-ins may occur in

              future versions.

              it's much safer to wait with your call until the first idle_hook call, or

              any other call to your AEGP. (which is what i do)