コード例 #1
0
 private static final <T extends RealType<T>> Img<T> process(
     final Img<ComplexDoubleType> fftImage, final FourierTransform<T, ComplexDoubleType> fft)
     throws Exception {
   final InverseFourierTransform<T, ComplexDoubleType> ifft =
       new InverseFourierTransform<T, ComplexDoubleType>(fftImage, fft);
   if (!ifft.checkInput() || !ifft.process()) {
     throw new Exception(
         "FFT: failed to process for image "
             + fftImage.getClass()
             + " -- "
             + ifft.getErrorMessage());
   }
   return ifft.getResult();
 }
コード例 #2
0
 protected void updateTitle() {
   String trailer = "";
   if (display instanceof ImageDisplay) {
     ImageDisplayService srv = getContext().getService(ImageDisplayService.class);
     if (srv != null) {
       Dataset ds = srv.getActiveDataset((ImageDisplay) display);
       if (ds != null) {
         Img<?> img = ds.getImgPlus().getImg();
         if (AbstractCellImg.class.isAssignableFrom(img.getClass())) {
           trailer = " (V)";
         }
       }
     }
   }
   String name = getDisplay().getName();
   if (name == null) name = "";
   getWindow().setTitle(name + trailer);
 }