Hi,
Do you have the issue on your dev machine or on productive infrastructure: I remember having issues with PNGs on my dev machine but that would work ok on live machines regards didier On May 12, 8:27 pm, Teng Shiu Huang <small...@gmail.com> wrote: > I am evaluating imagesService.applyTransform() to transform images(from URL) > to specific width/height. > It's documented that PNG is supported. But it seems it doesn't understand > some PNG file. > for example > :http://destinyfab.appspot.com/resizer/resize?url=http://www.google.co... > It works well , and can transform google's logo to 500x500. > > BUT , this PNG > :http://destinyfab.appspot.com/resizer/resize?url=http://upload.wikime... > > An error occurred , with this stacktrace : > > Caused by: java.lang.IllegalArgumentException: Unknown > at > com.google.appengine.api.images.ImagesServiceImpl.convertApplicationException(ImagesServiceImpl.java:306) > at > com.google.appengine.api.images.ImagesServiceImpl.applyTransform(ImagesServiceImpl.java:73) > at > com.google.appengine.api.images.ImagesServiceImpl.applyTransform(ImagesServiceImpl.java:50) > at > com.google.appengine.api.images.ImagesServiceImpl.applyTransform(ImagesServiceImpl.java:39) > at controllers.Resizer.resize(Resizer.java:72) > > I tried some PNGs , and many transparent PNG cannot be transformed . Is this > GAE's limitation ? > > The code is very simple , just grab the url's content , transform to byte[]. > > byte[] imageBytes = baos.toByteArray(); > Logger.info("imageBytes.length = %s " , imageBytes.length); > > ImagesService imagesService = ImagesServiceFactory.getImagesService(); > > Image oldImage = ImagesServiceFactory.makeImage(imageBytes); > Transform transform = ImagesServiceFactory.makeResize(w, h); > Image newImage = imagesService.applyTransform(transform, oldImage); > //error occurs > byte[] newImageData = newImage.getImageData(); -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to google-appengine-java@googlegroups.com. To unsubscribe from this group, send email to google-appengine-java+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.