Realistic Lens Flare

Realistic Lens Flare

by SpinningCube

👁 2,159 ❤️ 355 ⭐ 288 🔄 4
Created: Mar 27, 2022 Last modified: Nov 29, 2024 Shared: Apr 4, 2022

Description

A quick test project I made to generate lens flares, the kind of lens effect which would be visible when you point a camera at a bright light source like the sun. The end result is a quite nice-looking effect. The effect is composed of many individual lens flare elements. I made two of the lens flare textures using external image editing software, each one is a simple shape colored white with a radial gradient ranging from opaque at the edges to partially transparent at the center. More transparency is added by the project itself. This is a clone-based method, which means each lens element is a clone (A stamp-based version is perfectly doable, though). The clone is assigned a random size, position factor, shape, and transparency. There are 30 clones in total, though this can be changed in the code depending on how many lens elements are needed. The lens elements' positions are all multiples of the sun position. Everything is done in 2D, but this can be applied to a 3D project if Sun X and Sun Y are set to the projected coordinates of the sun. This project doesn't lag very much, but it does look smoother on TurboWarp with these settings: https://turbowarp.org/666704223?hqpen&fps=60&limitless Updated 16 April 2022 - Added exposure adjustment, where the background darkens when looking directly at the sun. Changed the sun streaks to make them fade in when looking directly at the sun. Released 3 April 2022 Anyway here's a bunch of tags: #Sun #Light #Sunlight #Day #Sky #Glare #Camera #Lens #Flare #Effect #2.5D #3D #Math #Clones #Mobile

Project Details

Visibility
Visible
Comments
Enabled

More Cool Projects

Project thumbnail
View Project

Kirby's Dreamland 3 Maker

by BenjaminWins11

Project thumbnail
View Project

Friday night funkin' VS Herobrine [DEMO]

by vollrineVPS1

Project thumbnail
View Project

Beat up roblox people(0.5)

by 25year5pupil4

Project thumbnail
View Project

Let's Make KNE Sans Serif: A Latin Extended Font! | v2.4.9

by WindowsMeRules2000

Project thumbnail
View Project

<[{(COLLABS)}]>talking tom and ben news hd 9: muchos gracias copy remix

by everton_trader2

Project thumbnail
View Project

beat up king tuck mooooore!

by CLAX1212

Project thumbnail
View Project

Talking News [REMASTERED] Ultra Remix

by LaytonHasFancyStuff

Project thumbnail
View Project

2D Minecraft V1.19  お金ある世界

by pira_kurahuto

Project thumbnail
View Project

GD level: "Dash" [Credits in notes] [unplayable]

by shai

Project thumbnail
View Project

3D Terrain Generator

by kevin_eleven_1234

Project thumbnail
View Project

SPIFFY PICTURES EXE. Buttons V40 Spiffy.exe

by gtmosaics

Project thumbnail
View Project

Spanish Alphabet Lore: Lowercase Sprites (Accurate Version)

by BryanTheAnimator

Project thumbnail
View Project

add a button to beat up Nano: 2024 edition [1]

by Super_Isaac_64

Project thumbnail
View Project

IENE Megifinity [1] (START to -₪)

by OctoNEs

Project thumbnail
View Project

Beat Up Viacom

by JSA1524

Project thumbnail
View Project

Cheating (FULLY PLAYABLE) VS Dave and Bambi

by darwiniscute

Project thumbnail
View Project

SLAP remix

by KubaKo_Player

Project thumbnail
View Project

Johnny vs Funny Valentine

by VLADSSJ123

Project thumbnail
View Project

[Undertale] - The Final Experiment

by LucasBr003

Project thumbnail
View Project

Stay Put Survival: The Expansion Update

by OopsieDaisy_

Project thumbnail
View Project

FNF ∆Triple PhoneBreakers∇ Playable

by Cuphead78250

Project thumbnail
View Project

Geometry Dash Level Editor 2.98.9

by iPhone_ATT_TWC_tests

Project thumbnail
View Project

Trollsome Runner 3D (Beta)

by IMACREEPER

Project thumbnail
View Project

Dragons’ Cave - A Parallax #art

by babe_ri400