Coder Social home page Coder Social logo

Comments (8)

nyanmisaka avatar nyanmisaka commented on May 27, 2024 1

@daoan1412

I did find an issue regarding the high latency. Please try this patch and see if it helps.

from ffmpeg-rockchip.

hbiyik avatar hbiyik commented on May 27, 2024

I would suggest not to use ffplay at all, since it does not suppport the drm prime frames.

from ffmpeg-rockchip.

nyanmisaka avatar nyanmisaka commented on May 27, 2024

@daoan1412
FFmpeg does not recommend using ffplay to test latency too.
https://trac.ffmpeg.org/wiki/StreamingGuide#Testinglatency

By default, ffplay (as a receiver for testing latency) introduces significant latency of its own, so if you use it for testing (see troubleshooting section) it may not reflect latency accurately.

So I doubt such a high latency is caused by ffplay/SDL itself and the internal software frame copies.

And the autovideosink in Rockchip gstreamer contains many hacks/optimizations specific to libmali driver. VOP2/GPU can directly access the DRM frames decoded by the MPP decoder through DMA, thus avoiding extra copies and latencies.

from ffmpeg-rockchip.

hbiyik avatar hbiyik commented on May 27, 2024

definetly the frame copies, internal ffmpeg yuv copy method is quite potato.

from ffmpeg-rockchip.

daoan1412 avatar daoan1412 commented on May 27, 2024

@nyanmisaka @hbiyik
However, my tests on a Linux x64 machine with an Nvidia card, using the same commands, showed almost no latency difference between ffplay and gstreamer. This leads me to believe that the issue does not lie in buffer copying. Moreover, I also conducted tests on the rk3588 platform with an Android version, building FFmpeg from source, and displaying it on the screen, which also did not show any significant real-time delay.

from ffmpeg-rockchip.

hbiyik avatar hbiyik commented on May 27, 2024

I will put PR wiki entry about how to get hw acceleration when rendering, but currently it is a little early, soon will be ready though

from ffmpeg-rockchip.

daoan1412 avatar daoan1412 commented on May 27, 2024

hi @nyanmisaka it seems that this patch has fixed the high latency issue for ffplay. Currently, I notice only about a 500ms delay compared to gstreamer, which is acceptable for my application.

from ffmpeg-rockchip.

nyanmisaka avatar nyanmisaka commented on May 27, 2024

Closed by e753665

from ffmpeg-rockchip.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.