Hello, I've been using PixMap effect in my lens distortion encoding system, which uses two separate STMaps; ViewMap which samples FootageMap to then sample the footage. It is nice, as it can not only rectify fisheye footage, but also transition between distortions by simply blending ViewMaps of different type in preComp. Imagine transition from anamorphic lens to wide-angle from extreme fisheye source.
ViewMaps map to equidistant coordinate square texture of given ViewMap FOV value. Blue channel encodes vignette. And it looks like this:
FootageMaps map from equidistant space of given FootageMap FOV to the footage and looks like this:
If there's a mismatch between view and footage map FOV, simple tiling scaling ( tile = ViewMapFOV/FootageMapFOV ) is applied when sampling the FootageMap.
I wanted to share that.
Anyway since ViewMap basically encodes theta angle, the coordinates can be rotated, giving full camera rotation in the footage (sic!). Maybe someone or you would like to create that color effect plugin for rotating ViewMaps? Here's the full code in GLSL:
There are four user input values FOV_ViewMap which is the FOV value in degrees, always a whole number; Roll_rot_angle, Tilt_rot_angle, Pan_rot_angle in degrees.
Hope you like it.