Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

running the reconstruction part with my own depth/normal maps #4

Open
HenriMir opened this issue Jun 4, 2018 · 2 comments
Open

running the reconstruction part with my own depth/normal maps #4

HenriMir opened this issue Jun 4, 2018 · 2 comments

Comments

@HenriMir
Copy link

HenriMir commented Jun 4, 2018

Hi, I am trying to use the mesh reconstruction from depth/normal maps part of your pipeline but with my own depth and normal maps, but I keep getting image format error in the C++ code (wrong byte per pixel amount) how do I have to save images for them to be computed by your C++ code?

Thank you

@HenriMir
Copy link
Author

HenriMir commented Jun 7, 2018

solved: just change the size of the images to 16 bit per channel, and save the resulting images with proper python library (I used write_png)

@happylun
Copy link
Owner

For your reference, if you have your own depth/normal data, you can load it in python and use tensorflow's built-in method to do the PNG encoding (that's what I did in my code).
Note that in my code I encode normal data in RGB channel and depth data in alpha channel. Also for each channel I map the value from [-1,1] to [0,65535] and encode the image in 16-bit PNG.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants