Quantcast
Channel: Adobe Community : Popular Discussions - Premiere Pro SDK
Viewing all articles
Browse latest Browse all 53010

Dummy importer

$
0
0

Hi folks,

 

I'm trying to write a dummy importer that would essentially only put a file pointer in the project for reference and archival purposes, like FCP XML translations results text file which gets imported into the project.

 

I thought that perhaps setting hasVideo and hasAudio as false would do the job, but I keep getting the "Importer returned generic error" in Premiere and "file cannot be imported - this file is damaged or unsupported".

 

Currently the entry function looks like this:

     switch (selector)     {          case imInit:               result =     SDKInit(stdParms,                                        reinterpret_cast(param1));               break;          case imGetInfo8:               result =     SDKGetInfo8(stdParms,                                             reinterpret_cast(param1),                                             reinterpret_cast(param2));               break;          case imGetIndFormat:               result =     SDKGetIndFormat(stdParms,                                                  reinterpret_cast(param1),                                                  reinterpret_cast(param2));               break;          case imGetIndPixelFormat:               result = imUnsupported;               break;          // Importers that support the Premiere Pro 2.0 API must return malSupports8 for this selector          case imGetSupports8:               result = malSupports8;               break;     }     return result;
}

 

And only these 3 selectors are supported:

imInit

imGetFormat

imGetIndFormat

 

imInit and imGetIndFormat work fine, because the importer is added to the list, and attempts to open the file. And the imGetFormat looks like this:

 

          prMALError                         result                    = malNoError;     SDKFileInfo8->hasAudio               = kPrFalse;     SDKFileInfo8->hasVideo               = kPrFalse;     return result;

 

Obviously I'm missing something, can anyone help me?


Viewing all articles
Browse latest Browse all 53010

Trending Articles