commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "VVD (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SANSELAN-67) Possibility to set DPI for PNG
Date Wed, 07 Mar 2012 02:25:57 GMT

    [ https://issues.apache.org/jira/browse/SANSELAN-67?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13223917#comment-13223917
] 

VVD commented on SANSELAN-67:
-----------------------------

Yes, it is.

Do you add this before 1.0 release?
                
> Possibility to set DPI for PNG
> ------------------------------
>
>                 Key: SANSELAN-67
>                 URL: https://issues.apache.org/jira/browse/SANSELAN-67
>             Project: Commons Sanselan
>          Issue Type: Question
>          Components: Format: PNG
>    Affects Versions: 0.97
>         Environment: Any
>            Reporter: VVD
>
> How I can to set DPI for PNG image?
> {code}
> File inImgFile = new File("in.png");
> File outImgFile = new File("out.png");
> BufferedImage image = Sanselan.getBufferedImage(inImgFile);
> // ImageInfo imageinfo = Sanselan.getImageInfo(inImgFile);
> // imageinfo.getPhysicalHeightDpi(): returned 300
> // imageinfo.getPhysicalWidthDpi(): returned 300
> // Sanselan.getMetadata(inImgFile): returned null
> ImageFormat format = ImageFormat.IMAGE_FORMAT_PNG;
> Sanselan.writeImage(image, outImgFile, format, params);
> // imageinfo = Sanselan.getImageInfo(outImgFile);
> // imageinfo.getPhysicalHeightDpi(): returned -1
> // imageinfo.getPhysicalWidthDpi(): returned -1
> {code}
> Thanks.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message