PNG files may become quite large, eg. when used for screenshots by the system.
therefore, when sent as DC_MSG_IMAGE, we could try to recode these PNG to a smaller bytesize, similar to what we're doing with large JPG (original PNG can still be sent when sending as DC_MSG_FILE).
recoding could be done by:
- scale down image width/height and/or palette and keep PNG format
- recode to JPG; JPG of the same width/height usually have much smaller bytesize
- a combination of 1. and 2.
- ?
this needs to be tried out. the destination bytes should be comparable with the result of WORSE_IMAGE_SIZE/BALANCED_IMAGE_SIZE, if that is too worse, a factor of that.
this issue is not about introducing new options in the UI, it is just about respecting exiting media-quality setting also for PNG.
nb: for avatars, we are already recoding PNG to JPG (as 2. above), so, the basic functionality is there.
most work will be testing and checking that things work with a changed file name+type.
ftr: this is a succcessor of #1563
PNG files may become quite large, eg. when used for screenshots by the system.
therefore, when sent as
DC_MSG_IMAGE, we could try to recode these PNG to a smaller bytesize, similar to what we're doing with large JPG (originalPNGcan still be sent when sending asDC_MSG_FILE).recoding could be done by:
this needs to be tried out. the destination bytes should be comparable with the result of WORSE_IMAGE_SIZE/BALANCED_IMAGE_SIZE, if that is too worse, a factor of that.
this issue is not about introducing new options in the UI, it is just about respecting exiting media-quality setting also for PNG.
nb: for avatars, we are already recoding PNG to JPG (as 2. above), so, the basic functionality is there.
most work will be testing and checking that things work with a changed file name+type.
ftr: this is a succcessor of #1563