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

Function avifInputGetFile

apps/avifenc.c:489–508  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

487}
488
489static const avifInputFile * avifInputGetFile(const avifInput * input, int imageIndex)
490{
491 if (imageIndex < input->cacheCount) {
492 return &input->files[input->cache[imageIndex].fileIndex];
493 }
494 if (input->fileIndex >= input->filesCount) {
495 return NULL;
496 }
497
498 if (input->files[input->fileIndex].filename == AVIF_FILENAME_STDIN) {
499 assert(input->fileIndex == 0);
500 ungetc(fgetc(stdin), stdin); // Kick stdin to force EOF
501
502 if (feof(stdin)) {
503 return NULL;
504 }
505 }
506
507 return &input->files[input->fileIndex];
508}
509
510static avifBool avifInputHasRemainingData(const avifInput * input, int imageIndex)
511{

Callers 3

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected