Free and open-source lib to decode x.265 (HEVC) stream in a C project?

1.4k Views Asked by At

I'm doing a project in C which requires playing an incoming stream of HEVC content to the user. My understanding is that I need a library that gives me an API to a HEVC decoder (not and encoder, but a decoder). Here are my options so far:

  • The x265 looks perfect but it's all about the encoding part (and nothing about decoding it !). I'm not interested in an API to a HEVC encoder, what I want is the decoder part.
  • There is libde265 and OpenHEVC but I'm not sure they have what I want. Couldn't find it anywhere in their docs that there is an API that I can use to decode the content but since there are players out there using those libs, I'm assuming it must be there somewhere ... couldn't find it though !
  • There is ffmpeg project with its own decoders (HEVC included) but I'm not sure this is the right thing since I only want the hevc decoder and nothing else.

Cheers

1

There are 1 best solutions below

0
On

Just go with FFmpeg, I'm guessing you'll only need to link with libavcodec library and it's API/Interfaces. And yes, the machine where your code work will have the whole FFmpeg installed (or maybe not, just the library might work).
Anyway, even that shouldn't be any problem unless the machine is an embedded system with tight space constraints (which is unlikely since it's h265, which implies abundant of source needed).