• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Off Topic Self-hosting & Homelabs Arc A380 QSV/HWA?

     
    • 0 Vote(s) - 0 Average

    Arc A380 QSV/HWA?

    Not just for Jellyfin, but for ffmpeg in general...
    bitmap
    Offline

    Community Moderator

    Posts: 821
    Threads: 9
    Joined: 2023 Jul
    Reputation: 27
    #18
    2023-09-13, 07:16 AM
    Okay, an update. I posted a bit in the other topic, but this is dedicated to AV1. I'm refining my tactics and have a bit of a template going on...I'm going with two-pass ABR since that's about all I can get to work with av1_qsv at the moment and it gives me the best bang for my buck with a variety of different media. Quick and dirty script:

    Code:
    # input file path
    MEDIA="/path/to/media.mkv" && \
    # output file template without extras or file extension
    OUTPUT="/path/to/media" && \
    # clean title (optional)
    CLNTTL=""
    # quality indicator
    QUALITY="Bluray" && \
    # resolution indicator
    RES="2160p" && \
    # release group indicator
    GRP="bitmap" && \
    # audio language(s)
    LNG="EN" && \
    # subtitle languages
    SUBS="EN" && \
    # video bit rate
    BV="10M" && \
    # max vid bit rate
    MRATE="20M" && \
    # vid buffer size
    BSIZE="40M" && \
    # English audio stream index
    ENAUD="0" && \
    # English subtitle stream index
    ENSUB="0" && \
    # Additional mappings (use full -map [input]:[stream-type]:[index] syntax)
    ADDMP="-map 0:a:1 -map 0:s:2" && \
    ffmpeg -y -hide_banner -v quiet -stats \
        -hwaccel qsv -hwaccel_output_format qsv -qsv_device /dev/dri/renderD129 \
        -i "${MEDIA}" -pass 1 -map 0:v -c:v av1_qsv -preset slower -an -sn \
        -b:v "${BV}" -maxrate:v "${MRATE}" -bufsize:v "${BSIZE}" \
        -look_ahead 1 -look_ahead_depth 100 \
        "${OUTPUT} [${QUALITY}-${RES} AV1 OPUS 2.0+5.1][${LNG][${SUBS}]-${GRP}.mkv" && \
    ffmpeg -y -hide_banner \
        -hwaccel qsv -hwaccel_output_format qsv -qsv_device /dev/dri/renderD129 \
        -i "${MEDIA}" -pass 2 -map 0:v:0 \
        -map 0:a:"${ENAUD}" -map 0:a:"${ENAUD}" -map 0:a:"${ENSUB}" \
        "${ADDMP}" \
        -c:v av1_qsv -preset slower -look_ahead 1 -look_ahead_depth 100 \
        -b:v "${BV}" -maxrate:v "${MRATE}" -bufsize:v "${BSIZE}" \
        -c:a libopus -ac:a:0 2 -b:a:0 192k -ac:a:1 6 -b:a:1 256k \
        -filter:a:0 "pan=stereo|FL<FC+0.30*FL+0.30*BL|FR<FC+0.30*FR+0.30*BR" \
           -c:s copy
           -metadata title="${CLNTTL} | ${GRP}" \
           -metadata:s:v:0 title='AV1 "${RES}" "${BV}" ABR' \
           -metadata:s:a:0 title='English OPUS Stereo Dialog Mix' \
           -metadata:s:a:1 title='English OPUS 5.1' \
           -metadata:s:s:0 title='English' \
           -metadata:s:s:1 title='English (SDH)' \
           "${OUTPUT} [${QUALITY}-${RES} AV1 OPUS 2.0+5.1][${LNG][${SUBS}]-${GRP}.mkv" && \
           rm ffmpeg2pass*

    Still haven't figured out the best way to automate selection for a bunch of stuff. Beginning to reach my limits on bash scripting, partially because I'm just writing these to copy and paste into the shell. I'll probably throw together a Python script or two in the coming days to see if I can get anything working on that front with a bit more friendly UX and maybe some deeper exploration of files.
    Jellyfin 10.10.7 LSIO Docker | Ubuntu 24.04 LTS | i7-13700K | Arc A380 6 GB | 64 GB RAM | 79 TB Storage

    [Image: AIL4fc84QG6uSnTDEZiCCtosg7uAA8x9j1myFaFs...qL0Q=w2400]
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    Messages In This Thread
    Arc A380 QSV/HWA? - by bitmap - 2023-08-28, 03:01 AM
    RE: Arc A380 QSV/HWA? - by TheDreadPirate - 2023-08-28, 03:55 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-08-28, 04:22 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-08-28, 10:39 PM
    RE: Arc A380 QSV/HWA? - by nyanmisaka - 2023-08-29, 12:45 AM
    RE: Arc A380 QSV/HWA? - by TheDreadPirate - 2023-08-29, 03:57 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-08-29, 01:07 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-08-29, 05:23 AM
    RE: Arc A380 QSV/HWA? - by TheDreadPirate - 2023-08-29, 05:31 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-08-29, 05:30 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-08-29, 05:38 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-09-04, 09:02 AM
    RE: Arc A380 QSV/HWA? - by nyanmisaka - 2023-09-04, 09:45 AM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-09-04, 09:53 AM
    RE: Arc A380 QSV/HWA? - by nyanmisaka - 2023-09-04, 12:27 PM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-09-04, 07:11 PM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-09-06, 03:56 PM
    RE: Arc A380 QSV/HWA? - by bitmap - 2023-09-13, 07:16 AM

    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode