Giter VIP home page Giter VIP logo

Comments (26)

th0ma7 avatar th0ma7 commented on July 20, 2024 2

@AlexPresso the following should provide the list of decoders available, which in turn depends of the platform and ffmpeg version in usage:

$ /usr/local/bin/ffmpeg6 -hide_banner -decoders | grep -i mpeg
 VFS..D ffv1                 FFmpeg video codec #1
 VF..BD ffvhuff              Huffyuv FFmpeg variant
 VFS..D h264                 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
 V....D libopenh264          OpenH264 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 (codec h264)
 V.S.BD mpeg1video           MPEG-1 video
 V..... mpeg1_v4l2m2m        V4L2 mem2mem MPEG1 decoder wrapper (codec mpeg1video)
 V.S.BD mpeg2video           MPEG-2 video
 V.S.BD mpegvideo            MPEG-1 video (codec mpeg2video)
 V..... mpeg2_v4l2m2m        V4L2 mem2mem MPEG2 decoder wrapper (codec mpeg2video)
 V....D mpeg2_qsv            MPEG2VIDEO video (Intel Quick Sync Video acceleration) (codec mpeg2video)
 VF..BD mpeg4                MPEG-4 part 2
 V..... mpeg4_v4l2m2m        V4L2 mem2mem MPEG4 decoder wrapper (codec mpeg4)
 V...BD msmpeg4v1            MPEG-4 part 2 Microsoft variant version 1
 V...BD msmpeg4v2            MPEG-4 part 2 Microsoft variant version 2
 V...BD msmpeg4              MPEG-4 part 2 Microsoft variant version 3 (codec msmpeg4v3)
 A....D mp1                  MP1 (MPEG audio layer 1)
 A....D mp1float             MP1 (MPEG audio layer 1) (codec mp1)
 A....D mp2                  MP2 (MPEG audio layer 2)
 A....D mp2float             MP2 (MPEG audio layer 2) (codec mp2)
 A....D mp3float             MP3 (MPEG audio layer 3) (codec mp3)
 A....D mp3                  MP3 (MPEG audio layer 3)
 A....D mp3adufloat          ADU (Application Data Unit) MP3 (MPEG audio layer 3) (codec mp3adu)
 A....D mp3adu               ADU (Application Data Unit) MP3 (MPEG audio layer 3)
 A....D als                  MPEG-4 Audio Lossless Coding (ALS) (codec mp4als)

And to get more details on a specific decoder:

$ /usr/local/bin/ffmpeg6 -hide_banner -h decoder=mpeg4
Decoder mpeg4 [MPEG-4 part 2]:
    General capabilities: horizband dr1 delay threads 
    Threading capabilities: frame
    Supported hardware devices: vaapi 
    Supported pixel formats: vaapi yuv420p
MPEG4 Video Decoder AVOptions:

Considering DS220+ is a geminilake (x64) pretty much everything should be enabled including vaapi acceleration.

EDIT: in order to use vainfo you must use sudo access or a user account that has group videodriver permissions:

sudo su -s /bin/bash sc-ffmpeg -c '/var/packages/ffmpeg6/target/bin/vainfo'
Password:  ************
Trying display: drm
libva info: VA-API version 1.18.0
libva info: Trying to open /var/packages/ffmpeg6/target/lib/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_18
libva info: va_openDriver() returns 0
vainfo: VA-API version: 1.18 (libva 2.18.1)
vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 23.1.6 (3359d2df)
vainfo: Supported profile and entrypoints
      VAProfileNone                   :	VAEntrypointVideoProc
      VAProfileNone                   :	VAEntrypointStats
      VAProfileMPEG2Simple            :	VAEntrypointVLD
      VAProfileMPEG2Main              :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointEncSlice
      VAProfileH264Main               :	VAEntrypointFEI
      VAProfileH264Main               :	VAEntrypointEncSliceLP
      VAProfileH264High               :	VAEntrypointVLD
      VAProfileH264High               :	VAEntrypointEncSlice
      VAProfileH264High               :	VAEntrypointFEI
      VAProfileH264High               :	VAEntrypointEncSliceLP
      VAProfileVC1Simple              :	VAEntrypointVLD
      VAProfileVC1Main                :	VAEntrypointVLD
      VAProfileVC1Advanced            :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointEncPicture
      VAProfileH264ConstrainedBaseline:	VAEntrypointVLD
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSlice
      VAProfileH264ConstrainedBaseline:	VAEntrypointFEI
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSliceLP
      VAProfileVP8Version0_3          :	VAEntrypointVLD
      VAProfileVP8Version0_3          :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointVLD
      VAProfileHEVCMain               :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointFEI
      VAProfileHEVCMain10             :	VAEntrypointVLD
      VAProfileVP9Profile0            :	VAEntrypointVLD

