The demo should not be limited to FreePascal and Lazarus versions. Of course, things have improved in recent years.
The problem lies in this line of code:
//
Avcodec_ Decode_ Video2 (pCodecCtx, frame, frame_finished, @ packet);
//
The phenomenon I tested is that under Windows, this line of code is very fast.
Under arm64 Linux, it is very slow, and decoding a 1080P video takes 70 milliseconds. Normally, it should not exceed 25 milliseconds. But under arm64 Linux, loading ffmpeg decoding with qt is very fast, usually around 10 milliseconds.
Should I suspect that Freepassal calling the C runtime library under arm64 Linux may cause Obvious efficiency issues?