-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make newest sciview compatible with local scenery (stupid jackson)
- Loading branch information
Showing
3 changed files
with
71 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,37 @@ | ||
package sc.iview | ||
|
||
import graphics.scenery.utils.lazyLogger | ||
import graphics.scenery.volumes.RAIVolume | ||
import graphics.scenery.volumes.TransferFunction | ||
import org.scijava.command.CommandService | ||
import org.scijava.ui.UIService | ||
import sc.iview.SciView | ||
import sc.iview.commands.demo.advanced.EyeTrackingDemo | ||
|
||
object StartEyeTrackingDirectly { | ||
//object StartEye { | ||
|
||
val logger by lazyLogger() | ||
// val logger by lazyLogger() | ||
|
||
@JvmStatic | ||
fun main(args: Array<String>) { | ||
val sv = SciView.create() | ||
val context = sv.scijavaContext | ||
val uiService = context?.service(UIService::class.java) | ||
uiService?.showUI() | ||
// @JvmStatic | ||
fun main() { | ||
val sv = SciView.create() | ||
val context = sv.scijavaContext | ||
val uiService = context?.service(UIService::class.java) | ||
uiService?.showUI() | ||
|
||
sv.open("C:/Software/datasets/MastodonTutorialDataset1/datasethdf5.xml") | ||
val volumes = sv.findNodes { it.javaClass == RAIVolume::class.java } | ||
volumes.first().let { | ||
it as RAIVolume | ||
it.minDisplayRange = 400f | ||
it.maxDisplayRange = 1500f | ||
val tf = TransferFunction() | ||
tf.addControlPoint(0f, 0f) | ||
tf.addControlPoint(1f, 1f) | ||
it.transferFunction = tf | ||
} | ||
sv.open("C:/Software/datasets/MastodonTutorialDataset1/datasethdf5.xml") | ||
val volumes = sv.findNodes { it.javaClass == RAIVolume::class.java } | ||
volumes.first().let { | ||
it as RAIVolume | ||
it.minDisplayRange = 400f | ||
it.maxDisplayRange = 1500f | ||
val tf = TransferFunction() | ||
tf.addControlPoint(0f, 0f) | ||
tf.addControlPoint(1f, 1f) | ||
it.transferFunction = tf | ||
} | ||
|
||
val command = sv.scijavaContext!!.getService(CommandService::class.java) | ||
val argmap = HashMap<String, Any>() | ||
command.run(EyeTrackingDemo::class.java, true, argmap) | ||
val command = sv.scijavaContext!!.getService(CommandService::class.java) | ||
val argmap = HashMap<String, Any>() | ||
command.run(EyeTrackingDemo::class.java, true, argmap) | ||
|
||
} | ||
} | ||
} | ||
//} |