Author Topic: Lens Constructor and Advanced Lens Effects  (Read 3996 times)

2022-05-06, 05:25:19

marchik

  • Active Users
  • **
  • Posts: 256
    • View Profile
Once again I want to raise this topic, but with a more thorough request.
Recently, I needed to do product images with a focus on photorealism, and once again ran into the annoying limitations of my lovely Corona in this matter.
We have a nice customizable DOF effect inside the corona camera, with almost all the necessary settings, and even the ability to add a custom image for the aperture shape, but...

Chromatic Aberrations
The first obstacle was the actual impossibility to add proper chromatic aberrations when using DOF inside corona, in case of any post processing methods to add this effect we have to blur or distort the images even more, summing this blur with the already existing DOF effect on the render

Adding a geometric lens with dispersion in front of the camera or simulating aberrations using a custom aperture shape image cannot correctly reproduce different types of aberrations that depend on the geometric position in the frame field and the lens scheme itself. Of course, in my question I turn to the wonderful DOF Pro plugin by Richard Rosenman, in the corresponding section on his website it is described in detail about different types of chromatic and achromatic aberrations and what exactly influences their appearance.
some examples

At the moment I don't know of any way to add longitudinal and lateral achromatic aberration to an image with an already existing DOF effect other than manually

I created a fairly complex setup in Fusion that adds different types of aberrations and mixes them using a Z-Depth map, but firstly, this approach seems to me not very user-friendly, and secondly, where you can manually refine on static frames, this will be impossible to do when rendering animation

Lens Flares
At the moment, we can only add Lens Flare effect when post-processing in third-party packages, although even real-time engines such as Unreal Engine and Yebis system inside Opengl rendering in Substance Painter/Designer can do this, and our ultra-realistic ray-tracing proudly CPU-based engine simply can not, I think this is a slightly strange omission, with all due respect.

Lens Dirt overlays etc
I will not talk about additional effects that can be added in post-processing, but which are much more efficient to simulate inside the render engine itself, because. for their correct imitation, each user needs to know at least the basic structure of optical schemes, use additional plug-ins, and so on, while the render engine, working in an interconnected system and receiving complete information about the image, can reproduce such effects much more accurately and correctly.

Current Situation
Speaking of the current situation and Corona's commitment to simplicity and user-friendliness, at the moment the user can control the shape of the aperture in 2 places independently - in the Custom Aperture section of Bloom & Glare, in and Bokeh section in the camera settings, meanwhile, these 2 parameters absolutely independent and if we set the bladed aperture in the camera settings, glares will still be calculated for circular and vice versa.
I think this confuses new users, and does not add convenience to the old ones, because in order to correctly simulate a photorealistic image, you need to manually link all these parameters, and I have already said about those effects that we cannot imitate with all our desire.

What do I suggest
Given all of the above, I came up with the idea of ​​one universal LensConstructor, which in its interface would cumulatively collect all the parameters that are responsible for all lens effects and would allow using a limited number of parameters and presets in the form of pre-made optical lens schemes to set the appearance of all these effects.
Schematically, I suggested how it could look, and it can be located in  the camera settings, similar to the current opening tonmapping window, otherwise it can be finalized from the current custom aperture shape interface that is in the bloom and glare settings.

The aperture shape created using the constructor or a selected preset from the most popular 10-15 photo and cinema lenses should control all effects at the same time, including both bokeh shape and glare, simplifying user interaction with our engine and providing additional features.

PS In the current iteration of the development of the 9th version, you have prioritized the refinement of existing features and I perfectly understand that these features are not a priority, and in general these effects remain the lot of enthusiasts, but I want to remind you that caustics used to be like that, and now any user can access it using one checkbox, thanks to you and thanks for your attention!
 




« Last Edit: 2022-05-06, 06:07:23 by marchik »

2022-05-06, 08:35:34
Reply #1

Elizaveta_Ivanova

  • Active Users
  • **
  • Posts: 19
    • View Profile
I think that's a really amazing suggestion.
I sometimes have to add a lens flare effect in third-party programs, too

2022-05-06, 13:17:03
Reply #2

aaouviz

  • Active Users
  • **
  • Posts: 882
    • View Profile
    • Another Angle 3D

2022-05-10, 14:54:46
Reply #3

mikinik

  • Active Users
  • **
  • Posts: 20
    • View Profile
Oh, great idea! Support it, I need it too.
I think it will be +100 to realism.

2022-06-11, 08:03:54
Reply #4

marchik

  • Active Users
  • **
  • Posts: 256
    • View Profile
just another example of how the current state of things is confusing for less experienced users as it is somewhat counter-intuitive

https://forum.corona-renderer.com/index.php?topic=36964.0;topicseen

2022-06-12, 03:02:32
Reply #5

burnin

  • Active Users
  • **
  • Posts: 1532
    • View Profile
Used to be possible, but now colored Aperture Custom shape isn't supported anymore (thus no CA w/ DOF).

