What does affect the ImageResolution parameter in the StiPdfExportSettings?
What does affect the ImageResolution parameter in the StiPdfExportSettings?
I put images on my print, but even when they are high resolution images, especially BMP files, they are not affected by this parameter, but are affected by ImageCompressionMethod setting. I can see that this parameter does affect images generated by Stimulsoft when creating images for the RTF control while printing with the ExportRtfTextAsImage flag enabled. What other elements does this parameter influence?
-
Lech Kulikowski
- Posts: 7691
- Joined: Tue Mar 20, 2018 5:34 am
Re: What does affect the ImageResolution parameter in the StiPdfExportSettings?
Hello,
The ImageCompressionMethod exists only in PDF export and affects only the codec (JPEG or Flate); it does not affect the image size or DPI.
There is the ImageResolutionMode parameter, which directly affects this. If it is Auto, the DPI of the original image is used; if it is Exactly, the DPI from ImageResolution is used.
As for ExportRtfTextAsImage, the DPI from ImageResolution is always used.
Thank you.
The ImageCompressionMethod exists only in PDF export and affects only the codec (JPEG or Flate); it does not affect the image size or DPI.
There is the ImageResolutionMode parameter, which directly affects this. If it is Auto, the DPI of the original image is used; if it is Exactly, the DPI from ImageResolution is used.
As for ExportRtfTextAsImage, the DPI from ImageResolution is always used.
Thank you.
Re: What does affect the ImageResolution parameter in the StiPdfExportSettings?
Do I understand correctly that during PDF export, when ImageResolutionMode is set to Auto and ExportRtfTextAsImage is set to false, the ImageResolution parameter has no effect? And if ExportRtfTextAsImage is enabled, then ImageResolution affects only the images generated from RTF text and nothing else?
-
Lech Kulikowski
- Posts: 7691
- Joined: Tue Mar 20, 2018 5:34 am
Re: What does affect the ImageResolution parameter in the StiPdfExportSettings?
Hello,
> Do I understand correctly that during PDF export, when ImageResolutionMode is set to Auto and ExportRtfTextAsImage is set to false, the ImageResolution parameter has no effect?
Yes.
> And if ExportRtfTextAsImage is enabled, then ImageResolution affects only the images generated from RTF text and nothing else?
On all images.
Thank you.
> Do I understand correctly that during PDF export, when ImageResolutionMode is set to Auto and ExportRtfTextAsImage is set to false, the ImageResolution parameter has no effect?
Yes.
> And if ExportRtfTextAsImage is enabled, then ImageResolution affects only the images generated from RTF text and nothing else?
On all images.
Thank you.
Re: What does affect the ImageResolution parameter in the StiPdfExportSettings?
Thanks for the clarification.
Just to make sure I fully understand the last point:
When ExportRtfTextAsImage = true, and regardless of whether the image comes from:
an Image component (e.g., BMP, PNG, JPEG),
a PictureBox,
or RTF rendered as image,
does ImageResolution override the original DPI for all of them when ImageResolutionMode = Exactly?
In other words, in that scenario, is the original image DPI completely ignored during PDF export?
I just want to be certain there isn’t a mixed behavior depending on the source of the image.
Just to make sure I fully understand the last point:
When ExportRtfTextAsImage = true, and regardless of whether the image comes from:
an Image component (e.g., BMP, PNG, JPEG),
a PictureBox,
or RTF rendered as image,
does ImageResolution override the original DPI for all of them when ImageResolutionMode = Exactly?
In other words, in that scenario, is the original image DPI completely ignored during PDF export?
I just want to be certain there isn’t a mixed behavior depending on the source of the image.
-
Lech Kulikowski
- Posts: 7691
- Joined: Tue Mar 20, 2018 5:34 am
Re: What does affect the ImageResolution parameter in the StiPdfExportSettings?
Hello,
If ExportRtfTextAsImage = false, then RichText is exported as text.
If ExportRtfTextAsImage = true, then RichText is exported as an image and takes the DPI only from ImageResolution.
For images:
If ImageResolutionMode = Exactly, then the DPI is taken only from ImageResolution for all images.
If ImageResolutionMode = Auto, then:
* for raster images - from the images themselves,
* for vector images - from ImageResolution.
The point is that RichText and vector images do not have their own DPI, so it is taken from the ImageResolution property.
Thank you.
If ExportRtfTextAsImage = false, then RichText is exported as text.
If ExportRtfTextAsImage = true, then RichText is exported as an image and takes the DPI only from ImageResolution.
For images:
If ImageResolutionMode = Exactly, then the DPI is taken only from ImageResolution for all images.
If ImageResolutionMode = Auto, then:
* for raster images - from the images themselves,
* for vector images - from ImageResolution.
The point is that RichText and vector images do not have their own DPI, so it is taken from the ImageResolution property.
Thank you.