From 6b40984ea2ffaa7029c09e927d113f79d7f5f277 Mon Sep 17 00:00:00 2001 From: Caleb Hulbert Date: Tue, 17 Oct 2023 14:36:25 -0400 Subject: [PATCH] refactor,fix: move BundleView to non-overloaded package --- .../bdv/fx/viewer/project/VolatileHierarchyProjector.java | 2 +- .../project/VolatileHierarchyProjectorPreMultiply.java | 2 +- .../saalfeldlab/paintera/data/mask/MaskedSource.java | 2 +- .../janelia/saalfeldlab/paintera/data/mask/SourceMask.java | 2 +- .../janelia/saalfeldlab/paintera/meshes/MarchingCubes.java | 2 +- .../java/{ => paintera}/net/imglib2/view/BundleView.java | 7 ++++++- .../paintera/control/actions/paint/SmoothAction.kt | 2 +- .../saalfeldlab/paintera/control/paint/ViewerMask.kt | 2 +- .../saalfeldlab/paintera/control/tools/paint/SamTool.kt | 2 +- .../janelia/saalfeldlab/paintera/PainteraBaseViewTest.java | 2 +- 10 files changed, 15 insertions(+), 10 deletions(-) rename src/main/java/{ => paintera}/net/imglib2/view/BundleView.java (94%) diff --git a/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjector.java b/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjector.java index 5982942d0..2cb7057f7 100644 --- a/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjector.java +++ b/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjector.java @@ -44,7 +44,7 @@ import net.imglib2.type.operators.SetZero; import net.imglib2.util.Intervals; import net.imglib2.util.StopWatch; -import net.imglib2.view.BundleView; +import paintera.net.imglib2.view.BundleView; import net.imglib2.view.Views; import java.util.ArrayList; diff --git a/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjectorPreMultiply.java b/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjectorPreMultiply.java index 2d2142e9c..bfd28d1dd 100644 --- a/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjectorPreMultiply.java +++ b/src/main/java/bdv/fx/viewer/project/VolatileHierarchyProjectorPreMultiply.java @@ -9,7 +9,7 @@ import net.imglib2.parallel.TaskExecutor; import net.imglib2.type.numeric.ARGBType; import net.imglib2.type.numeric.integer.ByteType; -import net.imglib2.view.BundleView; +import paintera.net.imglib2.view.BundleView; import net.imglib2.view.Views; import java.util.List; diff --git a/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/MaskedSource.java b/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/MaskedSource.java index 3e3287e8d..a6ced8582 100644 --- a/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/MaskedSource.java +++ b/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/MaskedSource.java @@ -86,7 +86,7 @@ import net.imglib2.util.ConstantUtils; import net.imglib2.util.IntervalIndexer; import net.imglib2.util.Intervals; -import net.imglib2.view.BundleView; +import paintera.net.imglib2.view.BundleView; import net.imglib2.view.ExtendedRealRandomAccessibleRealInterval; import net.imglib2.view.IntervalView; import net.imglib2.view.RealRandomAccessibleTriple; diff --git a/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/SourceMask.java b/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/SourceMask.java index 48ab5e90c..9b4e26add 100644 --- a/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/SourceMask.java +++ b/src/main/java/org/janelia/saalfeldlab/paintera/data/mask/SourceMask.java @@ -8,7 +8,7 @@ import net.imglib2.type.numeric.IntegerType; import net.imglib2.type.numeric.integer.UnsignedLongType; import net.imglib2.type.volatiles.VolatileUnsignedLongType; -import net.imglib2.view.BundleView; +import paintera.net.imglib2.view.BundleView; import net.imglib2.view.IntervalView; import net.imglib2.view.Views; diff --git a/src/main/java/org/janelia/saalfeldlab/paintera/meshes/MarchingCubes.java b/src/main/java/org/janelia/saalfeldlab/paintera/meshes/MarchingCubes.java index faf77d93a..8a3d009cd 100644 --- a/src/main/java/org/janelia/saalfeldlab/paintera/meshes/MarchingCubes.java +++ b/src/main/java/org/janelia/saalfeldlab/paintera/meshes/MarchingCubes.java @@ -8,7 +8,7 @@ import net.imglib2.loops.LoopBuilder; import net.imglib2.type.BooleanType; import net.imglib2.util.Intervals; -import net.imglib2.view.BundleView; +import paintera.net.imglib2.view.BundleView; import net.imglib2.view.IntervalView; import net.imglib2.view.Views; import org.slf4j.Logger; diff --git a/src/main/java/net/imglib2/view/BundleView.java b/src/main/java/paintera/net/imglib2/view/BundleView.java similarity index 94% rename from src/main/java/net/imglib2/view/BundleView.java rename to src/main/java/paintera/net/imglib2/view/BundleView.java index ff61fce6b..d1dde9764 100644 --- a/src/main/java/net/imglib2/view/BundleView.java +++ b/src/main/java/paintera/net/imglib2/view/BundleView.java @@ -31,7 +31,7 @@ * POSSIBILITY OF SUCH DAMAGE. * #L% */ -package net.imglib2.view; +package paintera.net.imglib2.view; import net.imglib2.Interval; import net.imglib2.RandomAccess; @@ -51,6 +51,11 @@ * {@link RandomAccess RandomAccess<RandomAccess<T>>} will preserve * this relative offset while absolute positioning will reset it, so, you can * do that, but you should know why :).

