Encode and Decode frames by libVLC (C#)

Viewed 175

I am new to VLC or libVLC. I am using C# (.Net Framework 4.8) and targeting to encode and decode video frames (each frame in form of Bitmap or byte array of Bitmap) as byte arrays in H.264 video streams, i.e., each frame being encoded as a byte array and then decoded. It is difficult to find any sample code for these simple functions.

I used OpenH264 and OpenH264Lib to perform similar functions. It works but seems the performance is unsatisfactory.

Can anyone help me? Thanks a lot!

1 Answers

LibVLC(sharp) is not the right tool for the right job. LibVLCSharp is good at playing videos, but enconding/decoding raw frames will likely be hard to do.

The ffmpeg libraries (libavcodec, libavformat...) are more suited for this. Please have a look at FFMpeg.Autogen

Related