Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Fubax

12
Posts
2
Following
A member registered Apr 08, 2019

Recent community posts

(4 edits)

Here's a demo, mapping from Panini to Rectilinear to Stereographic fisheye then panini.


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.

PixMap community · Replied to Fubax in Bugs

Basically the UV coordinates start from edge to edge, that's why first pixel center has a value of 0.5/dimensions and pixel coordinates start from the center of first pixel.

PixMap community · Replied to Wunkolo in Bugs
(1 edit)

Great work, anyway there's one last thing wrong with PixMap compared to B.Map, it's the coordinate mapping. The B.Map correctly maps UV coordinates to pixel position, while PixMap does not take account for the half-pixel offset in the UV space, as the center of first pixel is 0.5/Dimensions.

The correct formula for mapping pixel index coordinates XY starting from [0, 0] to UV is [U, V] = [(X+0.5)/Width, (Y+0.5)/Height]
And for mapping of UV to XY is [X, Y] = [U*Width-0.5, V*Height-0.5]. Width and Height are the dimensions of sampled texture as 1920x1080.

PixMap community · Replied to Wunkolo in Bugs

Fantastic! Works very great. Thank you ☺

PixMap community · Replied to Wunkolo in Bugs
(1 edit)

Thank you, seems to be more stable, but the tiling is pinned to corner which messes up scaling of STMaps, compared to B.Map where it is pinned to center and works OK. Also it flips the texture vertically.

I'm having the same thing, solution is to set Y tile to negative number.

PixMap community · Replied to Wunkolo in Bugs
(1 edit)

I would say that B.Map (beta) works as expected regarding this issue. I'm generating my UV texture using Shadron app and GLSL shaders, they are in RGBAF32LE pixel format TIFF file. Also regarding cropping, the B.Map (beta) works flawlessly, here in PixMap it seems that base resolution from which the texture normalized coordinates are calculated is taken from the STMap rather than from the sampled texture.

Only issue not solved in B.Map (beta) is that it crashes when the layer with applied effect is pre-composed, while the effect is enabled.

(1 edit)

One way to "simulate" anisotropic filtering is to pre-compose the UV map and increase the resolution of that pre-composition, like  4x to get 4xMSAA.

When can we expect this feature? Thanks for the plugin

PixMap community · Posted in Bugs
(1 edit)

Hello, thanks for the plugin.

I have noticed that when setting the V repeat to "clamp" I have to offset.y to the negative height of the UV map, otherwise, the mapped texture is below the bottom edge :/ It looks like some miscalculation bug in the plugin.

Also when the sampled texture is bigger than the UV map resolution, it gets cropped.
I use After Effects CS6 on Windows 10

Hello, could the effect use mip-mapping and anisotropic-filtering for really distorted UVs?