+ *

+ * NOTE: Copied from imglib2 to expose as public while + * Imglib2 Issue #351 + * is being resolved. + *

* * @param * @author Stephan Saalfeld <saalfelds@janelia.hhmi.org> diff --git a/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/actions/paint/SmoothAction.kt b/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/actions/paint/SmoothAction.kt index cdb0e30a5..886088adc 100644 --- a/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/actions/paint/SmoothAction.kt +++ b/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/actions/paint/SmoothAction.kt @@ -40,7 +40,7 @@ import net.imglib2.realtransform.AffineTransform3D import net.imglib2.type.numeric.integer.UnsignedLongType import net.imglib2.type.numeric.real.DoubleType import net.imglib2.util.Intervals -import net.imglib2.view.BundleView +import paintera.net.imglib2.view.BundleView import org.janelia.saalfeldlab.fx.Tasks import org.janelia.saalfeldlab.fx.UtilityTask import org.janelia.saalfeldlab.fx.actions.Action diff --git a/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/paint/ViewerMask.kt b/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/paint/ViewerMask.kt index e26a66a48..03f97d2d1 100644 --- a/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/paint/ViewerMask.kt +++ b/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/paint/ViewerMask.kt @@ -17,7 +17,7 @@ import net.imglib2.type.numeric.integer.UnsignedLongType import net.imglib2.type.volatiles.VolatileUnsignedLongType import net.imglib2.util.Intervals import net.imglib2.util.LinAlgHelpers -import net.imglib2.view.BundleView +import paintera.net.imglib2.view.BundleView import net.imglib2.view.Views import org.janelia.saalfeldlab.fx.extensions.component1 import org.janelia.saalfeldlab.fx.extensions.component2 diff --git a/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/tools/paint/SamTool.kt b/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/tools/paint/SamTool.kt index f7bcf47a8..6a6f8ad9f 100644 --- a/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/tools/paint/SamTool.kt +++ b/src/main/kotlin/org/janelia/saalfeldlab/paintera/control/tools/paint/SamTool.kt @@ -46,7 +46,7 @@ import net.imglib2.type.numeric.integer.UnsignedLongType import net.imglib2.type.numeric.real.FloatType import net.imglib2.type.volatiles.VolatileUnsignedLongType import net.imglib2.util.Intervals -import net.imglib2.view.BundleView +import paintera.net.imglib2.view.BundleView import net.imglib2.view.Views import org.apache.http.HttpException import org.apache.http.client.methods.HttpPost diff --git a/src/test/java/org/janelia/saalfeldlab/paintera/PainteraBaseViewTest.java b/src/test/java/org/janelia/saalfeldlab/paintera/PainteraBaseViewTest.java index d100433e8..579ce9612 100644 --- a/src/test/java/org/janelia/saalfeldlab/paintera/PainteraBaseViewTest.java +++ b/src/test/java/org/janelia/saalfeldlab/paintera/PainteraBaseViewTest.java @@ -15,7 +15,7 @@ import net.imglib2.type.numeric.integer.UnsignedLongType; import net.imglib2.util.Intervals; import net.imglib2.util.LinAlgHelpers; -import net.imglib2.view.BundleView; +import paintera.net.imglib2.view.BundleView; import net.imglib2.view.IntervalView; import net.imglib2.view.Views; import org.janelia.saalfeldlab.fx.util.InvokeOnJavaFXApplicationThread;