Anyone out there handy with the After Effects plug-in SDK? at

Go Back   DV Info Net > Cross-Platform Post Production Solutions > Digital Compositing and Effects

Digital Compositing and Effects
After Effects, Shake and everything else.

Thread Tools Search this Thread
Old November 7th, 2005, 12:46 PM   #1
Major Player
Join Date: Mar 2005
Location: Brighton, England
Posts: 225
Anyone out there handy with the After Effects plug-in SDK?

Hi all,

I'm having a little play around with AE's plug-in interface, but I've hit a bit of a problem:

For one of my filters I need to bring the image out of AE's LayerDef structure and into a user defined data type (probably an array of PF_Pixels, but I'm not sure at the moment) so that I don't need to use the iterate() function in order to traverse the image.

However, I can't work out a few simple things having not used the API before and having found it difficult to obtain useful info.

What I need to do is write a couple of functions to get a pixel from the current layer by x,y co-ordinate and put a pixel into the output buffer in the same way.

Also, I'm having trouble finding the current layer in the In_data structure that I'm passed - the documentation states that in the params[] array param[0] is always the current layer, but param[0] contains a PF_Paramdef value, not a PF_Layerdef, as you would expect to find for a layer, current or otherwise...

I know these are probably very easy to do once you have the knowledge but I'm pretty stuck. My C++ skills should still be good enough (if a touch rusty!) to handle coding the effect once I've got the data in a format outside of AE's representation, but I'm stuck until I can do that - any help would be most gratefully received!!!

The functions I've written for getting and putting pixels I'll include below, but I'm unable to test them as I can't get at the current layer :(

In Visual Studio (C++) on a PC the functions are these:

PF_Pixel *getPixel8(PF_LayerDef &def, int x, int y) {
return (PF_Pixel*)((char*) + (y * def.rowbytes) + (x * sizeof(PF_Pixel)));

void putPixel8(PF_LayerDef def, int x, int y, PF_Pixel pix) {
A_long pinter = (char)pix.alpha + (char) + (char) + (char); = (PF_Pixel*)(pinter + (y * def.rowbytes) + (x * sizeof(PF_Pixel)));

Thanks guys, looking forward to getting the benefit of some serious techie knowledge!....
Dominic Jones is offline   Reply

DV Info Net refers all where-to-buy and where-to-rent questions exclusively to these trusted full line dealers and rental houses...

Professional Video
(800) 833-4801
Portland, OR

B&H Photo Video
(866) 521-7381
New York, NY

(973) 335-4460
Mountain Lakes, NJ

Abel Cine Tech
(888) 700-4416
N.Y. NY & L.A. CA

Precision Camera
(800) 677-1023
Austin, TX

DV Info Net also encourages you to support local businesses and buy from an authorized dealer in your neighborhood.
  You are here: DV Info Net > Cross-Platform Post Production Solutions > Digital Compositing and Effects

Thread Tools Search this Thread
Search this Thread:

Advanced Search



All times are GMT -6. The time now is 02:53 PM.

DV Info Net -- Real Names, Real People, Real Info!
1998-2017 The Digital Video Information Network