Expand the 64-bit platforms for VP8LBitWriter

The defines are the same as the ones in bit_reader_utils.h

Change-Id: I3782425baf7dfb861dcc39d7683fba5c15e33f84
This commit is contained in:
Vincent Rabaud
2025-10-10 09:12:33 +02:00
parent e40787da71
commit 61791c774a

View File

@@ -16,6 +16,7 @@
#include <stddef.h>
#include "src/dsp/cpu.h"
#include "src/utils/bounds_safety.h"
#include "src/webp/types.h"
@@ -76,9 +77,10 @@ static WEBP_INLINE size_t VP8BitWriterSize(const VP8BitWriter* const bw) {
//------------------------------------------------------------------------------
// VP8LBitWriter
#if defined(__x86_64__) || defined(_M_X64) // 64bit
typedef uint64_t vp8l_atype_t; // accumulator type
typedef uint32_t vp8l_wtype_t; // writing type
// 64bit
#if defined(__x86_64__) || defined(_M_X64) || WEBP_AARCH64 || defined(__wasm__)
typedef uint64_t vp8l_atype_t; // accumulator type
typedef uint32_t vp8l_wtype_t; // writing type
#define WSWAP HToLE32
#define VP8L_WRITER_BYTES 4 // sizeof(vp8l_wtype_t)
#define VP8L_WRITER_BITS 32 // 8 * sizeof(vp8l_wtype_t)