Hello,
We are using ASPOSE CAD (.NET 23.3.0.0) to convert Dxf files to PDF files and something seems to be a bit off with the scaling.
After I convert the Dxf to PDF using my code (attached), I use an external tool (Bluebeam Revu 20) to take measurements directly on the PDF itself and the dimensions (length and width) aren’t matching what was originally in the Dxf file.
Here’s a screenshot of the incorrect dimensions. It should be measuring 30’ but is only measuring 27’-3 1/2" IncorrectMeasurement.png (8.2 KB)
The interesting thing is when I use your online converter (here) and take the measurements from the PDF using the same external tool (Revu Bluebeam 20), everything measures as it should. Here’s a screenshot of that. CorrectMeasurement.png (7.5 KB)
Is there any way to see what code your online converter uses so I can compare it to the code that I’m using?
@kgrems,
Hello.
Could you please try redo your measurements after export without margins, and export with different height/width options, e.g., try using image.Width, image.Height there instead of 1920 / 1080.
@oleksii.gorokhovatskyi
Thanks for the reply. Removing the margins worked. However, setting image.Height and image.Width doesn’t work because they are “read only” properties. They cause compile errors.
How would I go about maintaining some margin around the edge of my document but also maintaining the proportions/scaling?
@oleksii.gorokhovatskyi
This maintains the proper dimensions, but doesn’t give any margins: PageWidth = image.Width, PageHeight = image.Height,
This maintains the proper dimensions, but doesn’t give any margins. It just makes the page itself significantly larger: PageWidth = 5 * image.Width, PageHeight = 5 * image.Height,
This maintains proper dimensions, but doesn’t provide any margin. Again, it just makes the page larger:
PageWidth = 1920 + 2 * margin,
PageHeight = 1080 + 2 * margin,
@kgrems,
Ok, so how to calculate those 27’ 11 1/2’’ from the PDF? As I understood, removing of margins helped. Here is file without margins output_nomargins.pdf (75.8 KB). The length of the line in this file is exactly the same as for “output.pdf” above, isn’t it?
@oleksii.gorokhovatskyi
We use an external tool called Revu Bluebeam to take measurements directly on the PDF.
No, the length of the line in the file above is not the same as “output.pdf”. The file you just attached (output_nomargins.pdf) measures correctly since there are no margins. Here’s the measurement: CorrectMeasurement.png (2.2 KB)