[GEM-dev] Re: [GEM-cvs] Gem/src/Pixes pix_freeframe.cpp,1.2,1.3

james tittle tigital at mac.com
Fri Apr 29 17:11:12 CEST 2005


On Apr 21, 2005, at 10:59 AM, IOhannes m zmölnig wrote:

> Update of /cvsroot/pd-gem/Gem/src/Pixes
> In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23931
>
> Modified Files:
> 	pix_freeframe.cpp
> Log Message:
> initial support for loading plugins un windows and osX (still not 
> tested)

...ok, I've got this compiling on OSX now, and loading the plugin, but 
but it very quickly unloads because "no 24-bit support"...the relevent 
code here:


   if ((plugmain(FF_INITIALISE, NULL, 0)).ivalue == FF_FAIL){
     error("plugin %s: init failed", name);
     return NULL;
   }

//  plugmain(FF_DEINITIALISE,NULL,0);
   if ((plugmain(FF_GETPLUGINCAPS, (LPVOID)FF_CAP_32BITVIDEO, 0)).ivalue 
== FF_TRUE){
     if(can_rgba)*can_rgba=1;
   } else {
     if(can_rgba)*can_rgba=0;
     if ((plugmain(FF_GETPLUGINCAPS, (LPVOID)FF_CAP_24BITVIDEO, 
0)).ivalue != FF_TRUE){
       error("plugin %s: no %dbit support", name, 24);

       plugmain(FF_DEINITIALISE, NULL, 0);
       return NULL;
     }
   }

...is different than what I was using in a standalone OSX FF-host 
loader:

     if (pFreeFrameMain!=NULL) {

         pFreeFrameMain(FF_DEINITIALISE,NULL,0);

         if 
((DWORD)pFreeFrameMain(FF_GETPLUGINCAPS,(void*)2,0)==FF_TRUE) {
                 pVideoInfo->bitDepth=2;
         } else if 
((DWORD)pFreeFrameMain(FF_GETPLUGINCAPS,(void*)1,0)==FF_TRUE) {
                 pVideoInfo->bitDepth=1;
         } else if 
((DWORD)pFreeFrameMain(FF_GETPLUGINCAPS,(void*)0,0)==FF_TRUE) {
                 pVideoInfo->bitDepth=0;
         } else {
                 assert(FALSE);
                 pVideoInfo->bitDepth=2;
         }	

         pFreeFrameMain(FF_INITIALISE,pVideoInfo,0);
	
     }

...so, having not really peered into the logic too much, are you trying 
have it only load if it does RGBA?

l8r,
jamie
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/enriched
Size: 3924 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/gem-dev/attachments/20050429/469b08ba/attachment.bin>


More information about the GEM-dev mailing list