FFMS / ffms2

An FFmpeg based source library and Avisynth/VapourSynth plugin for easy frame accurate access
Other
582 stars 105 forks source link

vapoursource: Set Dolby Vision RPU data in frame props #397

Closed quietvoid closed 2 years ago

quietvoid commented 2 years ago

Normally as the RPU added in https://github.com/FFMS/ffms2/pull/396 is guarded, this has no downside. Tested with some WIP code here: https://github.com/quietvoid/vs-placebo/blob/6bed053c32f132e477e20bd074199a31465b7c51/tonemap.c#L223

It works fine for me.

I've tested with setting an int prop to the pointer, but it does not work consistently. Or maybe I didn't cast things properly.

dwbuiten commented 2 years ago

@quietvoid is it worth waiting for http://ffmpeg.org/pipermail/ffmpeg-devel/2021-December/289160.html ?

That is, is it useful to expose both the buffer and metadata in VapourSynth? We can do both, I just want to be sure they're both useful in a typical VapourSynth usecase.

quietvoid commented 2 years ago

I don't think exposing the new parsed metadata structs is possible in props, at least for users in Python. For C users (who use props in VapourSynth plugins), it would also require a libavcodec dependency, which might be undesirable.

So I think the RPU buffer only is probably the best idea for now.

dwbuiten commented 2 years ago

Makes sense.