dsmpixel
VEX function
Reads the z-records stored in a pixel of a deep shadow map or deep camera map.
Contexts: displace, fog, light, photon, shadow, surface
See also: teximport
-
int dsmpixel(string map, channel; int x, y; float &values[]) -
int dsmpixel(string map, channel; int x, y; vector &values[]) -
int dsmpixel(string map, channel; int x, y; vector4 &values[])
Each pixel of a deep shadow map channel has multiple values. This function will extract the list of the values associated with the channel for the given pixel.
Returns 1 on success and 0 on failure. If the function fails, the values variable will not be modified, and so may be left uninitialized.
A DSM will always have Pz and Of channels. The Pz channel stores the z-depth associated with each record. The Of channel stores the opacity.