Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

avif encoding support is not perfect #785

Open
sommio opened this issue Oct 7, 2023 · 1 comment
Open

avif encoding support is not perfect #785

sommio opened this issue Oct 7, 2023 · 1 comment

Comments

@sommio
Copy link

sommio commented Oct 7, 2023

aom can't encode jpeg (yuvj420p) and --pix-format doesn't work,
although it can be replaced with -sc-pix-format for now,
but av1an gives a new error when encoding webp and png.

Information

  • ffmpeg 2:6.0-11.1
  • av1an 0.4.1-1.2
  • via ALHP

Reproduction

av1an -i test.jpg --pix-format yuv444p10le -o test.jpg.avif
av1an -i test.jpg --sc-pix-format yuv444p10le -o test.jpg.avif
av1an -i test.webp --sc-pix-format yuv444p10le -o test.webp.avif
av1an -i test.png --sc-pix-format yuv444p10le -o test.png.avif

Expected

  • Ability to encode png and webp
  • --pix-format works fine like ffmpeg's -pix_fmt

Actual

❯ av1an -i test.jpg --pix-format yuv444p10le -o test.jpg.avif
INFO [av1an_core::settings] Input: 4032x3024 @ 25.000 fps, YUVJ420P, SDR
Scene detection
00:00:00 ▕                                      ▏   0%  0/1 (0 fps, eta unknown)
Error: aom does not support YUVJ420P
❯ av1an -i test.webp --sc-pix-format yuv444p10le -o test.webp.avif
INFO [av1an_core::settings] Input: 1920x1080 @ 25.000 fps, ARGB, SDR
Scene detection
INFO [av1an_core::settings] scenecut: found 1 scene(s) [with extra_splits (250 frames): 1 scene(s)]
  00:00:00 ▕█████████████████████████████████████████████████████████████████████████████████████████████▏ 100%  1/1 (5.09 fps, eta 0s)Queue 1 Workers 1 Passes 2
Params: --threads=8 --cpu-used=6 --end-usage=q --cq-level=30 --tile-columns=1 --tile-rows=0
WARN [av1an_core::broker] Encoder failed (on chunk 0):
encoder crashed: exit status: 1
stdout:

stderr:
        Fatal: Specify stream dimensions with --width (-w)  and --height (-h)


source pipe stderr:
        Warning: setVideoInfo: Video filter LWLibavSource has more than one output node but only the first one will be returned
        Error: can only apply y4m headers to YUV and Gray format clips without alpha
        Output 1 frames in 55264.79 seconds (0.00 fps)
        Warning: Core freed but 1 filter instance(s) still exist
        Warning: Core freed but 8294656 bytes still allocated in framebuffers

ffmpeg pipe stderr:
        fd:: Invalid data found when processing input

WARN [av1an_core::broker] Encoder failed (on chunk 0):
encoder crashed: exit status: 1
stdout:

stderr:
        Fatal: Specify stream dimensions with --width (-w)  and --height (-h)


source pipe stderr:
        Warning: setVideoInfo: Video filter LWLibavSource has more than one output node but only the first one will be returned
        Error: can only apply y4m headers to YUV and Gray format clips without alpha
        Output 1 frames in 55264.97 seconds (0.00 fps)
        Warning: Core freed but 1 filter instance(s) still exist
        Warning: Core freed but 8294656 bytes still allocated in framebuffers

ffmpeg pipe stderr:
        fd:: Invalid data found when processing input

ERROR [av1an_core::broker] [chunk 0] encoder failed 3 times, shutting down worker
ERROR [av1an_core::broker] [chunk 0] encoder crashed: exit status: 1
stdout:

stderr:
        Fatal: Specify stream dimensions with --width (-w)  and --height (-h)


source pipe stderr:
        Warning: setVideoInfo: Video filter LWLibavSource has more than one output node but only the first one will be returned
        Error: can only apply y4m headers to YUV and Gray format clips without alpha
        Output 1 frames in 55265.16 seconds (0.00 fps)
        Warning: Core freed but 1 filter instance(s) still exist
        Warning: Core freed but 8294656 bytes still allocated in framebuffers

ffmpeg pipe stderr:
        fd:: Invalid data found when processing input

Sample
Samples.zip

@BlueSwordM
Copy link
Contributor

Why not encode using avifenc?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants