Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get away from v4l2 stuff, and switch to ffmpeg nvv4l2 tegra stuff...... #13

Open
GavinDarkglider opened this issue Mar 1, 2022 · 0 comments

Comments

@GavinDarkglider
Copy link

GavinDarkglider commented Mar 1, 2022

Roadmap or todo item

Detailed Description
Basically nix the tegra decoder code in kodi for the most part, and use the pretty much perfect ffmpeg decoder switchroot developer CTCaer has been working on, which increases decoder performance at 1080p by 70%. Currently in moonlight we are getting a 2-4 milisecond lag, and that is on a network stream at 1080p.

Context

In general, it is better to fix minor issues, than implement a huge code change to add a feature that has pretty much been perfected somewhere else, and has been tested.

Possible Implementation

Use the patches from this ffmpeg, and it will force proper decoders in kodi.
https://gitlab.com/switchroot/switch-l4t-multimedia/FFmpeg
This still needs some sort of timestamp fix in kodi to fix issues with hle streams with where video is split.
It should be noted here that all patchsets are designed to force tegra decoders, so do not merge this in upstream kodi ffmpeg, or it will break things.

This is easy to revert, you just need to reorder the codecs below software versions.
and remove some hacks in ffmpeg/ffplay stuff.

Here is a libreelec build, using this implementation for the Switch. I dont have any jetson boards currently, so this is what I have available. https://nightly.builds.lakka.tv/members/gavin/70_percent_faster_decoder_encoder/LibreELEC-Switch.aarch64-10.0-devel-20220301001124-ac865eb.tar

Additional context, screenshots or links

Here are some relevant links or screenshots

Here is the bug report I made in kodi upstream using these patches. xbmc#21022
Here are the patches for kodi matrix ffmpeg 4.3.2 version. https://github.com/GavinDarkglider/Lakka-LibreELEC/tree/Final_decoder_encoder/packages/multimedia/ffmpeg/patches/L4T

I need to squash them into 1 patch file at some point, but this is still in development.

Note: Team Kodi is considering this item, but we are not making any promises if and when it will be included.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant