chromeos / cros-codecs

BSD 3-Clause "New" or "Revised" License
30 stars 11 forks source link

More HEVC support #29

Closed dwlsalmeida closed 1 year ago

dwlsalmeida commented 1 year ago

This commit improves on the HEVC support already merged. It also adds a VAAPI backend.

This is still work in progress. Some (very few) fluster tests pass, but the decoder hangs or crashes for most of the other tests. Further improvements will come in the future.

In particular, the H265 frame iterator can be refactored to exploit the similarities with the H.264 one, but that again is left for a future PR.

dwlsalmeida commented 1 year ago

Depends on https://github.com/chromeos/cros-libva/pull/2

dwlsalmeida commented 1 year ago

@Gnurou Alex can you rebase this?

I was in the process of doing it, but there's conflicts for VP8 and VP9 vaapi code, because for some reason the functions to build the VA buffers were moved out of the impl VaapiBackend block. Note that this is not the case for h.264 currently and was not the case at all for the commit I based this PR on.

As there's different implementations (VP8, VP9 using free functions vs H264 using the VaapiBackend impl block) I think it's best if you decide how you want to move forward here.

Other than that, it's just about merging the extra generic parameter introduced for VaapiBackend. We need that to stash H.265-specific data that is used across calls.

Gnurou commented 1 year ago

Thanks! Rebased and merged, confirmed all tests were still passing.