1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Reported bugs that have been closed and/or resolved

Moderators: helmut, XnTriq, xnview, Dreamer

Post Reply
User avatar
user0
XnThusiast
Posts: 2411
Joined: Sat May 09, 2015 9:37 am

1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by user0 »

XnView: MP 1.4.0b1 64bits
OS: Windows 64bit (22H2), display resolution 3840x2160, win scaling 150%

Batch convert

issue A
'Background color' shows selected color, but with Alpha applied (and on black background*) when dialog reopened.
It should show just selected color.
* it is even not a background color from Batch convert settings tab

issue B
Alpha control do nothing to the images without alpha channel

Suggestion
there are few options:
1. disable control for images without alpha channel
2. add checkbox that will enable/disable alpha control, means add/remove alpha channel*
3. keep it always enabled:
-- if value =255 (opacity =1oo%) - DO not add alpha channel to image
-- if value <255 (opacity <1oo%) - ADD alpha channel to background*
* then it will depends on output format's ability to keep alpha channel

as for me, option 2 is the clearest one, 3 is unintuitive
Attachments
batch_convert_'Canvas resize' background color and alpha.png
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by xnview »

user0 wrote: Wed Nov 30, 2022 2:17 pm issue A
Right
issue B
Alpha control do nothing to the images without alpha channel

Suggestion
there are few options:
1. disable control for images without alpha channel
2. add checkbox that will enable/disable alpha control, means add/remove alpha channel*
3. keep it always enabled:
-- if value =255 (opacity =1oo%) - DO not add alpha channel to image
-- if value <255 (opacity <1oo%) - ADD alpha channel to background*
* then it will depends on output format's ability to keep alpha channel
I can't disable alpha channel because we don't know if there is 32bits in the file list...
Pierre.
User avatar
user0
XnThusiast
Posts: 2411
Joined: Sat May 09, 2015 9:37 am

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by user0 »

xnview wrote: Sun Dec 04, 2022 2:29 pm I can't disable alpha channel because we don't know if there is 32bits in the file list...
correct, I forgot that we have multiple files in batch )
'Canvas resize' sould not add/delete Alpha channel, only apply some Alpha value to extended canvas space if image already has Alpha

However there is still some 'issue' I would like to address.

Current behaviour, if Alpha channel exists:
  • 'Background color' + 'Alpha' – works as expected (pic 1-3)
  • 'Color of pixel at.'. – does not work as expected
    it applies image's min Alpha value to extended canvas space and there is no way to change it (pic 4, 5)
_combined.png


How to bring more clarity?
  • let 'Alpha' control affect 'Color of pixel at..' as well as 'Background color'
    however some functionality will be lost (ability to apply image's min Alpha value), so maybe..
  • add some selector
    not sure about wording though as all I come up with looks too clunky
    xn_resize_mockup_canvas_extension.png
    xn_resize_mockup_canvas_extension.png (11.99 KiB) Viewed 2148 times
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by xnview »

issue A
'Background color' shows selected color, but with Alpha applied (and on black background*) when dialog reopened.
It should show just selected color.
* it is even not a background color from Batch convert settings tab
See issue for current status and some details.
user0 wrote: Sat Dec 10, 2022 8:01 pm
xnview wrote: Sun Dec 04, 2022 2:29 pm I can't disable alpha channel because we don't know if there is 32bits in the file list...
correct, I forgot that we have multiple files in batch )
'Canvas resize' sould not add/delete Alpha channel, only apply some Alpha value to extended canvas space if image already has Alpha

However there is still some 'issue' I would like to address.

Current behaviour, if Alpha channel exists:
  • 'Background color' + 'Alpha' – works as expected (pic 1-3)
  • 'Color of pixel at.'. – does not work as expected
    it applies image's min Alpha value to extended canvas space and there is no way to change it (pic 4, 5)
No, it takes color with alpha from selected pixel
Pierre.
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by xnview »

This problem is supposed to be fixed in XnView MP 1.4.3. Please check and confirm the bug fix here.
Pierre.
User avatar
user0
XnThusiast
Posts: 2411
Joined: Sat May 09, 2015 9:37 am

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by user0 »

fixed in 1.4.3 (by not memorizing Alpha value)
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by xnview »

user0 wrote: Tue Feb 28, 2023 6:38 am fixed in 1.4.3 (by not memorizing Alpha value)
:bugconfirmed: Thanks to your detailed description I can reproduce the problem.
Pierre.
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by xnview »

This problem is supposed to be fixed in XnView MP 1.4.4. Please check and confirm the bug fix here.
Pierre.
User avatar
user0
XnThusiast
Posts: 2411
Joined: Sat May 09, 2015 9:37 am

Re: 1.4.0b1 - batch convert - 'Canvas resize' background color and alpha

Post by user0 »

fixed in 1.4.4
Post Reply