MCPcopy Create free account
hub / github.com/AOMediaCodec/libavif / DecodeFile

Function DecodeFile

tests/gtest/aviftest_helpers.cc:699–708  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

697}
698
699ImagePtr DecodeFile(const std::string& path) {
700 ImagePtr decoded(avifImageCreateEmpty());
701 DecoderPtr decoder(avifDecoderCreate());
702 if (!decoded || !decoder ||
703 (avifDecoderReadFile(decoder.get(), decoded.get(), path.c_str()) !=
704 AVIF_RESULT_OK)) {
705 return nullptr;
706 }
707 return decoded;
708}
709
710bool Av1EncoderAvailable() {
711 const char* encoding_codec =

Callers 4

TEST_PFunction · 0.85
TESTFunction · 0.85
TEST_PFunction · 0.85
TESTFunction · 0.85

Calls 3

avifImageCreateEmptyFunction · 0.85
avifDecoderCreateFunction · 0.85
avifDecoderReadFileFunction · 0.85

Tested by

no test coverage detected