FFmpeg is the most popular multimedia transcoding software and is used extensively for video and audio transcoding. NVENC and NVDEC can be effectively used with FFmpeg to significantly speed up video decoding, encoding, and end-to-end transcoding.
For building a computer to do that kind of work best... ffmpeg can parallelize on the cpu, so getting a server with 4 cpu's... $50k + would be the best... mid grade a a workstation style computer having 2 cpu's... for a [home] PC choosing/building a tower with enough space to house a 2 slot video card, and choosing a cpu having the most cores at the highest frequency. I haven't followed the intel vs amd cpu topic in a while in that regard.
A PC or 2-cpu workstation will almost always have once PCIe x16 slot and enough space to accommodate a graphics card. Technically a gpgu such as an Nvidia V100, or later model, providing 5000 cuda cores and 32gb memory; for the gpgpu on a budget something nvidia in the $300-$400 range like a RTX3060 will do quite well. Getting a [rack] server having 4 cpu's can be difficult to accomodate a full size gpgpu - you'd be looking at something like a Dell R940xa type server.
Refer to https://www.videocardbenchmark.net/high_end_gpus.html to gain a sense of performance vs cost.
I can't speak for how well non nvidia and non CUDA stuff will work with ffmpeg on the gpu acceleration side, so do your homework before buying a RADEON video card it may not support h264 h265 acceleration / processing with ffmpeg.