erazortt / DoViBaker

Bake the DoVi into your clip
GNU General Public License v3.0
45 stars 7 forks source link

Read instream rpu, compatible to ffms2 #16

Closed erazortt closed 12 months ago

erazortt commented 12 months ago

Add compatibility to directly read the RPU from the stream, for streams load by ffms2. This is a new ffms2 feature that is currently being developed

With this neither the EL nor the RPU need to be extracted anymore!

Thus instead of: bl=DGSource("blclip.dgi") el=DGSource("elclip.dgi") DoViBaker(bl,el,rpu="RPU.bin")

This can now be used: bl=FFVideoSource("clip.ts", threads=1) el=FFVideoSource("clip.ts", threads=1, track=1) DoViBaker(bl,el)

This however is bought by a decoding speed of about half compared to using DGSource!

Asd-g commented 12 months ago

This however is bought by a decoding speed of about half compared to using DGSource!

LSMASHSource also supports DolbyVisionRPU frame property. You can try LWLibavVideoSource(..., prefer_hw=x) for hardware decoding.

erazortt commented 12 months ago

So apparently prefer_hw=1 disables the reading of RPU data. I opened an issue. It might be impossible due to the hw nature of the reading though...

rome1983 commented 12 months ago

MKV files supported using this method?

erazortt commented 12 months ago

I don't have any such files now at hand, but I'm quite positive it should work. Please feel free to try it out, and if it does not work directly "out-of-the-box" than please open an issue, I would then investigate.

rome1983 commented 12 months ago

loaded this config without errors

bl=FFVideoSource("F:\Me\Me.mkv") el=FFVideoSource("F:\Me\Me.mkv") SetFilterMTMode("DoViBaker",2) DoViBaker(bl,el) Prefetch(8)

rome1983 commented 11 months ago

Colors are wrong with mkv files but looks good with ts files.