Hi
Is there any way to remap a color ( colour ) gradient depth to a black and white ramp?
I need the depth at a greyscale so that I can use it as displacement texture
Hi
Is there any way to remap a color ( colour ) gradient depth to a black and white ramp?
I need the depth at a greyscale so that I can use it as displacement texture
Hi @LukeWilmot, @jonathansims may have some insights on this!
@LukeWilmot i had to do this also. There isnt an easy answer. I believe I ended up using the raw depth mattes from the kinect, which are already greyscale. Youll have to warp pin them to fit the distortion of the RGB stuff from your DSLR.
the alternative is to ( im talking in Nuke terms here ) reshuffle the RGB mattes into something greyscale.
the results werent great, but i was able to get some depth from them.
@jonathansims - that makes sense. We got ok results from feeding the raw RGB colour mattes into After Effects, then using Colorama operator to remap hue gradient to greyscale. It’s obviously fairly detrimental dropping the 24bit depth (RGB Lut) to 8bit (0-255) greyscale, but it works for getting a quick and dirty tessellation matte for Unity.
I’m hoping Depthkit are going to maybe rewrite their Unity shaders to work with new URP pipeline, as that would preserve the full 24bit RGB depth values in Unity, but this is an ok workaround for testing in the meantime.
@LukeWilmot We are revamping our Unity plugin and look forward to sharing updates with you early next year!
Has anyone been able to do this - create a black and white depthmap from a Depthkit color depthmap? There are several ways we can just take the Cinema footage and create a black and white depthmap, and that works reasonably well, but it kind of defeats the purpose of why we recorded in Depthkit in the first place. Definitely more gradations in the color depthmap.
@CatherineEng1 - You’re right about the finer gradation in the color map than in grayscale - That’s one of the reasons Depthkit uses hue-encoded depth. What is the bit depth of the grayscale output you are using?
I just posted an update in this thread including the contents of a 5x5x5 LUT which should be helpful in transforming the hue-encoded depth map into a grayscale one while leaving the RGB portion of the combined-per-pixel relatively unchanged. Hope this helps!
@CatherineEng1 Were you able to make the conversion from hue-encoded depth to luminance-encoded using the LUT I linked to? Let me know if you need anything else.