2023-12-10, 12:07:53
Reply #6

marchik

  • Active Users
  • **
  • Posts: 256
    • View Profile


I think the time has come :D
 Dear developers, if you are still going to add this, can you please implement it not like in the V-ray, but with the ability to create longditudinal and lateral aberrations with front/back or left/right  green/magenta differentiation.

2023-12-11, 10:02:40
Reply #7

John_Do

  • Active Users
  • **
  • Posts: 119
    • View Profile
I'm really disappointed by the new CA post-FX in V-Ray, looks like a missed opportunity to get a nicely simulated CA. Results feel cheap and on the same level as simulating CA with PS Lens Correction filter.

https://youtu.be/Vf8T0XXQie0?t=541

BTW I like your proposal about a lens constructor, it would require a serious work on the usability side of things to match Corona ethos, but imo it seems logical at some point to go full speed with a simulated lens rather than adding another "easily breakable" post-FX layer. I guess a performance hit can't be avoided but maybe it be could negligible these days considering modern CPU compute power ? Something similar has already been created for Arnold : http://www.lentil.xyz

Octane also got Chromatic Aberrations support recently, and while it says it is a post-effect it feels like it fully uses the camera settings to generate the effect (some really exagerated examples but it's a new feature so I struggled to find more).





2023-12-11, 10:48:04
Reply #8

romullus

  • Global Moderator
  • Active Users
  • ****
  • Posts: 8779
  • Let's move this topic, shall we?
    • View Profile
    • My Models
I would happily take even basic chromatic aberration post effect, but advanced lens constructor would be fantastic to have. +1
I'm not Corona Team member. Everything i say, is my personal opinion only.
My Models | My Videos | My Pictures

2023-12-12, 01:16:55
Reply #9

marchik

  • Active Users
  • **
  • Posts: 256
    • View Profile

BTW I like your proposal about a lens constructor, it would require a serious work on the usability side of things to match Corona ethos, but imo it seems logical at some point to go full speed with a simulated lens rather than adding another "easily breakable" post-FX layer. I guess a performance hit can't be avoided but maybe it be could negligible these days considering modern CPU compute power ? Something similar has already been created for Arnold : http://www.lentil.xyz

Octane also got Chromatic Aberrations support recently, and while it says it is a post-effect it feels like it fully uses the camera settings to generate the effect (some really exagerated examples but it's a new feature so I struggled to find more).


great example with Octane, lens flares looks magical, exactly what I would like to see in Corona. It’s a bit of a pity that this all comes to us with some delay.

Although I remember how Octane showed some kind of separate fabric shader in their presentations and in the end I could not find it in the release version :D

I would happily take even basic chromatic aberration post effect, but advanced lens constructor would be fantastic to have. +1

Thank you for your response, romullus, I’m very glad that this topic has attracted attention again. After I initially created it, it seems to me that no one simply noticed it.

2023-12-12, 18:20:57
Reply #10

piotrus3333

  • Active Users
  • **
  • Posts: 230
    • View Profile
Marcin Piotrowski
youtube

2023-12-12, 20:46:57
Reply #11

marchik

  • Active Users
  • **
  • Posts: 256
    • View Profile

2023-12-15, 13:43:16
Reply #12

Aram Avetisyan

  • Corona Team
  • Active Users
  • ****
  • Posts: 543
    • View Profile
Hi,

We have similar requests.

As I understand, chromatic aberrations will be the most wanted/used thing from the listed ones, so I will try to pushing the existing feature request.
Generally, New VFB with new improvements is planned. If such effects (or a menu/rollout for them) can make into it, that will be great.

(Internal ID=466224644)
Aram Avetisyan | chaos-corona.com
Chaos Corona Support Representative | contact us

2023-12-16, 02:44:27
Reply #13

marchik

  • Active Users
  • **
  • Posts: 256
    • View Profile
Hi,

We have similar requests.

As I understand, chromatic aberrations will be the most wanted/used thing from the listed ones, so I will try to pushing the existing feature request.
Generally, New VFB with new improvements is planned. If such effects (or a menu/rollout for them) can make into it, that will be great.

(Internal ID=466224644)

big thanks, yes, correct chromatic aberrations that respond to the focus point and lens flare depending on the current aperture shape would be a very desirable feature for me

2023-12-16, 22:57:59
Reply #14

marchik

  • Active Users
  • **
  • Posts: 256
    • View Profile
setup for axial aberration.
Corona has all you need for it but it will be slow:
https://forums.chaos.com/forum/v-ray-for-3ds-max-forums/v-ray-for-3ds-max-general/983612-chromatic-aberration-with-vray?p=1167560#post1167560

How this effect could be achieved in Corona if we do not have an additive (shellac) mode for Coronalayeredmtl and we cannot set ior values less than 1.0?

lentil add-on results from the original topic look awesome btw
« Last Edit: 2023-12-16, 23:01:34 by marchik »