mirror of
https://chromium.googlesource.com/libyuv/libyuv
synced 2025-12-06 16:56:55 +08:00
Add ARGBToABGR and ARGBToBGRA as actual functions instead of macros.
BUG=334 TESTED=libyuv unittests pass R=tpsiaki@google.com Review URL: https://webrtc-codereview.appspot.com/12659006 git-svn-id: http://libyuv.googlecode.com/svn/trunk@1008 16f28f9a-4ce2-e073-06de-1de4eb20be90
This commit is contained in:
parent
40a1d85579
commit
2a35da3912
@ -1,6 +1,6 @@
|
|||||||
Name: libyuv
|
Name: libyuv
|
||||||
URL: http://code.google.com/p/libyuv/
|
URL: http://code.google.com/p/libyuv/
|
||||||
Version: 1007
|
Version: 1008
|
||||||
License: BSD
|
License: BSD
|
||||||
License File: LICENSE
|
License File: LICENSE
|
||||||
|
|
||||||
|
|||||||
@ -25,24 +25,22 @@ int ARGBCopy(const uint8* src_argb, int src_stride_argb,
|
|||||||
uint8* dst_argb, int dst_stride_argb,
|
uint8* dst_argb, int dst_stride_argb,
|
||||||
int width, int height);
|
int width, int height);
|
||||||
|
|
||||||
// Convert ARGB To BGRA. (alias)
|
// Convert ARGB To BGRA.
|
||||||
#define ARGBToBGRA BGRAToARGB
|
|
||||||
LIBYUV_API
|
LIBYUV_API
|
||||||
int BGRAToARGB(const uint8* src_frame, int src_stride_frame,
|
int ARGBToBGRA(const uint8* src_argb, int src_stride_argb,
|
||||||
uint8* dst_argb, int dst_stride_argb,
|
uint8* dst_bgra, int dst_stride_bgra,
|
||||||
int width, int height);
|
int width, int height);
|
||||||
|
|
||||||
// Convert ARGB To ABGR. (alias)
|
// Convert ARGB To ABGR.
|
||||||
#define ARGBToABGR ABGRToARGB
|
|
||||||
LIBYUV_API
|
LIBYUV_API
|
||||||
int ABGRToARGB(const uint8* src_frame, int src_stride_frame,
|
int ARGBToABGR(const uint8* src_argb, int src_stride_argb,
|
||||||
uint8* dst_argb, int dst_stride_argb,
|
uint8* dst_abgr, int dst_stride_abgr,
|
||||||
int width, int height);
|
int width, int height);
|
||||||
|
|
||||||
// Convert ARGB To RGBA.
|
// Convert ARGB To RGBA.
|
||||||
LIBYUV_API
|
LIBYUV_API
|
||||||
int ARGBToRGBA(const uint8* src_frame, int src_stride_frame,
|
int ARGBToRGBA(const uint8* src_argb, int src_stride_argb,
|
||||||
uint8* dst_argb, int dst_stride_argb,
|
uint8* dst_rgba, int dst_stride_rgba,
|
||||||
int width, int height);
|
int width, int height);
|
||||||
|
|
||||||
// Convert ARGB To RGB24.
|
// Convert ARGB To RGB24.
|
||||||
|
|||||||
@ -11,6 +11,6 @@
|
|||||||
#ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT
|
#ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT
|
||||||
#define INCLUDE_LIBYUV_VERSION_H_
|
#define INCLUDE_LIBYUV_VERSION_H_
|
||||||
|
|
||||||
#define LIBYUV_VERSION 1007
|
#define LIBYUV_VERSION 1008
|
||||||
|
|
||||||
#endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT
|
#endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT
|
||||||
|
|||||||
@ -372,6 +372,17 @@ int BGRAToARGB(const uint8* src_bgra, int src_stride_bgra,
|
|||||||
width, height);
|
width, height);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Convert ARGB to BGRA (same as BGRAToARGB).
|
||||||
|
LIBYUV_API
|
||||||
|
int ARGBToBGRA(const uint8* src_bgra, int src_stride_bgra,
|
||||||
|
uint8* dst_argb, int dst_stride_argb,
|
||||||
|
int width, int height) {
|
||||||
|
return ARGBShuffle(src_bgra, src_stride_bgra,
|
||||||
|
dst_argb, dst_stride_argb,
|
||||||
|
(const uint8*)(&kShuffleMaskBGRAToARGB),
|
||||||
|
width, height);
|
||||||
|
}
|
||||||
|
|
||||||
// Convert ABGR to ARGB.
|
// Convert ABGR to ARGB.
|
||||||
LIBYUV_API
|
LIBYUV_API
|
||||||
int ABGRToARGB(const uint8* src_abgr, int src_stride_abgr,
|
int ABGRToARGB(const uint8* src_abgr, int src_stride_abgr,
|
||||||
@ -383,6 +394,17 @@ int ABGRToARGB(const uint8* src_abgr, int src_stride_abgr,
|
|||||||
width, height);
|
width, height);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Convert ARGB to ABGR to (same as ABGRToARGB).
|
||||||
|
LIBYUV_API
|
||||||
|
int ARGBToABGR(const uint8* src_abgr, int src_stride_abgr,
|
||||||
|
uint8* dst_argb, int dst_stride_argb,
|
||||||
|
int width, int height) {
|
||||||
|
return ARGBShuffle(src_abgr, src_stride_abgr,
|
||||||
|
dst_argb, dst_stride_argb,
|
||||||
|
(const uint8*)(&kShuffleMaskABGRToARGB),
|
||||||
|
width, height);
|
||||||
|
}
|
||||||
|
|
||||||
// Convert RGBA to ARGB.
|
// Convert RGBA to ARGB.
|
||||||
LIBYUV_API
|
LIBYUV_API
|
||||||
int RGBAToARGB(const uint8* src_rgba, int src_stride_rgba,
|
int RGBAToARGB(const uint8* src_rgba, int src_stride_rgba,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user