What is the actual advantage of using brightmaps?

Discuss anything ZDoom-related that doesn't fall into one of the other categories.

What is the actual advantage of using brightmaps?

Postby RKD » Fri Jun 17, 2022 11:42 am

I was curious about why some mods/projects have weapon sprites that look too dark at first glance. Then I realized those are combined with brightmaps included in a separate folder and what we see in-game is an overlay of the brightmap "layer" on top of the weapon sprite, as a sort of graphical patch.
I understand how bm are used and it's sort of intuitive to figure out why you'd want to use them in cases where you have a single sprite but want to alternate muzzle flashes or intermitent lights. The thing is that I've also seen the usage of brightmaps in weapons where each single frame is a different sprite.

So my question, more specifically, is: Why bother with two separate sprites (weapon+bm) for a single frame instead of making whatever light effect you desire in the actual weapon sprite? Is it perhaps a way to bypass some limitation that I haven't thought of (like palette colors or something)?
User avatar
RKD
 
Joined: 19 Mar 2022
Location: Argentina
Operating System: Windows 10/8.1/8/201x 64-bit

Re: What is the actual advantage of using brightmaps?

Postby Chris » Fri Jun 17, 2022 12:29 pm

RKD wrote:So my question, more specifically, is: Why bother with two separate sprites (weapon+bm) for a single frame instead of making whatever light effect you desire in the actual weapon sprite? Is it perhaps a way to bypass some limitation that I haven't thought of (like palette colors or something)?

More detailed lighting, perhaps, to simulate self-lighting. With separate weapon+bm sprites, the bm areas will remain bright in dark areas, while the dark areas of the bm will be light or dark depending on the room/sector. The player weapon sprite may not get as dark in dark rooms compared to monsters and decorations, but they do get slightly dimmer. If they were combined, the lit areas would get dimmed (if it's not set full-bright), or the unlit wouldn't get dimmed (if it is set full-bright).
User avatar
Chris
 
Joined: 17 Jul 2003
Operating System: Debian-like Linux (Debian, Ubuntu, Mint, etc) 64-bit
Graphics Processor: ATI/AMD with Vulkan Support

Re: What is the actual advantage of using brightmaps?

Postby fakemai » Fri Jun 17, 2022 12:36 pm

Do you have any examples of what you mean? Brightmaps are used to change how, well, brightness is applied to parts of a sprite, typically for bright light effects where having them at sector light level would look stupid. A great example are the external add-on ones for DoomRL Arsenal, I load them standard with it for a reason. It is not limited to just that though and I could see it used to add greater depth to how the sprites are lit, what would normally be baked into the graphic no matter what sector brightness they were shown in.
User avatar
fakemai
 
Joined: 12 Feb 2018
Location: Australia
Operating System: Debian-like Linux (Debian, Ubuntu, Mint, etc) 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: Intel (Legacy GZDoom)

Re: What is the actual advantage of using brightmaps?

Postby RKD » Fri Jun 17, 2022 1:08 pm

fakemai wrote:Do you have any examples of what you mean?

I've been fiddling around with several mods/standalone games in Slade out of curiosity, so I kinda have them all meshed together in my mind, haha.

In any case, both of you mentioned the thing I wasn't accounting for: having parts of a weapon that should always be lit in specific frames unaffected by ambient lights in a map. It makes a lot more sense in my head now. That settles it. Thanks a lot for the clarifications!
User avatar
RKD
 
Joined: 19 Mar 2022
Location: Argentina
Operating System: Windows 10/8.1/8/201x 64-bit


Return to General

Who is online

Users browsing this forum: mjr4077au and 3 guests