Tuesday, December 6, 2011

Selecting layers

I am trying to do the following:



for each layer

{

if bitmap grab all the pixels

if vector mask get the info

}



seems simple... and yet the doc is so artfully vague and without clear structure, I don't see how to do that.



I have gone through the outbound sample, and started to write some simple code and here's where I am at:



-I can get the number of layers, their type and size

-I can grab the pixels from the first layer



this is it: I do not know how I can select another layer; there is nothing in the doc about this,I do not know how I can parse the vector data, there is nothing in the doc either.

everything relies on the update progress callback,however I can only find in the SDK's header files what fields are read by the callback, it's not in the doc once again and it's all but clear from the header file.



I emailed Adobe, but I did not get a clear answer:

-%26gt; is the vector data available from the SDK?

-%26gt; how can I select which layer I want to retrieve pixels from?



I found scripting can access all this, but I've to do a lot of processing and it has to be fast; and it seems that even handling binary files with scripts is going to be a hassle.
Selecting layers
What you are trying - all is possible via exportParamBlock members. Study documentation and you have to play a lot with that.



I was able to get layers only rasterized. Vector information is not accessible via export plugin.



What you are trying to do would be probably possible only from automation plugin.

No comments:

Post a Comment