…to get to the first properly working stream. Setting up a robust streaming setup turned out to be more of a journey than I initially anticipated. But after some of trial and error, I finally achieved a configuration that lets me stream at 1080p 50fps while simultaneously recording high-quality video using hardware H.265 encoding. And all of this on a modest Ryzen 5 3400G CPU with its Vega 11 GPU.
The Challenges and Iterations
The first four attempts were plagued by misconfigurations, from encoding issues to syncing problems. The Ryzen 5 3400G is a capable APU, but definitely can’t be used “as is” for a good streaming setup. Here’s the laundry list of issues I faced:
- Finding the Right Encoder Balance: I started with hardware encoding for both streaming and recording, but AMD’s h264 implementation is a bad joke. Then switched to CPU encoding which was okay for the stream, but way too crappy for YouTube. It was clear that my PC is not strong enough to encode twice at different bitrates using the CPU. The solution? Leverage the Vega 11 GPU for H.265 hardware encoding for the background recording while reserving x264 CPU encoding for the stream. This setup struck the perfect balance, using both CPU and GPU. Interestingly the HEVC encoder of AMD does a more than adequate job, I purposefully used a fast moving shooter game, and it looks crisp and artefact-free at 15Mbps. Thanks to the low TDP profile of the chip things are both stable and silent.
- Choosing 50fps over 60fps: While most streams aim for the gold standard of 60fps, I discovered that 50fps produces far fewer x264 artifacts while still maintaining smooth visuals. The difference in smoothness was barely noticeable, but the improvement in encoding stability made it a no-brainer. This somehow enabled me to use the fastest encoder setting (ultrafast) but still see less blotching than with fast @ 60fps.
- Adjusting Brightness with Filters: One unexpected issue was the default luminosity of the Elgato 4K capture card. Adding a gamma filter to the stream solved it without making it washed out.
- Audio Sync Issues: My original plan was to reuse the stream’s audio for the recorded video to ease the load on the CPU. However, this caused lag and syncing issues, with the audio drifting out of sync with the recorded video. Eventually, I settled on encoding the audio twice – once for the stream and once the recording -, sacrificing a bit of CPU load to ensure quality.
- Audio Mixing & Volume Settings: VoiceMeeter to the rescue! It was not too easy to setup the right audio mix and have a feedback channel – that is, hear yourself back on the mic while also forwarding it to the streaming PC. It took some getting used to hearing back my own voice with a slight latency, but it helps me set the right volume mix.
- Not Compromising on Webcam: I started off with a HP 950 4K which is a decent little camera, but it has two major flaws: autoexposure is terribly unreliable and whenever it overexposes (which it does often & randomly) it will mess up the green screen chroma filter – plus the video looks super amateur. The other is a firmware / software bug: if you switch to manual exposure you’re severly underexposed even at max and get down to probably 10 fps. Comically bad. At the end I tossed them aside (unfortunately I had two) and got myself Logitech BRIOs, the original 4K version. The white balance is off, skin tones are so-so at best, but autoexposure is consistent and steady and autofocus is more reliable than any webcam I’ve ever used.
The Result
After five iterations of trial and error, I now have a stable setup that ticks all the boxes. Streaming at 1080p 50fps provides great visual quality with minimal artifacts, and the parallel hardware H.265 recording ensures a high-quality “master” without taxing the system. If and when I want to upload to YouTube I’ll have the HEVC file that’s much better than the real time stream. Thanks to the ultrafast CPU setting I have ample CPU headroom if I want to use my streaming PC for stream-related tasks like Google searching or working with my talking points in Google Docs.
Well, the 3400G APU is not a beast by any stretch, and at some point I was afraid it might not handle >30fps. After four attempts for which recording goes down the tube, I might have a working configuration. On to scenes and multiple webcams now!