You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This would remove global drift of the sample from the tracks shape. Upside is that the point cloud will always be centered around the center of the viewer (allows for easy rotation). Downside could be that the possible movement of the sample in the microscope is no longer reflected in the viewer.
This could be achieved by adding the following code to src/lib/TrackManager.ts:
let x_total = 0;
let y_total = 0;
let z_total = 0;
for (let i = 0; i < array.length; i += stride) {
x_total += array[i];
y_total += array[i + 1];
z_total += array[i + 2];
}
const meanX = x_total / (array.length / stride);
const meanY = y_total / (array.length / stride);
const meanZ = z_total / (array.length / stride);
Only adjustment that is needed is to calculate the mean from the points, and apply these means for rescaling the fetched tracks (now points and tracks use the same applyScale function
The text was updated successfully, but these errors were encountered:
This would remove global drift of the sample from the tracks shape. Upside is that the point cloud will always be centered around the center of the viewer (allows for easy rotation). Downside could be that the possible movement of the sample in the microscope is no longer reflected in the viewer.
Connected to #118
This could be achieved by adding the following code to
src/lib/TrackManager.ts
:Only adjustment that is needed is to calculate the mean from the points, and apply these means for rescaling the fetched tracks (now points and tracks use the same
applyScale
functionThe text was updated successfully, but these errors were encountered: