FallingSnow / h265ize

A node utility utilizing ffmpeg to encode videos with the hevc codec.
MIT License
527 stars 81 forks source link

Auto-crop gives unacceptable results #146

Open lalloni opened 4 years ago

lalloni commented 4 years ago

On several videos I'm trying to convert to h265 using h265ize the autocrop detection gives very bad results (blackboard tutorial videos, autocrop takes out half+ of the content which is actually wanted) so I would want and option to remove autocroping but keeping the rest of the normalization levels enabled. From what I read in the code/docs, that is not possible because for disabling autocroping I would need to say --normalize-level 0 which takes everything out, right? I think a specific option for disable only autocroping would be useful. Additionally/alternatively a threshold option to keep autocroping within sane limits might work too: say "--max-auto-croping .2" which would mean that if autocroping tries to kill more than 20% of pixels it should be automatically disabled. Thoughts?

spoo333 commented 4 years ago

support your request!!

Kazz3r24 commented 4 years ago

Using --normalize-level 0 has worked flawlessly for me to eliminate cropping. In my experience so far, setting the normalization level just leaves the video ratio as is. I've had no issues with it yet.

lalloni commented 4 years ago

Using --normalize-level 0 has worked flawlessly for me to eliminate cropping. In my experience so far, setting the normalization level just leaves the video ratio as is. I've had no issues with it yet.

I get that. That's exactly how I solved the unwanted cropping.

What I'm asking is being able to disable auto-cropping only but keeping the rest of the stuff that comes with higher values of --normalization-level:

That's from a quick search on https://github.com/FallingSnow/h265ize/blob/master/lib/classes/video.js

spoo333 commented 4 years ago

I'm confused now as I obviously lack the knowledge :))) can I use the normalize function without losing out on other benefits? Thank you both!!

On Fri, 3 Apr 2020, 20:36 Pablo Lalloni, notifications@github.com wrote:

Using --normalize-level 0 has worked flawlessly for me to eliminate cropping. In my experience so far, setting the normalization level just leaves the video ratio as is. I've had no issues with it yet.

I get that. That's exactly how I solved.

What I'm asking is being able to disable auto-cropping only but keeping the rest of the stuff that comes with higher values of --normalization-level:

  • various audio normalization alternatives
  • video deinterlacing
  • audio stream title handling

That's from a quick search on https://github.com/FallingSnow/h265ize/blob/master/lib/classes/video.js

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/FallingSnow/h265ize/issues/146#issuecomment-608621817, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADRAUCJPLTU6DV3GHA2ZOWLRKY3DRANCNFSM4LW2P6DA .

lalloni commented 4 years ago

AFAIK you need to use --normalize-level 0 to disable auto-cropping and that disables everything else that is controlled with that flag.

spoo333 commented 4 years ago

It appears indeed that a few features are left out with --normalize-level 0. Fine for videos without subs ...