Updated for AliceVision >=2.4.0 compatibility. Export: added --multiband_contrib option.

This commit is contained in:
matlabbe
2021-09-19 20:20:45 -04:00
parent 44b057b0d7
commit 14b56813d3
6 changed files with 150 additions and 72 deletions

View File

@@ -283,12 +283,13 @@ RTABMAP_DEPRECATED(bool RTABMAP_EXP multiBandTexturing(
* @param dbDriver Should be set if images and memory are not set.
* @param textureSize Output texture size 1024, 2048, 4096, 8192, 16384.
* @param textureDownscale Downscaling to 4 or 8 will reduce the texture quality but speed up the computation time. Set Texture Downscale to 1 instead of 2 to get the maximum possible resolution with the resolution of your images. The output texture size will be divided by this value, e.g., with texture size of 8192 and downscale value of 2, the output will be 4096.
* @param nbContrib number of contributions per frequency band for the multi-band blending (should be 4 values)
* @param textureFormat Output texture format: "png" or "jpg".
* @param gains Optional output of {@link #mergeTextures()}.
* @param blendingGains Optional output of {@link #mergeTextures()}.
* @param contrastValues Optional output of {@link #mergeTextures()}.
* @param gainRGB Apply gain compensation on each RGB channels separately, otherwise it is apply equally to all channels.
* @param unwrapMethod Method to unwrap input mesh if it does not have UV coordinates Basic (> 600k faces) fast and simple. Can generate multiple atlases LSCM (<= 600k faces): optimize space. Generates one atlas ABF (<= 300k faces): optimize space and stretch. Generates one atlas.
* @param unwrapMethod Method to unwrap input mesh if it does not have UV coordinates 0=Basic (> 600k faces) fast and simple. Can generate multiple atlases 2=LSCM (<= 600k faces): optimize space. Generates one atlas 1=ABF (<= 300k faces): optimize space and stretch. Generates one atlas.
* @param fillHoles Fill Texture holes with plausible values True/False.
* @param padding Texture edge padding size in pixel (0-100).
* @param bestScoreThreshold 0.0 to disable filtering based on threshold to relative best score (0.0-1.0).
@@ -307,6 +308,7 @@ bool RTABMAP_EXP multiBandTexturing(
const DBDriver * dbDriver = 0,
unsigned int textureSize = 8192,
unsigned int textureDownscale = 2,
const std::string & nbContrib = "1 5 10 0",
const std::string & textureFormat = "jpg",
const std::map<int, std::map<int, cv::Vec4d> > & gains = std::map<int, std::map<int, cv::Vec4d> >(),
const std::map<int, std::map<int, cv::Mat> > & blendingGains = std::map<int, std::map<int, cv::Mat> >(),