Comments (25)
...what about hwaccel auto ?
from axiom.
Hi, thanks for the suggestion. I will work on this.
from axiom.
I released an update for you to test.
Press the arrow button in Axiom to update through PowerShell, or download from here
https://github.com/MattMcManis/Axiom/releases
A few issues with Intel QSV
:
I'm using the Software decode
option -init_hw_device qsv=hw -filter_hw_device hw
.
I couldn't get the regular -hwaccel qsv -c:v h264_qsv
to work. It gives the error Decoding pixel format '(null)' is not supported
.
and
x265 -c:v hevc_qsv
gives loading plugin
error, but x264 -c:v h264_qsv
works.
https://trac.ffmpeg.org/wiki/Hardware/QuickSync
Examples
Works
ffmpeg -init_hw_device qsv=hw -filter_hw_device hw -i input.mpg -c:v h264_qsv output.mp4
Doesn't Work
ffmpeg -init_hw_device qsv=hw -filter_hw_device hw -i input.mpg -c:v hevc_qsv output.mp4
ffmpeg -hwaccel qsv -c:v h264_qsv -i input.mpg -c:v h264_qsv output.mp4
ffmpeg -hwaccel qsv -c:v hevc_qsv -i input.mpg -c:v hevc_qsv output.mp4
from axiom.
I did not know it exists, I will add it in the next update soon.
from axiom.
For -hwaccel auto
, it works when converting mp4
→mp4
, mp4
→webm
, or webm
→webm
.
It automatically selects dxva2
.
But when converting webm
→mp4
I get the error:
Cannot load cuvidGetDecodeStatus
Failed loading nvcuvid.
Failed setup for format cuda: hwaccel initialisation returned error.
Cannot load cuvidGetDecodeStatus
I'm not able to test it properly with my hardware. I'll add auto
option, but leave off
as the default so that users don't get hardware errors right out of the box.
from axiom.
Hello Matt, thanks for the support.
Everything was fine, only Intel QSV
was wrong for me.
This was the result of my tests on one input with 15.1 MB with different HW/A options
- The result for other options (like cuda, d3d11va , dxva2) was 14.9 MB
-hwaccel qsv -c:v h264_qsv
works but not same result like others. (output : 62.5 MB !)-init_hw_device qsv=hw -filter_hw_device hw -c:v h264_qsv
works but not same result like others. (output : 62.5 MB !)
But -hwaccel qsv -c:v libx264
works fine and result was like others (output : 14.9 MB)
I think should not change the video codec (-c:v) but, just enough to set -hwaccel qsv
from axiom.
Thanks for the info, I will change Intel QSV
to use -hwaccel qsv -c:v libx264
, but it's not able to auto-detect the input codec for all media, so it may have to just be -hwaccel qsv
.
I'm planning to split the HW Accel options into 2 menus, decode
and transcode
.
Take a look at the options in this post #41 (comment), let me know if it looks correct.
from axiom.
Thanks, but I don't have enough knowledge to comment on this case :)
from axiom.
For
-hwaccel auto
, it works when convertingmp4
→mp4
,mp4
→webm
, orwebm
→webm
.
It automatically selectsdxva2
.But when converting
webm
→mp4
I get the error:
Seems an FFMPEG's bug.
Here's an interesting (verbose) discussion about FFMPEG hw encode:
https://emby.media/community/index.php?/topic/10723-gpu-transcoding-intel-quicksync-and-nvidia-nvenc/
from axiom.
I've released an update with some new options:
- HW Accel
Decode
andTranscode
menus. - HW Accel
Decode
optionauto
. - HW Accel
Transcode
optionAMD AMF
forx264
/x265
. - Video Tab has new Sub Tabs,
Encoding
,Color
,Size
, to reduce the vertical scrolling height.
These changes could introduce new bugs, you will have to test it out and let me know how it works. Certain HW Accel options may need the required Intel/Nvidia/AMD hardware.
Some HW Accel Transcode
codecs are only available for x264
/x265
.
https://github.com/MattMcManis/Axiom/releases
from axiom.
All Transcode options with Decode: CUDA gives an error for me.
Impossible to convert between the formats supported by the filter 'graph 0 input from stream 0:0' and the filter 'auto_scaler_0'
Error reinitializing filters!
Failed to inject frame into filter network: Function not implemented
Error while processing the decoded data for stream #0:0
Conversion failed!
This is output script for decode CUDA and transcode off or auto that gives error.
-hwaccel cuda -hwaccel_output_format cuda
-c:v libx264
from axiom.
Can you find the correct options that work and post the script?
https://trac.ffmpeg.org/wiki/HWAccelIntro#NVDECCUVID
Sample decode using CUDA:
ffmpeg -hwaccel cuda -i input output
Full hardware transcode with NVDEC and NVENC:
ffmpeg -hwaccel cuda -hwaccel_output_format cuda -i input -c:v h264_nvenc -preset slow output
I'm not able to test it with my setup, I get the error:
ffmpeg -hwaccel cuda -hwaccel_output_format cuda -i input.mpg -c:v libx264 output.mp4
Cannot load cuvidGetDecodeStatus
Failed loading nvcuvid.
Failed setup for format cuda: hwaccel initialisation returned error.
Cannot load nvEncodeAPI64.dll
from axiom.
I was only able to get the correct result from the below script (no full hardware transcode - by removing -hwaccel_output_format cuda
)
-hwaccel cuda
-c:v libx264
from axiom.
I will change it in an update.
Does the Intel QSV
work for you?
It uses -hwaccel qsv -hwaccel_output_format qsv
.
Info I could find on -hwaccel_output_format
:
https://gist.github.com/Brainiarc7/95c9338a737aa36d9bb2931bed379219
-hwaccel_output_format : This option should be used every time you declare the -hwaccel method as vaapi , so that the decode stage takes place entirely in hardware. This option generates decode output directly on VAAPI hardware surfaces, speeding up decode performance significantly.
from axiom.
Yes, it works well.
@MattMcManis , I don't know enough about ffmpeg hwaccel, but if you want, I can give you access to my machine (via AnyDesk or etc...) to test different scripts as you wish.
from axiom.
Thanks, I'll let you know if needed.
I've released an update for hwaccel cuda
, and some other improvements, changelog.
from axiom.
Run button doesn't show any reaction anymore in v1.8.3-alpha ?!
But script for CUDA is OK now 👍.
from axiom.
Are you sure? It is working for me. I added support for CMD and PowerShell in the last update.
from axiom.
If you want to, open a separate Issue for the Run button. I am looking into it, trying to optimize the code and find bugs, but I'm unable to reproduce the error.
Let's keep this thread for HW Accel.
from axiom.
Of course, I opened a new issue and explained the cause of the problem.
Thanks again for your support on HW Accel.
from axiom.
I found a problem with Intel QSV.
CRF -crf
does not work, only Bit Rate -b:v
1 and 2 Pass works.
CRF ends up setting the lowest default bit rate when used with -c:v h264_qsv
.
https://trac.ffmpeg.org/wiki/Hardware/QuickSync
It says "ICQ mode (which is similar to crf mode of x264)" -global_quality 25
But I cannot get it to work. I get the error Selected ratecontrol mode is unsupported
.
I've fixed quite a few bugs and added some new features in v1.8.6.0.
from axiom.
It looks like none of the HW Accel codecs will work properly with CRF, they all have their own arguments.
I will have to make a system for the CRF slider that automatically converts the values into -rc:v vbr_hq -cq:v
values along with bit rate.
https://superuser.com/a/1236387/740888
from axiom.
As posted in the above FastFlix "issue", I found some interesting resouces for qsv encodes/filters:
- https://nico-lab.net/installing_qsv_with_ffmpeg/ (Japanese, use translator)
- mdhiggins/sickbeard_mp4_automator#932
Hope that helps/inspires !
from axiom.
OK, seems the (greatest ?) hardware accelerated video encoders expert is @Brainiarc7 here.
I believe he could help us to understand better how to create a right commandline for FFMPEG encodings.
from axiom.
from axiom.
Related Issues (20)
- 中文支持 :sweat_smile: HOT 7
- Simple bug with standard settings
- Preserve folder structure?
- Axiom crashes upon loading preset HOT 3
- Does it auto-update?
- [REQ] Versatile Video Coding (aka x266) support
- AV1 container
- Not able to batch convert? HOT 1
- [SUGGESTION] Optimal parms for "Coding to DVD with FFMPEG"
- Not sure. Issues pasting a link into the input box (youtube-dl)
- video to gif animation? HOT 1
- No exe file anywhere HOT 2
- Project Status HOT 4
- Custom Presets not loading properly.
- Converting DNxHR gives error
- Saving configurations
- language HOT 1
- Crash when input a double quotation mark to Input or Output box HOT 1
- [Question] Is it possible to burn specific subtitles from Input File ?
- cant understand how to just extract files, without encoding with ffmpeg gui? and how to download from youtube with GUI on windows? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from axiom.