Bug 152641 - SLIDESHOW Shape gradient angle not reflected when presenting without active 'Graphics Output Hardware Acceleration'
Summary: SLIDESHOW Shape gradient angle not reflected when presenting without active '...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
7.1.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Patrick (volunteer)
URL:
Whiteboard:
Keywords: bibisected, bisected, regression
: 145845 147939 (view as bug list)
Depends on:
Blocks: Impress-Gradient Slide-Show
  Show dependency treegraph
 
Reported: 2022-12-22 05:25 UTC by Kurt Huwig
Modified: 2023-08-21 15:10 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
Reproducing file (14.92 KB, application/vnd.oasis.opendocument.presentation)
2022-12-22 05:25 UTC, Kurt Huwig
Details
How it looks while editing (83.04 KB, image/png)
2022-12-22 05:28 UTC, Kurt Huwig
Details
How it looks during a presentation (22.47 KB, image/png)
2022-12-22 05:28 UTC, Kurt Huwig
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kurt Huwig 2022-12-22 05:25:51 UTC
Created attachment 184306 [details]
Reproducing file

Description:
Shapes with a Linear angled gradient do not display correctly in present mode, but do display correctly in edit more and PDF exports. (On Linux)

Steps to Reproduce:
1. Create an empty slide
2. Create a rectangle shape
3. Fill with two colors and set angle to 90 degrees Linear (Gradient should now be horizontal in the preview)
4. Press Shift-F5

Actual Results:
In present mode, the shape is filled with a vertical gradient.

Expected Results:
The fill colors in presentation mode should resemble the fill in edit mode.


Reproducible: Always

Additional Info:
When exporting the presentation as PDF the gradients show up correctly.

Version: 7.4.3.2 / LibreOffice Community
Build ID: 40(Build:2)
CPU threads: 12; OS: Linux 6.1; UI render: default; VCL: gtk3
Locale: de-DE (de_DE.utf8); UI: de-DE
7.4.3-3
Calc: threaded
Comment 1 Kurt Huwig 2022-12-22 05:28:08 UTC
Created attachment 184307 [details]
How it looks while editing
Comment 2 Kurt Huwig 2022-12-22 05:28:33 UTC
Created attachment 184308 [details]
How it looks during a presentation
Comment 3 Buovjaga 2022-12-22 06:55:50 UTC
Strange - for me there is no problem even though we run the same version. Do you also reproduce, if you go to Help - Restart in safe mode and then Continue in safe mode?

Arch Linux
Version: 7.4.3.2 / LibreOffice Community
Build ID: 40(Build:2)
CPU threads: 8; OS: Linux 6.0; UI render: default; VCL: gtk3
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
7.4.3-3
Calc: threaded

Set to NEEDINFO.
Change back to UNCONFIRMED, if the problem persists in safe mode. Change to RESOLVED WORKSFORME, if the problem went away (you can reset the user profile in this case).
Comment 4 Kurt Huwig 2022-12-22 10:29:19 UTC
Using the safe mode I was able to find the culprit:

Options - LibreOffice - View - Graphics Output - Use hardware acceleration

If I activate the acceleration, I cannot reproduce it. If I disable it, I can reproduce it.
Comment 5 Rainer Bielefeld Retired 2022-12-22 15:52:43 UTC
REPRODUCIBLE with reporter's sample, disabled Hardware acceleration and Installation of Version:7.4.2.3 (x64) 
Build ID: 382eef1f22670f7f4118c8c2dd222ec7ad009daf
CPU threads: 12; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: de-DE (de_DE); UI: de-DE |  Calc: threaded | ElementaryTheme | My normal User Profile
Comment 6 Rainer Bielefeld Retired 2022-12-22 16:03:21 UTC
With query <https://bugs.documentfoundation.org/buglist.cgi?cmdtype=dorem&remaction=run&namedcmd=DUPs152641&sharer_id=19321> I found "Bug 145845 - Impress gradient is not displayed the same way in edit mode and slide show", which already is concerning this issue – without having recognized the root of the problem. Same in "Bug 147645 - Linear and axial gradients lost in presentation mode", possibly others.

