Path: blob/master/thirdparty/libwebp/src/dec/alphai_dec.h
21362 views
// Copyright 2013 Google Inc. All Rights Reserved.1//2// Use of this source code is governed by a BSD-style license3// that can be found in the COPYING file in the root of the source4// tree. An additional intellectual property rights grant can be found5// in the file PATENTS. All contributing project authors may6// be found in the AUTHORS file in the root of the source tree.7// -----------------------------------------------------------------------------8//9// Alpha decoder: internal header.10//11// Author: Urvang ([email protected])1213#ifndef WEBP_DEC_ALPHAI_DEC_H_14#define WEBP_DEC_ALPHAI_DEC_H_1516#include "src/dec/vp8_dec.h"17#include "src/webp/types.h"18#include "src/dec/webpi_dec.h"19#include "src/dsp/dsp.h"20#include "src/utils/filters_utils.h"2122#ifdef __cplusplus23extern "C" {24#endif2526struct VP8LDecoder; // Defined in dec/vp8li.h.2728typedef struct ALPHDecoder ALPHDecoder;29struct ALPHDecoder {30int width;31int height;32int method;33WEBP_FILTER_TYPE filter;34int pre_processing;35struct VP8LDecoder* vp8l_dec;36VP8Io io;37int use_8b_decode; // Although alpha channel requires only 1 byte per38// pixel, sometimes VP8LDecoder may need to allocate39// 4 bytes per pixel internally during decode.40uint8_t* output;41const uint8_t* prev_line; // last output row (or NULL)42};4344//------------------------------------------------------------------------------45// internal functions. Not public.4647// Deallocate memory associated to dec->alpha_plane decoding48void WebPDeallocateAlphaMemory(VP8Decoder* const dec);4950//------------------------------------------------------------------------------5152#ifdef __cplusplus53} // extern "C"54#endif5556#endif // WEBP_DEC_ALPHAI_DEC_H_575859