Skip to content
This repository was archived by the owner on Nov 2, 2018. It is now read-only.
This repository was archived by the owner on Nov 2, 2018. It is now read-only.

Window resizing breaks light overlay #5

@DunkUK

Description

@DunkUK

If I run a scene with some Light2D lights, but then resize the game window, the lights become offset from the intended positions.
I think the lighting is still consistent with the obstacles (as the LightOverlay material's LightSources render target looks sensible though possibly stretched), but it doesn't overlay back correctly to the game.

I'm guessing it's some aspect ratio or scaling value for the overlay shader that isn't being updated.

Edit: I'm using a normals camera, and the normal map render target doesn't resize, so it might be related.
Edit2: Though if I turn NormalMapping off, the lights are in the right place, but then the obstacles are in the wrong place, casting incorrect shadows. Weird.

Tested on Unity 2017.1.0f3

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions