Skip to content

Post-processing depth images #5

Description

@lucaBartolomei

Hi,

thanks a lot for this nice tutorial!
I have a (basic) question about the depth images. In the following, I refer to this part of the code. If I got it right, the process is as follows:

  1. The shader gets the depth value;
  2. The value is mapped between 0 and 1 considering the near and far planes;
  3. The output value then gets "compressed";
  4. The final output is then the depth image, which is saved to a PNG file.

I now need to do some offline post-processing (i.e. outside Unity). How can I get back the original depth value for every pixel from the stored image?
Thanks a lot for the help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions