Skip to content

Commit

Permalink
v.0.5.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ekatrukha committed Dec 31, 2024
1 parent b82bbea commit 1b855fb
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/main/java/bigtrace/io/ROIsExportCSV.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@

import bigtrace.BigTrace;
import bigtrace.BigTraceBGWorker;
import bigtrace.BigTraceData;
import bigtrace.rois.AbstractCurve3D;
import bigtrace.rois.Roi3D;

Expand Down Expand Up @@ -51,7 +52,7 @@ protected Void doInBackground() throws Exception {
{
//column titles

writer.write("ROI_Number,X_coord,Y_coord,Z_coord,ROI_Name,ROI_Type,ROI_Group,ROI_TimePoint\n");
writer.write("ROI_Number,X_coord,Y_coord,Z_coord,Radius,ROI_Name,ROI_Type,ROI_Group,ROI_TimePoint\n");
DecimalFormatSymbols symbols = new DecimalFormatSymbols();
symbols.setDecimalSeparator('.');
DecimalFormat df3 = new DecimalFormat ("#.#####", symbols);
Expand All @@ -60,6 +61,7 @@ protected Void doInBackground() throws Exception {
String sRoiGroup;
String sRoiType;
String sRoiTP;
String sRadius;
int nRoiCurrN = 0;
//writer.write("ROIsNumber," + Integer.toString(nRoiN)+"\n");
for(nRoi=0; nRoi<nRoiN; nRoi++)
Expand All @@ -77,6 +79,7 @@ protected Void doInBackground() throws Exception {
sRoiName = currRoi.getName();
sRoiType = Roi3D.intTypeToString( currRoi.getType());
sRoiGroup = bt.roiManager.groups.get(currRoi.getGroupInd()).getName();
sRadius = df3.format( currRoi.getLineThickness()*0.5*BigTraceData.dMinVoxelSize);
ArrayList< RealPoint > points = currRoi.getJointSegmentResampled();
for(int nP=0; nP<points.size(); nP++)
{
Expand All @@ -85,7 +88,7 @@ protected Void doInBackground() throws Exception {
{
writer.write( df3.format(points.get( nP ).getDoublePosition( d ) ) +"," );
}
writer.write( sRoiName + "," + sRoiType + "," + sRoiGroup + "," + sRoiTP + "\n");
writer.write( sRadius +"," + sRoiName + "," + sRoiType + "," + sRoiGroup + "," + sRoiTP + "\n");
}
}

Expand Down

0 comments on commit 1b855fb

Please sign in to comment.