Discussion:
Depth Map Expression
(too old to reply)
i***@adobeforums.com
2008-07-18 23:12:00 UTC
Permalink
I thought I would do this myself, but I quickly realized that I don't have the knowhow to make it happen.

What I planned to do was to write an expression which can be applied to a 2D solid at the top of a comp.

The expression would through each pixel in a composition, and find the front-most 3D layer on each particular pixel. It would then return a greyscale value which is determined by the distance between that pixel on the front-most layer and a specified point.

The problem I ran into is that the only way I could figure out of *returning* color values on particular pixels was to either use (on a 2k image, let's say) roughly 2 million copies of the circle filter, or create an expression which generates roughly 2 million keyframes per frame for the write-on filter! I'm pretty sure neither of these is a viable option.

I'd love to figure this out, though. Because I think this expression would be enormously useful. I know there's a $200 plugin which does something similar, but I'm not sure it's as flexible, and I know it anti-aliases which is death for many depth-map applications.
A***@adobeforums.com
2008-07-19 00:38:47 UTC
Permalink
This isn't a good job for expressions. While it is theoretically possible to evaluate every pixel in a comp, the expression in question would be excruciatingly slow, and would probably time out. And, as you've already figured out, there's no practical way to actually get at the depth map data even if you could calculate it.
i***@adobeforums.com
2008-07-19 00:54:52 UTC
Permalink
Hmmmm... You'd think this would be something which was possible to do in AE natively. Not sure I can spend $200 for a plugin to do just this.
A***@adobeforums.com
2008-07-19 01:35:55 UTC
Permalink
Expressions are really much more about calculating a limited number of values for animation. Image processing is the domain of plugins.
Loading...