2 * (C) GraÅžvydas "notaz" Ignotas, 2011
4 * This work is licensed under the terms of any of these licenses
6 * - GNU GPL, version 2 or later.
7 * - GNU LGPL, version 2.1 or later.
8 * See the COPYING file in the top-level directory.
14 @ void *dst, const void *src, int count, uint abits
15 .macro do_argb bgr2rgb
20 vswp d4, d6 @ BGR->RGB
31 @ void *dst, const void *src, int count
32 .macro do_argb_alpha bgr2rgb
39 vswp d4, d6 @ BGR->RGB
42 @ d = (((s-d)*a+255)>>8)+d
49 vaddhn.i16 d4, q8, q12
50 vaddhn.i16 d5, q9, q12
51 vaddhn.i16 d6, q10,q12
64 @ void *dst, const void *src, int count, uint alpha
65 .macro do_argb_alphaS bgr2rgb
73 vswp d4, d6 @ BGR->RGB
75 @ d = (((s-d)*a+255)>>8)+d
82 vaddhn.i16 d4, q8, q12
83 vaddhn.i16 d5, q9, q12
84 vaddhn.i16 d6, q10,q12
99 vzip.8 d4, d5 @ RRR..|GGG.. -> RGRG..
100 vzip.8 d6, d7 @ BBB..|000.. -> B0B0..
125 .global neon_ARGBtoXRGB
129 .global neon_ABGRtoXRGB
133 .global neon_ARGBtoXRGBalpha
134 neon_ARGBtoXRGBalpha:
137 .global neon_ABGRtoXRGBalpha
138 neon_ABGRtoXRGBalpha:
141 .global neon_ARGBtoXRGBalphaS
142 neon_ARGBtoXRGBalphaS:
145 .global neon_ABGRtoXRGBalphaS
146 neon_ABGRtoXRGBalphaS:
149 @ vim:filetype=armasm