# Ffmpeg 4.0 w/ Radeon HW encoder

**URL:** https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710
**Category:** New Features
**Created:** [April 22, 2018, 6:29pm UTC](https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710 "2018-04-22T18:29:04Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![mch](https://discussion.mcebuddy2x.com/letter_avatar_proxy/v4/letter/m/898d66/32.png) [@mch](https://discussion.mcebuddy2x.com/u/mch)
#### Post date: [April 22, 2018, 6:29pm UTC](https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710/1 "2018-04-22T18:29:05Z")

</div>

**Request Type:**  
NEW FEATURE

**Summary of the problem or suggestion:**  
ffmpeg released v4.0 yesterday. It includes AMF hardware encoding for AMD GPUs.

I know it might take time with a major release, but a version of MCEBuddy that bundles 4.0 and includes AMF in the hardware acceleration checkbox would be appreciated. Presently running a three-step process where MCEBuddy cuts commercials and then moves files before they’re encoded by another encoder, and then finally moves the result;I miss the all-in-one setup. 🙂

---

<div class="post-metadata">

### Author: ![Goose](https://discussion.mcebuddy2x.com/letter_avatar_proxy/v4/letter/g/5f9b8f/32.png) [@Goose](https://discussion.mcebuddy2x.com/u/Goose)
#### Post date: [April 23, 2018, 12:14am UTC](https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710/2 "2018-04-23T00:14:10Z")

</div>

We don’t have access to an AMF encoding card. Maybe you can download the latest build, replace it in MCEBuddy, modify the profile to use `h264_amf` and `hevc_amf` as the encoders and let us know how it goes.

The tricky question for MCEBuddy is how to detect if AMF encoding is available.

---

<div class="post-metadata">

### Author: ![mch](https://discussion.mcebuddy2x.com/letter_avatar_proxy/v4/letter/m/898d66/32.png) [@mch](https://discussion.mcebuddy2x.com/u/mch)
#### Post date: [April 23, 2018, 12:24am UTC](https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710/3 "2018-04-23T00:24:27Z")

</div>

Tried responding by email and it didn’t appear to work, so apologies if there’s two replies.

According to [docs](https://github.com/GPUOpen-LibrariesAndSDKs/AMF), AMF (which itself is just an expansion/rebranding of AMD’s old VCE) is supported by every Radeon manufactured since the HD7000 dGPUs of 2012, so anyone who has oneone kicking around from years ago it should work. I suppose I can zip up my installation folder for backup and try to port the new code into an existing installation, but I’m not familiar with how MCEBuddy works, so apart from replacing files in \ffmpeg I’m not sure where to look.

---

<div class="post-metadata">

### Author: ![mch](https://discussion.mcebuddy2x.com/letter_avatar_proxy/v4/letter/m/898d66/32.png) [@mch](https://discussion.mcebuddy2x.com/u/mch)
#### Post date: [April 24, 2018, 7:43am UTC](https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710/4 "2018-04-24T07:43:59Z")

</div>

So here’s my trip report:

1. Downloaded Zeranoe’s nightly git build to replace the shipped copy. I don’t know what version of ffmpeg you ship with MCEBuddy, but be aware if you compile it on your own you’ll need to get AMF’s headers from another github account for inclusion. Zeranoe doesn’t have a 4.0 release build out yet, but the nightly was stable for testing.

2. Went into the profiles file to set ffmpeg as my primary encoder, and changed the -encoder flag to `-c:v h264_amf` (HEVC is `hevc_amf`, fwiw) and . I don’t know how MCEBuddy looks for hardware acceleration and applies the flags as needed, but this is the line you’d have to use. Video encoded fine, plays normally, logs show that amf encoder was called successfully. On a very basic budget Radeon (Vega 8 graphics onboard a $99 Ryzen 3 2200G) the encoder can move very quickly. I don’t know how to see FPS in MCEBuddy, but I have seen VCEnc used in StaxRip and A’s hit 120fps on this budget APU.

So I have it working for now, it seems “ready for use”. If I run into any issues I’ll let you know but I think it seems good.

---

<div class="post-metadata">

### Author: ![Goose](https://discussion.mcebuddy2x.com/letter_avatar_proxy/v4/letter/g/5f9b8f/32.png) [@Goose](https://discussion.mcebuddy2x.com/u/Goose)
#### Post date: [May 29, 2018, 11:36pm UTC](https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710/5 "2018-05-29T23:36:13Z")

</div>

Linking posts:

> [@MCEBuddy and FFMPEG-AMD: Broken File, Huge Logs](https://discussion.mcebuddy2x.com/t/mcebuddy-and-ffmpeg-amd-broken-file-huge-logs/1809/):
>
> You guys mentioned in the past that you don’t have any AMD hardware to test with, so I’m testing on my own. I renamed/replaced the ffmpeg/ffprobe with versions from Zeranoe’s nightly, and created a copy of the MKV Normal profile that uses h264\_vce as the video codec instead of x264. My source is 30 minute TV shows from HDHomeRun Prime, which convert just fine in software. I made no other changes to the copy of MKV Normal profile other than specifying a different encoder to ffmpeg. Every other s…

---

<div class="post-metadata">

### Author: ![Goose](https://discussion.mcebuddy2x.com/letter_avatar_proxy/v4/letter/g/5f9b8f/32.png) [@Goose](https://discussion.mcebuddy2x.com/u/Goose)
#### Post date: [September 27, 2019, 10:31pm UTC](https://discussion.mcebuddy2x.com/t/ffmpeg-4-0-w-radeon-hw-encoder/1710/6 "2019-09-27T22:31:26Z")

</div>

> [@MCEBuddy and FFMPEG-AMD: Broken File, Huge Logs](https://discussion.mcebuddy2x.com/t/mcebuddy-and-ffmpeg-amd-broken-file-huge-logs/1809/9):
>
> If you have an AMD card, try today’s 2.5.1 BETA build, it now support automatic detection of NVidia (CUDA/NvEnc), Intel (QuickSync) and AMD (AMF/VCE) hardware and enables the hardware acceleration automatically.