Please decide which one is DUP of which one.
Comment 7 Telesto 2022-12-22 18:57:44 UTC
(In reply to Rainer Bielefeld Retired from comment #6)
Bug 147645 is Skia related. This is GTK3 rendering. See also bug 147645 comment 3.

It's still possible to be related. But lets say this being different until proven otherwise.
Comment 8 Buovjaga 2022-12-22 20:59:08 UTC
(In reply to Kurt Huwig from comment #4)
> Using the safe mode I was able to find the culprit:
> 
> Options - LibreOffice - View - Graphics Output - Use hardware acceleration
> 
> If I activate the acceleration, I cannot reproduce it. If I disable it, I
> can reproduce it.

I repro on Linux with all backends.

Arch Linux 64-bit, X11
Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: baddc742c3fe260d20d7924ab134f0fbf179fd85
CPU threads: 8; OS: Linux 6.0; UI render: default; VCL: kf5 (cairo+xcb)
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
Calc: threaded Jumbo
Built on 12 December 2022
Comment 9 Rainer Bielefeld Retired 2022-12-23 06:50:32 UTC
(In reply to Telesto from comment #7)
> But lets say this being different until proven otherwise.

Yes, you are right, my explication was a little short.

Although my knowledge is very basic, I am pretty sure sure that they are related. Please
10. Launch LibO (Start Center)
11. Menu ˋTools  → Options  → View → Uncheck "Use Hardware Acceleration" → Use anti aliasing" → Uncheck "Use Skia"ˊ
12. Quit and Relaunch LibO
13. Menu ˋTools  → Options  → View → Check "Use Hardware Acceleration" (if not yet checkedˊ
14. Quit and Relaunch LibO
15. Uncheck "Use Hardware Acceleration"
16. Check "Use Skia ..."
   » You will see that 
     "Use Hardware Acceleration" becomes greyed out
     Unexpectedly checkmark  "Use Hardware Acceleration" appears ⁉

(16) might indicate that there is a relation between Skia and Hardware acceleration.
But I'm still not sure whether we already have collected all aspects.
Comment 10 Rainer Bielefeld Retired 2022-12-23 06:58:04 UTC
Already REPRODUCIBLE with Server Installation of Version: Version: 7.2.5.2 (x64)  Build ID 499f9727c189e6ef3471021d6132d4c694f357e5
CPU threads: 12; OS: Windows 10.0 Build 19042
Comment 11 Buovjaga 2022-12-25 17:32:25 UTC
Bibisected with linux-64-7.1 to https://git.libreoffice.org/core/commit/a46cb5dc607d1d1af402ff3e8fce731e7427854d
try to use directly VCL's DrawGradient() in vclcanvas (tdf#136523)
Comment 12 Aron Budea 2022-12-26 16:41:36 UTC
*** Bug 145845 has been marked as a duplicate of this bug. ***
Comment 13 Aron Budea 2022-12-26 16:42:31 UTC
*** Bug 147939 has been marked as a duplicate of this bug. ***
Comment 14 Patrick (volunteer) 2023-08-16 12:39:55 UTC
I have committed a fix for https://bugs.documentfoundation.org/show_bug.cgi?id=147645 which also fixes this bug. The fix should be available in tomorrow's (17 August 2023) nightly master build.

Note: I only tested on macOS. I saw the https://bugs.documentfoundation.org/show_bug.cgi?id=152641#c9 comment about hardware acceleration but on macOS, hardware acceleration cannot be enabled so, for macOS, there was only one place in the code that gets used to draw gradients in slideshows.

Can anyone test the fix on Windows or Linux both with and without hardware acceleration enabled?
Comment 15 Patrick (volunteer) 2023-08-21 12:46:32 UTC
Note: I have also submitted this fix for the following branches:

LibreOffice 7-6: https://gerrit.libreoffice.org/c/core/+/155705
LibreOffice 7-5: https://gerrit.libreoffice.org/c/core/+/155707

They are both awaiting review but hopefully they will be included in the next LibreOffice 7.5 and 7.6 releases.
Comment 16 Buovjaga 2023-08-21 15:10:33 UTC
Verified

Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: e60ef8651cfb30335471d1622e58c13eebc7d58b
CPU threads: 2; OS: Windows 10.0 Build 22621; UI render: default; VCL: win
Locale: en-US (en_FI); UI: en-US
Calc: threaded

Arch Linux 64-bit, X11
Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 0a17e45e3fed13c240629fdf0dbb00b8908f5acc
CPU threads: 8; OS: Linux 6.4; UI render: default; VCL: kf5 (cairo+xcb)
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
Calc: threaded
Built on 21 August 2023