openMVS icon indicating copy to clipboard operation
openMVS copied to clipboard

Texture Brightness High Exposure

Open Habsburgg opened this issue 1 year ago • 12 comments

Hi, for texture maps there are many area luminosity highly exposed. Is there a suitable way to reduce this phenomenon? Or is there any way to lower the weight of this region, giving priority to non-highly exposed image regions. Looking forward to your reply. 111

Habsburgg avatar Jul 03 '23 12:07 Habsburgg

are these highly exposed regions in the source images?

cdcseacave avatar Jul 04 '23 09:07 cdcseacave

are these highly exposed regions in the source images?

Yes, but there are many pictures from different angles corresponding to the same place on the model, some pictures are high exposure, some are not.

Habsburgg avatar Jul 05 '23 01:07 Habsburgg

  1. for best 3D reconstruction results (not only texture) images should be acquired at good, but diffuse light, and equal or close to equal exposure (constant light).
  2. since 1 is a requirement, OpenMVS does not have a good way now to select images without glossiness artifacts, in fact as it is now it is biassed to select such images
  3. help is needed to implement a better texturing algorithm, pls give a sign if interested

cdcseacave avatar Jul 05 '23 06:07 cdcseacave

thank you for your reply,

  1. I marked the high-exposure areas in the image as much as possible, and reduced the scores of these pixels in the view selection stage, but the effect was not good. If I have time, I will continue to study.
  2. I encountered a problem. There is still a color difference between the texturePatches. I saw that you used Poisson fusion. Why is there such a big difference? Can opencv's seamlessClone replace this function? textureBorder texture

Habsburgg avatar Jul 12 '23 08:07 Habsburgg

good suggestion, a different blending procedure might be better, pls try

cdcseacave avatar Jul 13 '23 14:07 cdcseacave

I did an experiment. Set the color of the border of the texture block to black as the boundary condition of the Poisson calculation, and the texture map result is shown in the figure. Does this mean that there is a problem with setting the edge color of the texture block in LocalSeamLeveling, causing the Poisson calculation to be wrong. I'm not sure if my guess is correct. 1111 2222

Habsburgg avatar Jul 19 '23 09:07 Habsburgg

Interesting experiment. However not clear to me what is the results before and after, and which edge did you set to black exactly. Can you add more screenshots?

cdcseacave avatar Jul 19 '23 16:07 cdcseacave

openMVS: 11 12

Habsburgg avatar Jul 20 '23 01:07 Habsburgg

mvs-texturing: 21 22

Habsburgg avatar Jul 20 '23 01:07 Habsburgg

Interesting experiment. However not clear to me what is the results before and after, and which edge did you set to black exactly. Can you add more screenshots?

I set the junction of different textures to black, and the original code is set to the average color. By comparison, I suspect that openmvs misses some border pixels, doesn't change their color, causing the poisson calculation to still use the original color, which leads to weird transition areas between different textures.

Habsburgg avatar Jul 20 '23 01:07 Habsburgg

This is the mask image I saved, and you can see that some edges are not set to gray "border". In the DrawLine function, "Bresenham's line algorithm" is used to calculate the texture edge pixels. Is there any problem here? Looking forward to your reply. mask2 mask1

Habsburgg avatar Jul 20 '23 12:07 Habsburgg

thanks for the detailed experiment a couple of thoughts:

  • mvs-texturing is using mapmap instead of LBP to assign a image to each face, which should be not only faster, but better/fewer patches, and less seams
  • recently I discovered a bug in how the camera matrix K is scaled, and I think the same bug affects also other parts of OpenMVS where the image coordinates are scaled, possibly also in texturing, though I can not see one at a quick look

most probably though might be a problem with drawing the line, like you say, or something related; it would be of great help if you could look into this and fix it; you could compare on how this is done in mvs-texturing

cdcseacave avatar Jul 20 '23 12:07 cdcseacave