Better lens flares?

  • BrandonHortman
  • Topic Author
More
9 years 2 weeks ago #1 by BrandonHortman Better lens flares? was created by BrandonHortman
If god rays could have one texture and be triggered by depth for only the sun.
and Lenz flare with a definable texture ( hopefully triggered by more than just the center of the screen)

Right now they are all using the same sprite texture

Maybe if there was a color spectrum threshold for the trigger would help to limit the lenz flares to Magic effects and torches or other fire.

K ENB is a good example of what I'm talking about.

Just putting it out there. Great work!!!!! Thanks so much.

Please Log in or Create an account to join the conversation.

  • Marty McFly
More
9 years 2 weeks ago - 9 years 2 weeks ago #2 by Marty McFly Replied by Marty McFly on topic Better lens flares?
K ENB runs on enbseries that can access HDR input so actually fire and torches are 10+ times as bright as pure white. There is no color threshold, just these things are uber bright. A red with the color value 1000 0 0 (yes HDR goes beyond 255) is more than 3 times brighter than a pure FFFFFF white. ENB HDR space goes from 0 to 65535 and for example the sun in GTA IV has a brightness value around 40000 which is about 150 times brighter than anything that is possible in LDR space which is the input of Reshade.
Last edit: 9 years 2 weeks ago by Marty McFly.
The following user(s) said Thank You: Ganossa, BrandonHortman

Please Log in or Create an account to join the conversation.

  • Ganossa
More
9 years 2 weeks ago #3 by Ganossa Replied by Ganossa on topic Better lens flares?
Its your code Marty, so thanks for dropping in :lol:

BrandonHortman wrote: If god rays could have one texture and be triggered by depth for only the sun.
and Lenz flare with a definable texture ( hopefully triggered by more than just the center of the screen)


God rays triggered by depth, is already implemented.
I have an algorithm to identify other light sources than the center but currently center makes most sense. We first have to find a smooth transition from one source to another, otherwise the lenz flare will bounce all over the screen.

BrandonHortman wrote: Right now they are all using the same sprite texture


I do not see a problem with that? If they do not bug out, both effects look pretty good with it. (especially those strong god rays)

BrandonHortman wrote: Maybe if there was a color spectrum threshold for the trigger would help to limit the lenz flares to Magic effects and torches or other fire.

K ENB is a good example of what I'm talking about.

Just putting it out there. Great work!!!!! Thanks so much.

As Marty already said, it is very hard to detect brightness for us and there is always scenes in which you detect it wrong. The only thing you can filter for is either colored light instead of pure white light or only some certain colored light. Of course that will increase the precision but it will also reduce the recall, as it is usual for those kind of problems.

What I definitely can do already, is detecting wide light in addition to bright light. This combine with detecting the brightest light source and some tricks might help to increase precision without reducing the spectrum. Let's see :side:
The following user(s) said Thank You: BrandonHortman, jas01, Aelius Maximus

Please Log in or Create an account to join the conversation.

  • BrandonHortman
  • Topic Author
More
9 years 2 weeks ago #4 by BrandonHortman Replied by BrandonHortman on topic Better lens flares?
Thanks for the replies Marty and LuciferHawk. I am highly enthusiastic about the work that you guys do.

I am sure you understand what I mean, but just to clarify.


I notice that when I select pixels with depth only the sun is triggered in Dragonage: Inquisition.

So I built this little sun ray:
[img
God Ray example for Marty and Luciferhawk by brandon.hortman , on Flickr

Then I built this for the Lens flares, not triggered by depth.

[img
Trying so hard for some rad lensflares =D by brandon.hortman , on Flickr

I dont know what triggered by depth means honestly, I am enthusiast level, but I have a high level of comprehension; so maybe this is a stupid suggestion, but what if the lenz flares could ignore pixels with depth?

As it is, If I could have that separate texture for the Lens flares than the godrays, they could still look pretty rad together.

Hope you guys have a great day =D

Please Log in or Create an account to join the conversation.

  • BrandonHortman
  • Topic Author
More
9 years 2 weeks ago #5 by BrandonHortman Replied by BrandonHortman on topic Better lens flares?
Also thank you for the very in depth answers :cheer:

Please Log in or Create an account to join the conversation.

  • Ganossa
More
9 years 2 weeks ago #6 by Ganossa Replied by Ganossa on topic Better lens flares?
"Triggered depth" is the term you used, so I though it would be more comfortable to use it again ;)
I would rather call it depth dependent. Depth is just another value to each pixel. If you say "what if the lenz flares could ignore pixels with depth", that basically means you apply them without using that information. This you can already do by deactivating depth check.
However, if "what if the lenz flares could ignore pixels with depth" means that you actually want to evaluate the depth value and apply it to either close or far pixels, then you do need the depth value.

Currently, using the depth value has the advantage that you can identify pixels that are part of the background (farthest pixels) which is where normally the sun/sky is drawn. That way, you can apply a very strong effect that is less likely triggered for false pixels. Not using the depth value for lens flares will therefore trigger it more often than you want for all kinds of false pixels cause we can currently not distinguish well between intended and not indented applications of those effects other than with that depth information. You can simply check on that by turning of the depth check for those effects :)

Please Log in or Create an account to join the conversation.

  • jas01
More
9 years 1 week ago #7 by jas01 Replied by jas01 on topic Better lens flares?

BrandonHortman wrote:
Then I built this for the Lens flares, not triggered by depth.

Trying so hard for some rad lensflares =D by brandon.hortman , on Flickr


Hello BrandonHortman :)

Can I ask you something? How I can get those radial lensflares? (from the second picture)
They are a part of the Framework?

Sorry for my poor grammar.

best wishes
The following user(s) said Thank You: BrandonHortman

Please Log in or Create an account to join the conversation.

  • BrandonHortman
  • Topic Author
More
9 years 1 week ago #8 by BrandonHortman Replied by BrandonHortman on topic Better lens flares?
My plan was to have two different sprites. This sprite for the lenz flares ( or maybe another technique, but most likely lenz) and use it with
#define LENZ_DEPTH_CHECK 0

[img
GFX_sprite3 by brandon.hortman , on Flickr

Then I was going to try to use this as the godray:
#define GODRAY_DEPTH_CHECK 1

[img
GFX_sprite12 by brandon.hortman , on Flickr

I looked through the code for the last week, but I can't for the life of me figure out how to define a texture for two different techniques
I also wondered if the Gaussian anamorphic lens flare could make sharp X patterns like this....but probably not.

I ended up settling for this Sprite with just the Lenz.
[img
GFX_sprite by brandon.hortman , on Flickr

Which can look like this in game
[img
DA:I ReShade 4K by brandon.hortman , on Flickr

But under more intense lights like the sun the rays are more prominent, but the radial flare is still there of course.

I dunno, I'm trying to come up with some creative solutions.
I guess I need to get a book on HLSL :grin:
The following user(s) said Thank You: crosire, jas01

Please Log in or Create an account to join the conversation.

We use cookies
We use cookies on our website. Some of them are essential for the operation of the forum. You can decide for yourself whether you want to allow cookies or not. Please note that if you reject them, you may not be able to use all the functionalities of the site.