]> git.ipfire.org Git - thirdparty/freeswitch.git/commit
FS-7500: libpng 1.6.0 has much simpler APIs, also add a new switch_img_patch_png...
authorSeven Du <dujinfang@gmail.com>
Sun, 15 Feb 2015 05:49:43 +0000 (13:49 +0800)
committerMichael Jerris <mike@jerris.com>
Thu, 28 May 2015 17:47:02 +0000 (12:47 -0500)
commite02ff26569e34afd743d679bd1775cbc2fd608fd
tree48c126f4a5c1d489e2d92267889f107d87f50090
parentf4fad4e7568e8527b990dc23e2786d907c49592f
FS-7500: libpng 1.6.0 has much simpler APIs, also add a new switch_img_patch_png to possible patch a transparent png to an img

While this is not optimal, we should cache the png:
1) cache the whole buffer, with comes with RGBARGBA pixel formats
2) Allow switch_image_t to be other formats e.g. VPX_IMG_FMT_ARGB, VPX_IMG_FMT_ARGB_LE, or VPX_IMG_FMT_444A
   those can have alpha channels so we can check the alpha channel before we patch

Note all PNG are created equel, or maybe a bug in libpng since for some PNG files with alpha the returned buffer
     not seems like RGBARGBA... while docs says it should default be RGBA
src/include/switch_core_video.h
src/switch_core_video.c