So issue may well be that the @dmoskovchenko may be using an account which isn't part of the videodriver group

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024 2

Hello, I have tried new solution and at once everything works fine for me now.
Great job.
I will stay on your solution, it is nice to be intouch with developer in resolving an issue.
I wat to thank you one more time for your work .

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024 1

Hello,

I'll have a look at it as soon as I can

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024 1

Hello @dmoskovchenko

I made a fix attempt in the linked PR, could you try to use the following procedure to test it please:

  • uninstall the patch : curl https://raw.githubusercontent.com/AlexPresso/VideoStation-FFMPEG-Patcher/fix_scale_vaapi/patcher.sh | bash -s -- -a unpatch
  • install the new patch curl https://raw.githubusercontent.com/AlexPresso/VideoStation-FFMPEG-Patcher/fix_scale_vaapi/patcher.sh | bash -s -- -a patch -b fix_scale_vaapi

If you still have an issue please run the issue-report tool and post the result here again

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024 1

After patching on this link(branch) the video picture is strange: image

and if I do unpatch video picture format became normal but without eac3(( : image

this part is fixed, but in general the videos that plays in unpatched mode still has problem with playing after patching

Here is log: https://gist.github.com/dmoskovchenko/ce76407af830f24ef1257a18c123f64a

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024 1

Thank you for the feedback
I tried to re-add the vaapi to the filter chain, could you please unpatch/repatch using the same commands and give it a try

Could you also give me the ouput of the following command:

  • vainfo
  • (only in case the first one didn't work) /bin/vainfo

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024 1

Tried to repatch - nothig changed :(
Here is vainfo: https://gist.github.com/dmoskovchenko/4d87abe48fa9fa470ac94618b0069366

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024 1

Do you have any output if running /var/packages/VideoStation/target/bin/vainfo ?
Unfortunately, I can't test it by myself because my NAS is not having an Intel CPU and so doesn't have VAAPI

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024 1

Thank you for the feedback @th0ma7 :)

And thank to you @dmoskovchenko for your will to help and for giving informations from the commands, it's highly appreciated 👌.
But the one you used are for ffmpeg6 and I see from the issue-report that your patch configuration is using ffmpeg4, could you give me the output of the following commands for ffmpeg4 please (needs sudo):

  • /var/packages/ffmpeg/target/bin/ffmpeg4 -hide_banner -decoders | grep -i mpeg
  • sudo su -s /bin/bash sc-ffmpeg -c '/var/packages/ffmpeg/target/bin/vainfo'
  • and also this one to see what are the capabilities of VideoStation's default ffmpeg: /var/packages/VideoStation/target/bin/ffmpeg.orig -hide_banner -decoders | grep -i mpeg

To give some explainations about my thoughts:
The reason why it's working with the other wrapper you're using, is because the other wrapper is in first case, trying to run the transcoding with the default VideoStation's ffmpeg. My wrapper is only using the SynoCommunity's ffmpeg. I decided to do it this way because the SC ffmpeg is having way more capabilities and is containing latest ffmpeg optimizations.

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024 1

Hello @dmoskovchenko

If you have time, I made a new patch to try my theory about the previous comment, if you are okay to try it here are the steps:

  • uninstall the other patch (the two patches are incompatible)
  • uninstall the patch : curl https://raw.githubusercontent.com/AlexPresso/VideoStation-FFMPEG-Patcher/multitry_ffmpeg/patcher.sh | bash -s -- -a unpatch
  • install the new patch curl https://raw.githubusercontent.com/AlexPresso/VideoStation-FFMPEG-Patcher/multitry_ffmpeg/patcher.sh | bash -s -- -a patch -b multitry_ffmpeg

If you still have an issue please run the issue-report tool and post the result here again

PS : If you have time, please also send me the output of the other commands ;)

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024 1

Fixed

from videostation-ffmpeg-patcher.

Gargaj avatar Gargaj commented on July 20, 2024 1

Seems to be working on the few I tried! If I run into issues I'll come back.

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024

Hello, first of all I want to thank you for your work.
I have treid ^
image

No changes for me

Here is log file: https://gist.github.com/dmoskovchenko/c8f058d6149bbf83341ac551b14ca1a0

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024

After patching on this link(branch) the video picture is strange:
image

and if I do unpatch video picture format became normal but without eac3(( :
image

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024

My bad, I inverted the width and height, could you please unpatch and repatch using the same above commands

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024

Here is /var/packages/VideoStation/target/bin/vainfo
vainfo.zip

If it is neccesarry I could make a vpn with acces to my nas to fix an issue

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024

Thank you for the report :)

Hello @th0ma7, I hope you're doing well
By any chance, do you have an idea why the OP is able to play the video with default ffmpeg but not with the SC's ffmpeg ? For me the args looks pretty similar, could it be possible the SC's ffmpeg is missing the MPEG4 Advanced Simple profile ?

Key infos: https://gist.github.com/dmoskovchenko/c8f058d6149bbf83341ac551b14ca1a0

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024

Hello, @th0ma7 thx for your answer. Here is New logs: https://gist.github.com/dmoskovchenko/4e5f79795ac0b0da7541e0e7dc1bd0ac with the commands that you provided.

For this time I found another resource with wrapper patcher(as a work around) that helps me to solve the issue , now all formats are played well.

I still want to understand if this problem is only mine and still want to help @AlexPresso to enchance his project :)

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024

Thank you very much for testing :)
I'm glad everything working fine, but could you please just give me the output of the commands in the following comment so I can have a deep understanding of what was not working fine in the first try please: #95 (comment)

from videostation-ffmpeg-patcher.

dmoskovchenko avatar dmoskovchenko commented on July 20, 2024

Here are logs: https://gist.github.com/dmoskovchenko/cea0724f701ea6f7f10192297f90acb0

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024

Thank you :)

