Bug 455077 - Height to normal crashes krita
Summary: Height to normal crashes krita
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Filters (show other bugs)
Version: 5.0.6
Platform: Microsoft Windows Microsoft Windows
: NOR crash
Target Milestone: ---
Assignee: Halla Rempt
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-06-09 12:10 UTC by Mmero
Modified: 2022-06-10 14:51 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
KritaCrashLogs (274.90 KB, text/plain)
2022-06-10 08:43 UTC, Mmero
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mmero 2022-06-09 12:10:21 UTC
SUMMARY

STEPS TO REPRODUCE
1.  add any texture
2.  separate image
3.  use "height to normal map" on one of the layers

OBSERVED RESULT
crash every time
Comment 1 Halla Rempt 2022-06-09 12:33:10 UTC
Could you check whether you have a kritacrash.log in %APPDATA% and if so, attach it here?
Comment 2 Mmero 2022-06-10 08:43:20 UTC
Created attachment 149593 [details]
KritaCrashLogs

KritaCrashLogs
Comment 3 Halla Rempt 2022-06-10 09:32:14 UTC
Are you by any chance working on a grayscale layer? I can reproduce the crash with that, but not with an RGB layer.
Comment 4 Halla Rempt 2022-06-10 10:52:55 UTC
Git commit 55f4df14e1f12ea7cc1214783685ee74a37cace1 by Halla Rempt.
Committed on 10/06/2022 at 10:45.
Pushed by rempt into branch 'master'.

Don't run height-to-normal map if there aren't enough channels

M  +7    -0    plugins/filters/convertheightnormalmap/kis_convert_height_to_normal_map_filter.cpp

https://invent.kde.org/graphics/krita/commit/55f4df14e1f12ea7cc1214783685ee74a37cace1
Comment 5 Halla Rempt 2022-06-10 10:53:19 UTC
Git commit e429092969f5c28f68fee4c7ed47551b143204e4 by Halla Rempt.
Committed on 10/06/2022 at 10:53.
Pushed by rempt into branch 'krita/5.1'.

Don't run height-to-normal map if there aren't enough channels
(cherry picked from commit 55f4df14e1f12ea7cc1214783685ee74a37cace1)

M  +7    -0    plugins/filters/convertheightnormalmap/kis_convert_height_to_normal_map_filter.cpp

https://invent.kde.org/graphics/krita/commit/e429092969f5c28f68fee4c7ed47551b143204e4
Comment 6 Mmero 2022-06-10 14:51:21 UTC
(In reply to Halla Rempt from comment #5)
> Git commit e429092969f5c28f68fee4c7ed47551b143204e4 by Halla Rempt.
> Committed on 10/06/2022 at 10:53.
> Pushed by rempt into branch 'krita/5.1'.
> 
> Don't run height-to-normal map if there aren't enough channels
> (cherry picked from commit 55f4df14e1f12ea7cc1214783685ee74a37cace1)
> 
> M  +7    -0   
> plugins/filters/convertheightnormalmap/
> kis_convert_height_to_normal_map_filter.cpp
> 
> https://invent.kde.org/graphics/krita/commit/
> e429092969f5c28f68fee4c7ed47551b143204e4

For the Future It would be nice to be able to run that filter with GreyScale texture
not only "separate image" creates greyscale layers but heightmaps itself are GreyScale in nature so it's kinda funny that "height to normal map" won't accept height maps as input.