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

use non-default pixel format? #55

Open
bbcuffer opened this issue Oct 2, 2024 · 0 comments
Open

use non-default pixel format? #55

bbcuffer opened this issue Oct 2, 2024 · 0 comments

Comments

@bbcuffer
Copy link

bbcuffer commented Oct 2, 2024

This could be me rather than av. Is there a way to specify the pixel format to be used by the video codec?

Trying to output ProRes with an alpha channel using format yuva444p10le

av sees the prores_ks codec:

> av::av_encoders() |> filter(name=="prores_ks")
   type      name               description      format
1 video prores_ks Apple ProRes (iCodec Pro) yuv422p10le

and ffmpeg sees the yuva444p10le format for that codec:

$ ffmpeg -h encoder=prores_ks

ffmpeg version 7.0.1 Copyright (c) 2000-2024 the FFmpeg developers
  built with Apple clang version 15.0.0 (clang-1500.1.0.2.5)
  configuration: --prefix=/usr/local/Cellar/ffmpeg/7.0.1 --enable-shared --enable-pthreads --enable-version3 --cc=clang --host-cflags= --host-ldflags='-Wl,-ld_classic' --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libaribb24 --enable-libbluray --enable-libdav1d --enable-libharfbuzz --enable-libjxl --enable-libmp3lame --enable-libopus --enable-librav1e --enable-librist --enable-librubberband --enable-libsnappy --enable-libsrt --enable-libssh --enable-libsvtav1 --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libspeex --enable-libsoxr --enable-libzmq --enable-libzimg --disable-libjack --disable-indev=jack --enable-videotoolbox --enable-audiotoolbox
  libavutil      59.  8.100 / 59.  8.100
  libavcodec     61.  3.100 / 61.  3.100
  libavformat    61.  1.100 / 61.  1.100
  libavdevice    61.  1.100 / 61.  1.100
  libavfilter    10.  1.100 / 10.  1.100
  libswscale      8.  1.100 /  8.  1.100
  libswresample   5.  1.100 /  5.  1.100
  libpostproc    58.  1.100 / 58.  1.100
Encoder prores_ks [Apple ProRes (iCodec Pro)]:
    General capabilities: threads 
    Threading capabilities: frame and slice
    Supported pixel formats: yuv422p10le yuv444p10le yuva444p10le <<---- HERE
.....

But can't see a way to tell av to use that format. e.g.

> av::av_encode_video(anim_fns, 
    output = "demo.mov",
    framerate = 25, code = "prores_ks", vfilter = "format=yuva444p10le"
  )

gets me video encoded in the default format

> av::av_media_info("demo.mov"))
$duration
[1] 6

$video
  width height  codec frames framerate      format
1  1920   1080 prores    151        25 yuv422p10le

as does vfilter = "format=pix_fmts=yuva444p10le"

Is it that I haven't specified the pixel format correctly or established whether it is, in fact, available for av?

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

1 participant