@@ -3389,7 +3389,7 @@ public class TileProcessor {
st.planes,// final TilePlanes.PlaneData [][] planes,
merge_candidates,// final int [][][] merge_candidates,
plane_nooverlaps,// final boolean [][][] valid_candidates, // will be updated
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -3424,7 +3424,7 @@ public class TileProcessor {
clt_parameters.plTargetEigen,// final double targetEigen, // = 0.1; // Remove outliers until main axis eigenvalue (possibly scaled by plDispNorm) gets below
clt_parameters.plFractOutliers,// final double fractOutliers, // = 0.3; // Maximal fraction of outliers to remove
clt_parameters.plMaxOutliers,// final int maxOutliers, // = 20; // Maximal number of outliers to remove
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -3582,12 +3582,23 @@ public class TileProcessor {
LinkPlaneslp=newLinkPlanes(clt_parameters,st);
// condition supertiles (create and manage links, merge)
st.planes,// final TilePlanes.PlaneData [][] planes,
10,// final int max_num_merge_try,
0);// debugLevel); // final int debugLevel);
// Used only by conflicts (not processed currently)
lp.calcStarValueStrength(
true,// boolean set_start_planes,
clt_parameters.plStarOrtho,// orthoWeight, // final double orthoWeight,
clt_parameters.plStarDiag,// diagonalWeight, // final double diagonalWeight,
clt_parameters.plStarPwr,// starPwr, // final double starPwr, // Divide cost by number of connections to this power
clt_parameters.plStarWeightPwr,// starWeightPwr, // final double starWeightPwr, // Use this power of tile weight when calculating connection cost
clt_parameters.plWeightToDens,// weightToDens, // Balance weighted density against density. 0.0 - density, 1.0 - weighted density
clt_parameters.plStarValPwr,// starValPwr, //double starValPwr, // Raise value of each tile before averaging
2,// starSteps, // final int steps,
st.planes,// final TilePlanes.PlaneData [][] planes,
clt_parameters.plPreferDisparity,// preferDisparity, // final boolean preferDisparity)
debugLevel-2);
// re-generate planes in the supertiles using previously calculated planes (for tghe tiles and their neighbors)
// as hints, new planes will be assumed parallel to the known and possibly slightly offset in disparity
...
...
@@ -3627,23 +3638,35 @@ public class TileProcessor {
clt_parameters.plDiscrGrown,// final int plDiscrGrown, // = 0; // Only use tiles within this range from original selection
clt_parameters.plDiscrXMedian,// final double plDiscrXMedian, // = 1.5; // Remove outliers from the final selection that have distance more than scaled median
0,// -1, // debugLevel, // final int debugLevel)
debugLevel,// -1, // debugLevel, // final int debugLevel)
debugLevel+1,// 2, // -1, // debugLevel, // final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -4015,7 +4044,7 @@ public class TileProcessor {
clt_parameters.plTargetEigen,// final double targetEigen, // = 0.1; // Remove outliers until main axis eigenvalue (possibly scaled by plDispNorm) gets below
clt_parameters.plFractOutliers,// final double fractOutliers, // = 0.3; // Maximal fraction of outliers to remove
clt_parameters.plMaxOutliers,// final int maxOutliers, // = 20; // Maximal number of outliers to remove
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// 2, // -1, // debugLevel, // final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -4035,7 +4064,7 @@ public class TileProcessor {
st.planes_mod,// final TilePlanes.PlaneData [][] planes,
conflicting_candidates,// final int [][][] merge_candidates,\
0.4,// final double min_distance,
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// 2, // -1, // debugLevel, // final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -4046,7 +4075,7 @@ public class TileProcessor {
plane_nooverlaps,// final boolean [][][] valid_candidates, // will be updated
true,// final boolean merge_low_eigen, here it should be true
true,// final boolean useNonExcl, // consider only directions available for non-exclusive merges
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// 2, // -1, // debugLevel, // final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -4061,7 +4090,7 @@ public class TileProcessor {
conflicting_candidates,// final int [][][] merge_candidates,
plane_nooverlaps,// final boolean [][][] valid_candidates, // will be updated
lp.getConflRelax(),//relax_for_conflicts, // final double relax,
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// 2, // -1, // debugLevel, // final int debugLevel)
lp.getConflRelax(),// relax_for_conflicts, // final double relax,
2,// -1, // debugLevel, // final int debugLevel)
debugLevel+1,// 2, // -1, // debugLevel, // final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -4103,10 +4132,14 @@ public class TileProcessor {
clt_parameters.plTargetEigen,// final double targetEigen, // = 0.1; // Remove outliers until main axis eigenvalue (possibly scaled by plDispNorm) gets below
clt_parameters.plFractOutliers,// final double fractOutliers, // = 0.3; // Maximal fraction of outliers to remove
clt_parameters.plMaxOutliers,// final int maxOutliers, // = 20; // Maximal number of outliers to remove
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// 2, // -1, // debugLevel, // final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
System.out.println("Try "+num_merge_try+": removed "+num_removed_by_merging+" conflicting planes by merging, recalculating connections");
if(num_merge_try>=max_num_tries){
System.out.println("Exceeded maximal number of iterations, beaking anyway...");
break;
}
if(num_removed_by_merging==0){// re-calculate all links
break;
}
...
...
@@ -4117,20 +4150,20 @@ public class TileProcessor {
lp.matchPlanes(
st.planes,// final TilePlanes.PlaneData [][] planes,
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
lp.interPlaneCosts(//
true,// final boolean en_sticks, // treat planes with second eigenvalue below plEigenStick as "sticks"
st.planes,// final TilePlanes.PlaneData [][] planes,
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
lp.filterNeighborPlanes(
st.planes,// final TilePlanes.PlaneData [][] planes,
true,// final boolean merge_low_eigen,
2,// -1, // debugLevel, // final int debugLevel)
debugLevel,// final int debugLevel)
clt_parameters.tileX,
clt_parameters.tileY);
...
...
@@ -4138,34 +4171,34 @@ public class TileProcessor {