This commit is contained in:
sfop
2017-03-16 17:02:11 +01:00
parent 7c8595f8ee
commit 44ebfb505c
2 changed files with 22 additions and 13 deletions
+10 -10
View File
@@ -1,13 +1,13 @@
#Thu Mar 16 10:22:37 CET 2017
#Thu Mar 16 16:57:17 CET 2017
colormap=Grayscale
colormapAutomatic=true
colormapMax=0.0
colormapMin=0.0
colormapAutomatic=false
colormapMax=124.459
colormapMin=83.269
flipHorizontally=false
flipVertically=false
grayscale=false
imageHeight=1024
imageWidth=1280
imageHeight=1200
imageWidth=1246
invert=false
rescaleFactor=1.0
rescaleOffset=0.0
@@ -19,9 +19,9 @@ rotation=0.0
rotationCrop=false
scale=1.0
serverURL=localhost\:10000
spatialCalOffsetX=-50.0
spatialCalOffsetY=-50.0
spatialCalScaleX=-1.0
spatialCalScaleY=-1.0
spatialCalOffsetX=8751.115234375
spatialCalOffsetY=16090.42578125
spatialCalScaleX=-26.761820720381525
spatialCalScaleY=-26.595745478002502
spatialCalUnits=mm
transpose=false
+12 -3
View File
@@ -2258,18 +2258,27 @@ public class ScreenPanel extends Panel {
private void buttonGrabBackgroundActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_buttonGrabBackgroundActionPerformed
try {
if (camera instanceof Camtool) {
if ((camera!=null) && (camera instanceof Camtool)) {
if (SwingUtils.showOption(getTopLevel(), "Background", "Do you want to capture background now?", OptionType.YesNo) == OptionResult.Yes) {
boolean laserOn = getLaserState();
boolean rendering = (!camera.isClosed());
if (rendering){
camera.close();
}
if (laserOn) {
setLaserState(false);
}
try {
((Camtool) camera).grabBackground(null, 5);
try{
System.out.println("Grabbing background for: " + cameraName);
((Camtool) camera).grabBackground(cameraName, 5);
} finally {
if (laserOn) {
setLaserState(true);
}
if (rendering){
comboCamerasActionPerformed(null);
}
updateStop();
}
SwingUtils.showMessage(getTopLevel(), "Success", "Success capturing background", 5000);
}