Equirectangular blurring/glow effect?

Hello Everyone,

I am in the midst of working on a 360 degree video to post on Youtube. I’m using cycles equirectangular camera. My setup is an animated star field scene which I am using as the backdrop and I am compositing a foreground scene on top of. I hope that made sense.

I wanted to add a glow effect to the star background, and when I popped the rendered result into a 360 viewer I found it to be mostly pleasing, until I noticed the distortion at the seams and the poles of the image.

If this were a still image I would probably render it out and edited the texture manually in gimp or photoshop, but as it is an animated scene and I want something that most accurately matches the equirectangular lense, I really want to do this in the blender compositor.

I have searched online but have not found any tips or solutions for this scenario. I have also tried looking for how to convert an equirectangular image into a box map to try and apply the blur that way, then load the box map into blender again. I have also looked into coding and I’m only a basic python coder and what I found I didn’t understand.

I’ve tried several compositor node setups, different blur settings as well as the lense distortion node.

And lastly I’ve tried using a sphere placed around the camera (with a shell and without) with various combinations of transparent shader-glass shader-add shaders, transparent-volume scattering-add shaders, transparent shaders + any shader I could think of with a roughness parameter or bump mapping… With no luck of anything which blurred the image without also darkening the image.

Any ideas, solutions, or general brainstorming would be much appreciated, thank you.
Veggiet.

Please post some blend-files. “Darkening the image” sounds like a separate (Alpha-related) problem, and/or an unwanted artifact caused by your particular selection of, say, Mix-node modes, which could be corrected. I can’t anticipate what exactly you mean by “distortion at the seams and poles of the image,” especially with regard to the (two-dimensional) compositor.

And finally: “in your judgment, will the audience actually notice, or care, or be distracted by it to the detriment of their enjoyment of the show?” Just sayin’ … “how seriously does this artifact need fixing?”

Thank you for replying, to answer your last question, I think the distortion is pretty noticeable. I’ve watched many 360 videos and the ones that don’t handle poles and seams properly always bug me. Here is a test video I posted privately to Youtube.

The glow affect is just large enough to be noticeable, when you look up and down you’ll notice the glow turns into streaks surrounding the poles, the seam is less noticeable. i’d like to perhap apply a couple of other glow filters to fine-tune the image, but I don’t want to unless I can make a quality effect. The goal is a more realistic expanding universe, so I want to continue with other combinations of particle and or physics systems.

when you look up and down you’ll notice the glow turns into streaks surrounding the poles,

this is called “polar pinch”

and is caused by the image interpretation

use “nearest neighbor”

the Gaussian and cubic interpretation is one of the CAUSES of this

this is a trade off for using “simple cylindrical map” the poles ARE distorted
the top line and bottom line of pixels are really ONLY ONE pixel - " the pole "

Cube maps solve the pole issue BUT add other problems

Cube maps can help as JohnVV wrote. I would blend the sperical map with cube map so that pole areas are from cube map.

Filter that works correctly on spherical image must be designed so that it does its calculations in angular space. Projections distort the image, there is no way around it.

Thank you all for your input. After JohnVV suggested “nearest neighbor” I began doing test images with different blur modes to see what they looked like, I found that the “flat” blur mode to be the best out of the gate (which fits because most likely being based on nearest neighbor), but while flat looks best at the poles it is uglier overall and I still wasn’t satisfied. I decided to start experimenting with a gradient to control the shape of the blur over the image. I think I have a node group that will work for blur sizes much less than 10% of the image which is the limit of what I think I will use. Here is the node group:


and the tests I did:



Image taken of the pole of an inverted globe image, blurring at 3%


blurring at 5%, the seam becomes annoying, still need to fix that.


blurring at 10% pole pinching becomes evident, but it seems softer than it does with your basic gaussian filter.


Finally a glow effect, created with 5% blurring.

And now a node group to get rid of the seam:





And now a couple test videos:
[video]https://youtu.be/C72uiyoWUOI[/video]
[video]https://youtu.be/BmHxslk5DWQ[/video]
there is a black seam that seems to have been inserted by either Youtube or Adobe Media Converter.

I notice a small issue when the blur is low, close to zero, the blur seems to get horizontally wider