Commit b3ce3bd2 authored by Andrey Filippov's avatar Andrey Filippov

Motion blur correction made symmetrical, elimination biases

parent 5a11583a
...@@ -4364,7 +4364,7 @@ public class GpuQuad{ // quad camera description ...@@ -4364,7 +4364,7 @@ public class GpuQuad{ // quad camera description
double dy = mb_vectors[1][nTile]; double dy = mb_vectors[1][nTile];
double mb_len = Math.sqrt(dx*dx+dy*dy); // in pixels/s -> 0 double mb_len = Math.sqrt(dx*dx+dy*dy); // in pixels/s -> 0
double [] centerXY_sub = centerXY; double [] centerXY_sub = centerXY;
if (mb_len < min_len) { if (mb_len < min_len) { // No MB correction
tp_task.setScale(1.0); tp_task.setScale(1.0);
tp_task_sub.task = 0; // disable tp_task_sub.task = 0; // disable
tp_task_sub.setScale(-min_sub); tp_task_sub.setScale(-min_sub);
...@@ -4380,7 +4380,8 @@ public class GpuQuad{ // quad camera description ...@@ -4380,7 +4380,8 @@ public class GpuQuad{ // quad camera description
} }
dx *= mb_offs; dx *= mb_offs;
dy *= mb_offs; dy *= mb_offs;
centerXY_sub = new double[] {centerXY[0]+dx,centerXY[1]+dy}; centerXY_sub = new double[] {centerXY[0]+0.5*dx,centerXY[1]+0.5*dy};
centerXY = new double[] {centerXY[0]-0.5*dx,centerXY[1]-0.5*dy};
tp_task_sub.setCenterXY(centerXY_sub); tp_task_sub.setCenterXY(centerXY_sub);
double exp_offs = Math.exp(-mb_offs/mb_len); double exp_offs = Math.exp(-mb_offs/mb_len);
double gain = 1.0/(1.0 - exp_offs); double gain = 1.0/(1.0 - exp_offs);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment