Announcement

Collapse
No announcement yet.

how to get the actual z value in zdepth element

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • how to get the actual z value in zdepth element

    Hi guys

    Seems the zdepth max is decided by the bounding of the entire scene?

    Can I set zdepth max or set Clamp zdepth​ to false? Or it would be nice if the actual z of each pixel can be directly given.

    Thanks

  • #2
    Yes, the Z-depth is normalized according to the size of the scene bounding box. There are no settings for it. We could easily print the size of the bounding box in the log though, would this help?

    if the actual z of each pixel can be directly given
    Not sure what you mean by that. A render element with the depth of pixels relative to the camera in scene units?

    What is your use case, are you using Nuke or Photoshop or something else?
    Nikola Goranov
    Chaos Developer

    Comment


    • #3
      Originally posted by npg View Post
      Yes, the Z-depth is normalized according to the size of the scene bounding box. There are no settings for it. We could easily print the size of the bounding box in the log though, would this help?


      Not sure what you mean by that. A render element with the depth of pixels relative to the camera in scene units?

      What is your use case, are you using Nuke or Photoshop or something else?
      Yes, the depth relative to the camera. So if it is normalized by scene bounding, I can use app sdk to get it.

      By "the size" you mentioned, is it the max value of the scene bounding?

      My use case is to do some post processing by depth.

      Comment


      • #4
        The maximum depth is taken from the largest component (X or Y or Z) of the diagonal of the axis-aligned bounding box of the scene.
        Nikola Goranov
        Chaos Developer

        Comment

        Working...
        X