I'm trying to get my exporter to simultaneously export 2 separate files (one for audio, one for video):
(1) *.wav file (for PCM audio)
(2) *.m4v file (for encoded H264 video)
The exported WAV & M4V files are readable in external tools - So I have the basic exporting routines writing out correct fileData.
But so far, I can do ONE at a time -- i.e. I have manually hardcoded the 'supportsAudio' and 'supportsVideo' to to be mutually exclusive, and changed my exDoExport() routine to behave accordingly.
I want my exporter to support any combination of audio/video exporter: audio-only, video-only, or audio + video
(1) audio-only : write out a single *.WAV file
(2) video-only : write out a single *.m4V file
(3) audio+video : write out both files (*.WAV + *.M4V)
But I can't figure out how to do this through the Premiere Pro CS6 SDK.
I've tried writing handlers for the selector exSelQueryOutputFileList. I followed the directions carefully (about PPro calling the selector 3 times in a row.) I've stepped through my handler using VS2010's debugger, so I *know* that CS6 is calling me 3 times. And I have also confirmed that I correctly set the numOutputFiles, outputFileRecs.pathLength, and outputFileRecs.path.
But when the 'export' method is finally engaged, CS6 only calls the exSelExport selector ONCE, and it only passes the first outputFileRec[#0]. So there is no opportunity for my exporter code to utilize the 2 outputFileRecs that were allocated previously.
....How is this supposed to work?!?
That's normal that exSelExport is called exactly once. The file locations you specify during exSelQueryOutputFileList are used for the FTP panel and other areas, but you still need to write out all the files during exSelExport.
So is it acceptable for the plugin to directly call the C-library functions [fopen() + fwrite() + fclose()] to create and write out the files?
The plugin is not obligated to use the Adobe generated handle <exDoExportRec.fileObject>?
Yes, that is fine since you don't receive a fileObject for the other files you'll be writing.