Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

iText getDpiX() returns zero and cannot maintain originality in .png  RSS feed

 
Krishna Chaitanya Reddy Balam
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to print a .png file into pdf and I want the same clarity inside the pdf.
I was trying to
png.scalePercent(72f / jpg.getDpiX() * 100);
but getDpiX() returns zero.
Is there any way to keep the images as it is in pdf rather than default dpi.
The images are large in number and I cannot do something like
png.scalePercent(75);

Please provide me a mechanism where I can preserve the originality of any .png image on pdf.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!