summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/libwebp/src/dsp/argb.c
diff options
context:
space:
mode:
authorEirik Aavitsland <eirik.aavitsland@qt.io>2019-11-21 13:50:25 +0100
committerEirik Aavitsland <eirik.aavitsland@qt.io>2019-11-29 09:57:36 +0100
commit218e5a342b289edeac82dbebf9ab62f893964dc2 (patch)
tree4f37d3c2b3866e18700765316805f0fd2ede7960 /src/3rdparty/libwebp/src/dsp/argb.c
parent35382896a4c8f155d45a02ecfc5479b5d6e0db47 (diff)
Update bundled libwebp to version 1.0.3
[ChangeLog][Third-Party Code] Update bundled libwebp to version 1.0.3 (This is a squashed cherry pick from 5.12 branch) Change-Id: I177a6818c5e073298fc565f91d4126af628b7639 Reviewed-by: Andy Nichols <andy.nichols@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io>
Diffstat (limited to 'src/3rdparty/libwebp/src/dsp/argb.c')
-rw-r--r--src/3rdparty/libwebp/src/dsp/argb.c68
1 files changed, 0 insertions, 68 deletions
diff --git a/src/3rdparty/libwebp/src/dsp/argb.c b/src/3rdparty/libwebp/src/dsp/argb.c
deleted file mode 100644
index cc1f9a9..0000000
--- a/src/3rdparty/libwebp/src/dsp/argb.c
+++ /dev/null
@@ -1,68 +0,0 @@
-// Copyright 2014 Google Inc. All Rights Reserved.
-//
-// Use of this source code is governed by a BSD-style license
-// that can be found in the COPYING file in the root of the source
-// tree. An additional intellectual property rights grant can be found
-// in the file PATENTS. All contributing project authors may
-// be found in the AUTHORS file in the root of the source tree.
-// -----------------------------------------------------------------------------
-//
-// ARGB making functions.
-//
-// Author: Djordje Pesut (djordje.pesut@imgtec.com)
-
-#include "./dsp.h"
-
-static WEBP_INLINE uint32_t MakeARGB32(int a, int r, int g, int b) {
- return (((uint32_t)a << 24) | (r << 16) | (g << 8) | b);
-}
-
-static void PackARGB(const uint8_t* a, const uint8_t* r, const uint8_t* g,
- const uint8_t* b, int len, uint32_t* out) {
- int i;
- for (i = 0; i < len; ++i) {
- out[i] = MakeARGB32(a[4 * i], r[4 * i], g[4 * i], b[4 * i]);
- }
-}
-
-static void PackRGB(const uint8_t* r, const uint8_t* g, const uint8_t* b,
- int len, int step, uint32_t* out) {
- int i, offset = 0;
- for (i = 0; i < len; ++i) {
- out[i] = MakeARGB32(0xff, r[offset], g[offset], b[offset]);
- offset += step;
- }
-}
-
-void (*VP8PackARGB)(const uint8_t*, const uint8_t*, const uint8_t*,
- const uint8_t*, int, uint32_t*);
-void (*VP8PackRGB)(const uint8_t*, const uint8_t*, const uint8_t*,
- int, int, uint32_t*);
-
-extern void VP8EncDspARGBInitMIPSdspR2(void);
-extern void VP8EncDspARGBInitSSE2(void);
-
-static volatile VP8CPUInfo argb_last_cpuinfo_used =
- (VP8CPUInfo)&argb_last_cpuinfo_used;
-
-WEBP_TSAN_IGNORE_FUNCTION void VP8EncDspARGBInit(void) {
- if (argb_last_cpuinfo_used == VP8GetCPUInfo) return;
-
- VP8PackARGB = PackARGB;
- VP8PackRGB = PackRGB;
-
- // If defined, use CPUInfo() to overwrite some pointers with faster versions.
- if (VP8GetCPUInfo != NULL) {
-#if defined(WEBP_USE_SSE2)
- if (VP8GetCPUInfo(kSSE2)) {
- VP8EncDspARGBInitSSE2();
- }
-#endif
-#if defined(WEBP_USE_MIPS_DSP_R2)
- if (VP8GetCPUInfo(kMIPSdspR2)) {
- VP8EncDspARGBInitMIPSdspR2();
- }
-#endif
- }
- argb_last_cpuinfo_used = VP8GetCPUInfo;
-}