Created attachment 112305 [details] Test PDF Image scaling, rotating, shearing - all of these are problems for current PDF import code. Test files and screenshot are attached.
Created attachment 112306 [details] Test SVG (source file; linked to e:\logo.png)
Created attachment 112307 [details] Screenshot (LO.Draw vs Adobe Reader)
Created attachment 112343 [details] Patch v1 Here is the first version of the patch. It fixes Bug 88049 and partially fixes this bug (88465).
(In reply to vvort from comment #3) > Created attachment 112343 [details] [review] > Patch v1 > > Here is the first version of the patch. > It fixes Bug 88049 and partially fixes this bug (88465). You should send it to gerrit and reference the issues. Patches in BZ get lost.
OK, I've sent it. https://gerrit.libreoffice.org/13957 But here is some notes: 1. This commit changes the way how transformations are processed; Because of this, many things must be tested and checked for regressions: text, polygons and images. 2. Skew transformations are not fixed: bug lies somewhere deep in LO code: maybe even in specifications (look at https://wiki.openoffice.org/wiki/User:Regina/MYDrafts4 ).
(In reply to vvort from comment #0) > Image scaling, rotating, shearing - all of these are problems for current > PDF import code. REPRO Steps: - Open attachment 112305 [details] (test PDF) in Draw - Compare to renderings of LO and Adobe Reader in attachment 112307 [details] TESTING with LO 4.4.0.2 + Ubuntu 14.04 CONFIRMED: image transforms are wildly/incorrectly skewed compared to how the document renders in Adobe Reader and in Firefox 34.0 Status -> NEW Whiteboard -> filter:pdf
Created attachment 112423 [details] Render of half-fixed image transforms Hello, all. I have created utils for regression testing of pdf import-export filters. They are limited to Windows' batch language, but can be easily ported to *nix. Additionally to libreoffice installation, Poppler's pdftocairo.exe and ImageMagick's compare.exe are needed. Here they are: generate.bat: @echo off set pdf_to_png=d:\poppler\bin\pdftocairo.exe set libre_office=e:\_Projects\libreoffice-build\instdir\program\soffice.exe set search_path=original\*.pdf if not "%1" == "" set search_path=original\%1 for %%f in (%search_path%) do ( echo Processing: %%~nf.pdf if not exist original\%%~nf.png ( %pdf_to_png% -singlefile -png original\%%~nf.pdf 2>nul ) %libre_office% --convert-to odf --outdir libreoffice original\%%~nf.pdf %libre_office% --convert-to pdf --outdir libreoffice libreoffice\%%~nf.odf %pdf_to_png% -singlefile -png libreoffice\%%~nf.pdf 2>nul ) compare.bat: @echo off set cmp_path1=libreoffice-master set cmp_path2=libreoffice set cmp_path3=diff set im_compare=d:\ImageMagick\compare mkdir diff 2>nul for %%f in (libreoffice-master\*.png) do ( echo Comparing: %%~nf.png %im_compare% %cmp_path1%\%%~nf.png %cmp_path2%\%%~nf.png %cmp_path3%\%%~nf.png ) And I have tested this test utils on gerrit commit #13957 with 23 different PDF files: no regressions was found. Also render result for image_transforms.pdf with latest commit attached.
Vort committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=ee21771db0292315ff3e1b87ff58294335106bd3 fdo#88465 PDF Import: fix scale and rotate image transformations It will be available in 4.5.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Vort committed a patch related to this issue. It has been pushed to "libreoffice-4-4": http://cgit.freedesktop.org/libreoffice/core/commit/?id=470eaff4ddbadb26b7c3d524d351508e984ce878&h=libreoffice-4-4 fdo#88465 PDF Import: fix scale and rotate image transformations It will be available in 4.4.5. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Converting Whiteboard tags to Keywords: filter:pdf
Rotation looks good. But the placement is not correct and all images are mirrored.
*** Bug 84337 has been marked as a duplicate of this bug. ***
*** Bug 99811 has been marked as a duplicate of this bug. ***
Here's copypaste of #99811: Decided to give a go for several PDF's with Draw 5.1.3.1 x64, the latest at this time. The PDF's are freely available: - http://it-ebooks.info/book/1463046616/ - http://it-ebooks.info/book/1463046483/ - http://it-ebooks.info/book/1463046723/ - http://it-ebooks.info/book/1463047378/ - http://it-ebooks.info/book/1463047188/ 1) In some files the first page is brutally stretched from the middle all the way to the bottom, exceeding the seeable view without zooming out radically. 2) Texts are misplaced mindlessly. 3) Where Draw shows some sort of transparent box, the shape of the box can be just anything. 3.2) Related to 2, the texts and objects are, usually, misplaced mindlessly. The mentioned points happen with almost every PDF from the site.
I wasn't able to download books from specified URLs. After pressing download button, web page just refreshes, popping another bunch of ads.
(In reply to vvort from comment #15) > I wasn't able to download books from specified URLs. After pressing download > button, web page just refreshes, popping another bunch of ads. Same order on my "File Server": - http://s284544448.onlinehome.us/public/_PDF_/_PROGRAMMING_/Python/Python%20Playground.pdf - http://s284544448.onlinehome.us/public/_PDF_/Statistics%20Done%20Wrong.pdf - http://s284544448.onlinehome.us/public/_PDF_/_PROGRAMMING_/Python/Python%20Crash%20Course.pdf - http://s284544448.onlinehome.us/public/_PDF_/_PROGRAMMING_/CSS/Pro%20CSS3%20Layout%20Techniques.pdf - http://s284544448.onlinehome.us/public/_PDF_/Editshare%20Lightworks/12/Digital%20Video%20Editing%20Fundamentals.pdf
There are many font, kerning and clipping problems in this files, but I think they are not related to this report. Only one thing is left unfixed in the scope of this report: incorrect skew transformations of the images, but this is a rare case in real PDF files.
(In reply to vvort from comment #17) > There are many font, kerning and clipping problems in this files, but I > think they are not related to this report. > Only one thing is left unfixed in the scope of this report: incorrect skew > transformations of the images, but this is a rare case in real PDF files. #99811 was closed as dupe of this one.
(In reply to Jouni Järvinen from comment #18) > (In reply to vvort from comment #17) > > There are many font, kerning and clipping problems in this files, but I > > think they are not related to this report. > > Only one thing is left unfixed in the scope of this report: incorrect skew > > transformations of the images, but this is a rare case in real PDF files. > > #99811 was closed as dupe of this one. Your report had several issues. Did you review this list, like Heiko suggested: https://bugs.documentfoundation.org/showdependencytree.cgi?id=99746&hide_resolved=1
(In reply to Buovjaga from comment #19) > (In reply to Jouni Järvinen from comment #18) > > (In reply to vvort from comment #17) > > > There are many font, kerning and clipping problems in this files, but I > > > think they are not related to this report. > > > Only one thing is left unfixed in the scope of this report: incorrect skew > > > transformations of the images, but this is a rare case in real PDF files. > > > > #99811 was closed as dupe of this one. > > Your report had several issues. Did you review this list, like Heiko > suggested: > https://bugs.documentfoundation.org/showdependencytree. > cgi?id=99746&hide_resolved=1 I must be missing something cuz I can't find such suggestions anywhere, and I had absolutely no clue about existence of such dependency tree.
(In reply to Jouni Järvinen from comment #20) > I must be missing something cuz I can't find such suggestions anywhere, and > I had absolutely no clue about existence of such dependency tree. https://bugs.documentfoundation.org/show_bug.cgi?id=99811#c1
(In reply to Buovjaga from comment #21) > (In reply to Jouni Järvinen from comment #20) > > I must be missing something cuz I can't find such suggestions anywhere, and > > I had absolutely no clue about existence of such dependency tree. > > https://bugs.documentfoundation.org/show_bug.cgi?id=99811#c1 Sorry.
Created attachment 126105 [details] PDF tested on LO Draw, missing some text when compared to view from pdf reader I'm new to bug reporting for libreoffice. I've attached a pdf file. Text is missing when opened in Libreoffice Draw Version: 5.1.4.2, on Windows. Haven't tested on Linux.
Text missing under headings when opened in LibreOffice Draw.
(In reply to freshproductive from comment #23) > Created attachment 126105 [details] > PDF tested on LO Draw, missing some text when compared to view from pdf > reader > > I'm new to bug reporting for libreoffice. I've attached a pdf file. Text > is missing when opened in Libreoffice Draw Version: 5.1.4.2, on Windows. > Haven't tested on Linux. Not relevant to this report, please create a new report after searching for existing reports.
Created attachment 136413 [details] LOO 5.4.2.1 64 bit in win 10 64 bit pdf export looks all ok in my view
Created attachment 136414 [details] screenshot 5.4.2.1-64 win10-64 looks good in LOO 5.4.2.1
(In reply to paulystefan from comment #27) > looks good in LOO 5.4.2.1 No, not good. Look at bottom 6 images. Their shapes should be horizontally symmetrical.
you are right, bottom 6 are false in directions
also in 5.4.3.2 x64 win10
also in 6.0.5.1 x64 win10 bottom 6 are false in directions
also in 6.1.0.3 x64 win10 6 at bottom are false in directions
also in 6.3.0.4 x64 win10 6 at bottom are false in directions
Unable to even open the file, I get General Errror - General Input/Output Error Tested with Inkscape 1.0.2, I can see the file correctly (I downloaded also LO logo.png to be able to see the result) In present LO version I am unable to see anything. Version: 7.1.1.1 (x64) / LibreOffice Community Build ID: 575c5867c4cc13d7ae78f9ce39a54a52ed38c769 CPU threads: 4; OS: Windows 10.0 Build 19042; UI render: Skia/Vulkan; VCL: win Locale: cs-CZ (cs_CZ); UI: en-GB Calc: threaded The same for Linux version Version: 7.1.1.1 / LibreOffice Community Build ID: 575c5867c4cc13d7ae78f9ce39a54a52ed38c769 CPU threads: 8; OS: Linux 5.10; UI render: default; VCL: kf5 Locale: cs-CZ (cs_CZ.UTF-8); UI: cs-CZ Calc: threaded
Opens fine in 7.2 and what is best, it matches the Adobe Reader screenshot perfectly! Arch Linux 64-bit Version: 7.2.0.0.alpha0+ / LibreOffice Community Build ID: e5f436bc53e0d07654901ef7cc8ff56d04f0686e CPU threads: 8; OS: Linux 5.11; UI render: default; VCL: kf5 Locale: fi-FI (fi_FI.UTF-8); UI: en-US Calc: threaded Built on 24 February 2021