Jump to content
Changes to the Jaspersoft community edition download ×


  • Posts

  • Joined

  • Last visited

gustavo.alvarenga's Achievements

  1. Based on accounts_8's comment, I swapped out the BufferedImage mapping for a SimpleDataRenderer and it worked perfectly with the pictures that had been giving me issues.
  2. Hello, I'm trying to generate a PDF report on JR 6.19.1 with images on it; those images are loaded as BufferedImage in our application and fed to JasperReports through a JRDataSource. It usually works, but sometimes I get the following error: net.sf.jasperreports.engine.JRException: No appropriate image writer found for the "jpeg" format. It seems to happen when we try using .png images in the report. Looking at the source code for JRJdk14ImageEncoder, I can see the following snippet: switch (imageType){ case JRRenderable.IMAGE_TYPE_GIF : { formatName = "gif"; break; } case JRRenderable.IMAGE_TYPE_PNG : { formatName = "png"; break; } case JRRenderable.IMAGE_TYPE_TIFF : { formatName = "tiff"; break; } case JRRenderable.IMAGE_TYPE_JPEG : case JRRenderable.IMAGE_TYPE_UNKNOWN : default: { formatName = "jpeg"; break; }}[/code]What defines the "imageType" variable there? Is there any way I can tell the report to render all pictures as "png" or something like that?
  • Create New...