garrysmod-requests
garrysmod-requests copied to clipboard
HDR static prop lightmaps (RGBA16161616f PPL/`-dumppropmaps` PFM files)
Details
Source SDK 2013 Multiplayer (and Garry's Mod) support static prop lightmaps in the form of RGB888 (24-bit SDR) PPL files. According to the VDC Wiki's page on VertexLitGeneric
's $lightmap
VMT parameter:
VRAD ought to be modified to compile static prop lightmaps to RGBA16161616f to support HDR lighting for maps that use it as most already do.
If Garry's Mod supports conditional statements in VMT files like I believe it does, VRAD could generate both LDR and HDR lightmaps for static props, swapping between them depending on which lighting mode is loaded at runtime. An example VMT could look something like this (untested):
"VertexLitGeneric"
{
$basetexture "mybasetexture"
"!HDR?$lightmap" "lightmap/path"
"HDR?$lightmap" "lightmap/path_hdr"
}
Will reference issues #2109, #517 and #2441 for posterity.