Adventure Game Studio

Community => General Discussion => Topic started by: deee on Fri 28/11/2014 14:08:14

Title: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Fri 28/11/2014 14:08:14
Hey everyone,

I would like to introduce the tool for game developers and artists I am currently running a Kickstarter campaign (already more than 650% funded) for:
Sprite DLight on Kickstarter (http://kck.st/11fs6g5)

The main use of Sprite DLight is the generation of normal maps from 2D sprites in one click, which allows for quick and atmospheric dynamic lighting effects in 2D games:

(http://1.bp.blogspot.com/-nE2dhIbOKY4/VHfHCcnRcvI/AAAAAAAABhU/NgA1fUbq6Bs/s600/Sprite_DLight_Infograph_Kickstarter.png) (http://kck.st/11fs6g5)

This way, you could create a game featuring dynamic lighting on pixel art characters and objects, simply by processing the existing game art and using the normal maps in combination with a shader.
This is a preview of a pixel art sprite sheet with dynamic lighting via instant normal maps of Sprite DLight:

(http://2.bp.blogspot.com/-2hxB4vheuWM/VHe30QF5_nI/AAAAAAAABhE/OfGv5vbuAOE/s456/Sprite_DLight_Thanksgiving_Preview.gif) (http://kck.st/11fs6g5)
"Selen Run Animation" from the game "Timespinner", ©2014 Lunar Ray Games (http://timespinnergame.com), animated dynamic lighting preview of the sprite sheet in Sprite DLight

I know, real dynamic lighting is not possible (at a reasonable performance) with AGS at this time, however one of the already achieved stretch goals brings amazing possibilities for AGS users:
It is a feature, which allows you to re-render sprites for different environments, based on the 3D information from the normal map.


(https://s3.amazonaws.com/ksr/assets/002/794/813/4d18ab4e3ec6815f409567372d54de65_large.png?1414162340) (http://kck.st/11fs6g5)
"Squirrel", ©2010-2014 AlbertoV from DYA Games (http://dyagames.com), normal map generated by Sprite DLight and different lighting applied in the Sprite Lamp shader

One use of this could be day and night versions, achieved by batch processing all sprites in a few seconds with different lighting conditions.

There are 24 hours left to pre-order Sprite DLight at the Kickstarter backer price and to get in on the backer beta (planned to start by the end of December).
The tool is also on Steam Greenlight here! (http://steamcommunity.com/sharedfiles/filedetails/?id=340326626)
Any support and feedback is highly appreciated.


(http://2.bp.blogspot.com/-pFr_sC3DXlE/VHTJ2TQSlrI/AAAAAAAABgo/zidrPDsQ0sE/s600/Sprite_DLight_Ghost_Pizza_Preview.gif) (http://kck.st/11fs6g5)
"Ghost Pizza", ©2014 AlbertoV from DYA Games (http://dyagames.com), normal map and dynamic lighting preview of Sprite DLight

Cheers,

Dennis
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: Monsieur OUXX on Fri 28/11/2014 15:47:30
There had already been some similar technology launched last year ( here (http://www.snakehillgames.com/spritelamp/) ), but I must say this one goes one step further in automation.

It must have a lot of flaws (e.g. some lighting angles that don't make it look great), but like always with rendering technologies, the most important question is not "is it fully realistic?", it's instead "does it look impressive when used properly?". And yes, yes it does.

EDIT: unlike SpriteLamp, it doesn't seem to handle the light coming from "behind" the sprite. It's more like bump-mapping. However, as I wrote, it's way more automated than SpriteLamp and doesn't require artistic skills.

Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: dbuske on Sat 29/11/2014 14:10:09
Great!  Will it be a free graphics tool?
In the meantime I am going to try to use
light artist on a practice sprite.  See what I can get.
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Sat 29/11/2014 18:11:08
Thank you, Monsieur OUXX :)
Painting multiple lightmaps by hand and combining them to a normal map can of course lead to better results than processing a single input sprite, but as you said, if used properly, it is good enough for a great improvement.
And it saves a lot of time.

Regarding the light coming from behind: Sprite DLight's normal maps have the same range like those of Sprite lamp and other tools.
Are you referring to the preview shader? This is a new horizontal orbiting light source of Sprite DLight's lighting preview, including light from behind the sprite:

(http://1.bp.blogspot.com/-I-w3ieijX_A/VHoFIgCFqtI/AAAAAAAABiQ/jcdl4EvBQHw/s420/Sprite_DLight_Horizontal_Light_Orbit.gif)
"Sprite DLight Title Art" ©2014 AlbertoV (DYA Games (http://dyagames.com)), normal map and dynamic lighting preview of Sprite DLight

@dbuske: If there will be a free demo, which I am not yet sure about, it will have a watermark on the output maps.
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: Monsieur OUXX on Sat 29/11/2014 19:30:45
Quote from: deee on Sat 29/11/2014 18:11:08
Regarding the light coming from behind: Sprite DLight's normal maps have the same range like those of Sprite lamp and other tools.
Are you referring to the preview shader?
On your site there's a video of a platformer that takes place in a cave, with torchlights. Whenever the character walks in front of the torches, he does not obstruct the light, and he doesn't appear all black. Quite the opposite: he's fully enlighted, like he's standing behind the torch.
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Sat 29/11/2014 19:48:45
Quote from: Monsieur OUXX on Sat 29/11/2014 19:30:45
On your site there's a video of a platformer that takes place in a cave, with torchlights. Whenever the character walks in front of the torches, he does not obstruct the light, and he doesn't appear all black. Quite the opposite: he's fully enlighted, like he's standing behind the torch.
Okay, I get it. This actually has nothing to do with the used normal maps, but rather the z-value of the light source set in the shader.
I think the developers of "Bravery and Greed" did this on purpose and I like the effect, even though it is not perfectly realistic, but as you said... ;)
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Sun 30/11/2014 13:53:03
A short update: Less than 450$ missing for the re-rendering stretch goal.

For this, the diffuse light is reduced to its directional component (the angle can be set), which means that sprite sheets can be re-rendered consistently, based on the normal map.
Ambient colors can be set for the cardinal directions, too.

(http://2.bp.blogspot.com/-F_xCMTNPG4I/VHsfeO8TmfI/AAAAAAAABig/WBpJaM7ncW8/s600/Sprite_DLight_Stretch_Goal_3_Re_Rendering_Aged_Warriors_AlbertV.gif)

The re-rendering feature will synergize with the batch processing option of the Pro version.
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: dbuske on Sun 30/11/2014 22:17:28
There is another program that does normal mapping, but does not do lights.
CrazyBump
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Mon 01/12/2014 22:55:28
There are various normal map generators and plugins for image editors, but...

(https://2.bp.blogspot.com/-k3HnjmYy41s/VGH-qW5iILI/AAAAAAAABd4/aagiv8farYs/s440/Sprite_DLight_Normals_Comparison.png)

1. Original sprite
2. Normal map created by the GIMP plugin (same as PS plugin)
3. Normal map created by a common normal map generator with the original sprite used as height map, followed by shape enhancement
4. Normal map created by Sprite DLight in one click

#3 is the best result you can achieve with current automatic normal map generators combined with clever techniques, although the result is still pretty poor, it's more of a bevel effect, which is randomly concave or convex, particularly at the edges of the shape.

Update:
Stretch goal #3 just has been reached today, so the re-rendering feature is now official!

(https://s3.amazonaws.com/ksr/assets/002/994/389/5cbe36179020298c69f78583f8a408f3_large.gif?1417469914)
"Wolf where?" sprite sheet, ©2014 Kevin Chaloux (http://kaiseto.deviantart.com), re-rendered for different environments with the normal map and lighting of Sprite DLight
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Thu 11/12/2014 21:16:17
The final countdown is running, there are 24 hours left to grab the tool at the Kickstarter backer price and to jump in for the beta.

(https://s3.amazonaws.com/ksr/assets/003/033/349/93de999f27770b425f1e5fc867c309ec_large.gif?1418246645)
"Skull Plant", ©2013 Kevin Chaloux (http://kaiseto.deviantart.com), normal map and dynamic lighting preview of Sprite DLight
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: Darth Mandarb on Fri 12/12/2014 13:36:12
So happy for your success man!

I put my pledge in a long time ago (nod).

Lookin' forward to trying it out!
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Mon 15/12/2014 11:56:07
Thanks a lot, Darth :)

The Kickstarter is over and I am fully concentrating on the first beta build. 
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: InCreator on Thu 25/12/2014 20:04:01
It's actually a mystery why normal mapping in took 15 years to reach 2D games, while technology has been there so long and widely used in 3D. Advent of shader technology?
And why it's still basically at kickstarter/indie level, instead of being a norm
Title: Re: Sprite DLight - instant normal maps for 2D graphics
Post by: deee on Mon 12/01/2015 16:52:35
True!