tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

apng.h (826B)


      1 // Copyright (c) the JPEG XL Project Authors. All rights reserved.
      2 //
      3 // Use of this source code is governed by a BSD-style
      4 // license that can be found in the LICENSE file.
      5 
      6 #ifndef LIB_EXTRAS_DEC_APNG_H_
      7 #define LIB_EXTRAS_DEC_APNG_H_
      8 
      9 // Decodes APNG images in memory.
     10 
     11 #include <cstdint>
     12 
     13 #include "lib/extras/dec/color_hints.h"
     14 #include "lib/extras/packed_image.h"
     15 #include "lib/jxl/base/span.h"
     16 #include "lib/jxl/base/status.h"
     17 
     18 namespace jxl {
     19 
     20 struct SizeConstraints;
     21 
     22 namespace extras {
     23 
     24 bool CanDecodeAPNG();
     25 
     26 // Decodes `bytes` into `ppf`.
     27 Status DecodeImageAPNG(Span<const uint8_t> bytes, const ColorHints& color_hints,
     28                       PackedPixelFile* ppf,
     29                       const SizeConstraints* constraints = nullptr);
     30 
     31 }  // namespace extras
     32 }  // namespace jxl
     33 
     34 #endif  // LIB_EXTRAS_DEC_APNG_H_