Bug 142021 - [EMF] SetPolyfilMode Mode = 2 ("winding") is ignored
Summary: [EMF] SetPolyfilMode Mode = 2 ("winding") is ignored
Status: RESOLVED DUPLICATE of bug 84199
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: graphics stack (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 84199 EMF-WMF 138147 143876
  Show dependency treegraph
 
Reported: 2021-05-01 15:41 UTC by Valek Filippov
Modified: 2024-05-27 17:18 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
EMF sample (364 bytes, image/x-emf)
2021-05-01 15:43 UTC, Valek Filippov
Details
Screenshot of the sample file in MSO for win (2.11 KB, image/png)
2021-05-01 15:45 UTC, Valek Filippov
Details
EMF with PolyfillMode set to 0 beforr the bottom star record (364 bytes, image/x-emf)
2021-05-01 15:47 UTC, Valek Filippov
Details
EMF with PolyfillMode set to 6 before the bottom star record (364 bytes, image/x-emf)
2021-05-01 15:47 UTC, Valek Filippov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Valek Filippov 2021-05-01 15:41:58 UTC
Description:
[MS-EMF] describes two values for PolygonFillMode enum:
Alternate = 1
Winding = 2

LO seems to ignore 'winding' mode and apply 'alternate'.

Steps to Reproduce:
Open EMF sample (star_pfm2.emf) in LO.

Actual Results:
Both stars rendered with unfilled pentagon in the center 

Expected Results:
Bottom star should be fully filled.


Reproducible: Always


User Profile Reset: No



Additional Info:
Implementation in MSO for Windows seems to consider anything other than 1 as "Winding".
Implementation in MS wordpad seems to consider anything other than 2 as "Alternate".

Because of the inconsistency in MS own implementation, decision is needed with what to be compatible.
Comment 1 Valek Filippov 2021-05-01 15:43:41 UTC
Created attachment 171570 [details]
EMF sample

PolyfillMode is set to 1 before top star record.

It set to 2 after that before the bottom start record.
Comment 2 Valek Filippov 2021-05-01 15:45:32 UTC
Created attachment 171571 [details]
Screenshot of the sample file in MSO for win
Comment 3 Valek Filippov 2021-05-01 15:47:09 UTC
Created attachment 171572 [details]
EMF with PolyfillMode set to 0 beforr the bottom star record

(for completeness, a file with undocumented value in SetPolyfillMode Mode)
Comment 4 Valek Filippov 2021-05-01 15:47:42 UTC
Created attachment 171573 [details]
EMF with PolyfillMode set to 6 before the bottom star record
Comment 6 Roman Kuznetsov 2021-05-03 13:41:49 UTC
confirm in

Version: 7.2.0.0.alpha0+ / LibreOffice Community
Build ID: a52590d76b89dc75be2aa87f4287624c89f1e82f
CPU threads: 4; OS: Mac OS X 11.3; UI render: default; VCL: osx
Locale: ru-RU (ru_RU.UTF-8); UI: en-US
Calc: threaded
Comment 7 Chris Sherlock 2021-10-09 23:48:50 UTC
Hossein, is this related to the work you are doing on winding?
Comment 8 Hossein 2021-10-10 10:35:41 UTC
(In reply to Chris Sherlock from comment #7)
> Hossein, is this related to the work you are doing on winding?
Chris: Yes. Please take a look at: tdf#84199. It depends on this issue.
Comment 9 QA Administrators 2024-03-25 03:13:25 UTC Comment hidden (obsolete)
Comment 10 Hossein 2024-05-27 17:18:55 UTC

*** This bug has been marked as a duplicate of bug 84199 ***