from videostation-ffmpeg-patcher.

Gargaj avatar Gargaj commented on July 20, 2024

@AlexPresso
Getting the same issue with some HEVC files - work fine before patching, don't work at all after.
Log: https://pastebin.com/raw/aWjq4cej

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024

Hi @Gargaj
Thank you for the report, could you provide me the video file so I can do some tests locally please ?

from videostation-ffmpeg-patcher.

Gargaj avatar Gargaj commented on July 20, 2024

Any HEVC file will do that has yuv420p10le pixel format:
https://www.dropbox.com/scl/fi/0p81fmldvrvxzip6jlv0r/Big_Buck_Bunny_1080_10s_30MB-yuv420p10le.mp4?rlkey=rw96xaib9v0t0v97l3yumvn0v&dl=0

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024

I made a fix attempt in the linked PR (#102) , could you try to use the following procedure to test it please:

  • uninstall the patch : curl https://raw.githubusercontent.com/AlexPresso/VideoStation-FFMPEG-Patcher/fix_err_code/patcher.sh | bash -s -- -a unpatch
  • install the new patch curl https://raw.githubusercontent.com/AlexPresso/VideoStation-FFMPEG-Patcher/fix_err_code/patcher.sh | bash -s -- -a patch -b fix_err_code

If you still have an issue please run the issue-report tool and post the result here again

from videostation-ffmpeg-patcher.

AlexPresso avatar AlexPresso commented on July 20, 2024

Alright, thank you for testing :)

from videostation-ffmpeg-patcher.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.