Skip to content

deluxemap overflow #299

@illwieckz

Description

@illwieckz

Reported there before: UnvanquishedAssets/map-station15_src.dpkdir#3

I'm now sure it's an engine issue, and I now know the line causing this:

	lightColor /= clamp(dot(normalize(var_Normal), lightDir), 0.004, 1.0);

There:

// divide by cosine term to restore original light color
lightColor /= clamp(dot(normalize(var_Normal), lightDir), 0.004, 1.0);

We can find trace of this code in first commit of the repository:

float NdotLnobump = clamp(dot(normalize(var_Normal.xyz), L), 0.004, 1.0);

It was removed in 0bb3550 (Add tiled light-index renderer) and re-added in 0949fda (Lightmapping fixes) by @gimhael.

I don't know what this code is for, it looks like there is less issues by not using this code than using it.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions