Package javax.media.jai.remote

Examples of javax.media.jai.remote.SerializableRenderedImage


/* 396 */       RenderedImage img = (RenderedImage)sourceVector.get(i);
/* 397 */       if (!(img instanceof Serializable)) {
/* 398 */         if (!isCloned) {
/* 399 */           sourceVector = (Vector)sourceVector.clone();
/*     */         }
/* 401 */         sourceVector.set(i, new SerializableRenderedImage(img, false));
/*     */       }
/*     */     }
/* 404 */     return sourceVector;
/*     */   }
View Full Code Here


/*  793 */     RenderableImage ri = (RenderableImage)nodes.get(id);
/*  794 */     RenderedImage rendering = ri.createDefaultRendering();
/*  795 */     if ((rendering instanceof Serializable)) {
/*  796 */       return rendering;
/*      */     }
/*  798 */     return new SerializableRenderedImage(rendering);
/*      */   }
View Full Code Here

/*      */
/*  824 */     RenderedImage rendering = ri.createRendering(renderContext);
/*  825 */     if ((rendering instanceof Serializable)) {
/*  826 */       return rendering;
/*      */     }
/*  828 */     return new SerializableRenderedImage(rendering);
/*      */   }
View Full Code Here

/* 194 */     if (source != null)
/*     */       try {
/* 196 */         if ((source instanceof Serializable))
/* 197 */           this.remoteImage.setSource(this.id, source);
/*     */         else {
/* 199 */           this.remoteImage.setSource(this.id, new SerializableRenderedImage(source));
/*     */         }
/*     */       }
/*     */       catch (RemoteException e)
/*     */       {
/* 204 */         throw new RuntimeException(e.getMessage());
View Full Code Here

        defaultCM.isAlphaPremultiplied(), null);

    // serialize it
    OutputStream outStream = null;
    ObjectOutputStream ooStream = null;
    SerializableRenderedImage sri = null;
    try {
      outStream = new BufferedOutputStream(new FileOutputStream(
          sampleImageFile));
      ooStream = new ObjectOutputStream(outStream);
      sri = new SerializableRenderedImage(sampleImage, true);
      ooStream.writeObject(sri);
    } finally {
      try {
        if (ooStream != null)
          ooStream.close();
      } catch (Throwable e) {
        IOUtils.closeQuietly(ooStream);
      }
      try {
        if (outStream != null)
          outStream.close();
      } catch (Throwable e) {
        IOUtils.closeQuietly(outStream);
      }
      try {
                            if (sri != null)
                                    sri.dispose();
                        } catch (Throwable e) {
                        }
    }
  }
View Full Code Here

                serializedImage = (SerializableRenderedImage) source;
            } else {
                if (tileEncoding == null) {
                    tileEncoding = "gzip";
                }
                serializedImage = new SerializableRenderedImage(source, false, null,
                                                                tileEncoding, null, null);
                final LogRecord record = Loggings.format(Level.FINE,
                        LoggingKeys.CREATED_SERIALIZABLE_IMAGE_$2, getName(), tileEncoding);
                record.setSourceClassName(GridCoverage2D.class.getName());
                record.setSourceMethodName("writeObject");
View Full Code Here

TOP

Related Classes of javax.media.jai.remote.SerializableRenderedImage

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.