Really weird Detelecine problems on 60 fps source file

HandBrake for Windows support
Forum rules
An Activity Log is required for support requests. Please read How-to get an activity log? for details on how and why this should be provided.
Post Reply
raspberry
Posts: 8
Joined: Fri Oct 06, 2017 10:01 pm

Really weird Detelecine problems on 60 fps source file

Post by raspberry » Wed Apr 03, 2019 4:36 pm

Description of problem or question:

I'm trying to encode a 60 fps broadcast recording (In this case, Fox, which uses 720p60). The source material, The Orville, is shot at 23.976. I've used handbrake before with detelecine, and it can handle properly reducing 60 fps to 23.976. I just enable detecine-default, and leave decomb disabled, while forcing frame rate to 23.976 (since it's a progressive source; enabling decomb didn't fix this problem anyway). However, I've been seeing a really weird detelecine problem recently, including with other shows, but The Orville gave me a prime example to show others what's happening.

I clipped out the opening segment of the episode: A live-action cold open, then the opening credits using effects. When I set the frame rate to 23.976 and set detelecine to default, the live-action cold open looks perfect. But there are weird frame issues in the opening credits. If I set detelecine to off, it's exactly the opposite: the cold open has the weird frame issues... but the opening credits look perfect. The transition happens at 1:44 in the video. It's not limited to the opening credits: The problem will typically reappear at some point later in the episode. In other episodes, it happens from the very start.

Here are Google Drive links to each file:

Encoded, Detelecine Off:

https://drive.google.com/open?id=1Hvj0H ... yekRuWi9fq

Encoded, Detelecine Default

https://drive.google.com/open?id=1PuF8- ... THIjhUwx6q

Original MPEG2 clip:

https://drive.google.com/open?id=1pSb8U ... nwJOuGJwgB

Steps to reproduce the problem (If Applicable):

- Use default Fast 1080p30 preset.
- Disable Deinterlace and Interlace Detection
- Video codec: H264. FPS: 23.976 Constant
- Test with Detelecine: Default and Detelecine: Off
- Everything else can be left default

HandBrake version (e.g., 1.0.0):

Tested on both Nightly 20190309213014-3082b59-master and 1.1.2.

Operating system and version (e.g., Ubuntu 16.04 LTS, macOS 10.13 High Sierra, Windows 10 Creators Update):

Windows 10 1803

HandBrake Activity Log ***required*** (see How-to get an activity log)

Delecine Off Log:

https://pastebin.com/iLJFDH8L

Detelecine Default Log:

https://pastebin.com/y1xHrf7Y

mduell
Veteran User
Posts: 6753
Joined: Sat Apr 21, 2007 8:54 pm

Re: Really weird Detelecine problems on 60 fps source file

Post by mduell » Wed Apr 03, 2019 6:29 pm

Are you sure the credits are 24fps, not 30 or 60? I can't download the clips at the moment, but it sounds like the classic case of mixed framerate content.

Try leaving the framerate as same as source, variable framerate, and see how the scene looks.

raspberry
Posts: 8
Joined: Fri Oct 06, 2017 10:01 pm

Re: Really weird Detelecine problems on 60 fps source file

Post by raspberry » Wed Apr 03, 2019 8:02 pm

mduell wrote:
Wed Apr 03, 2019 6:29 pm
Are you sure the credits are 24fps, not 30 or 60? I can't download the clips at the moment, but it sounds like the classic case of mixed framerate content.

Try leaving the framerate as same as source, variable framerate, and see how the scene looks.
That was my first thought, too! Maybe it's like DS9 and Voyager, which I've grudgingly accepted encoding at 30fps.

But I don't believe this is a situation of mixed frame rate. Otherwise the credits wouldn't be silky-smooth at 23.976 when I turn off Detelecine. The credits look great with no dropped frames.

For the cold open, it's a clear 3:2 pulldown, as the cadence is AAABB. When I get to the opening credits, the cadence is also AAABB. There is one exception: The TV-14-LV fades at full 60fps; however, it doesn't seem to cause an issue with handbrake at the point where that happens.

Also, I've seen this problem in Handbrake on other shows that have no effects, and are just film. "The Orville" was just a rare example where I could reproduce it perfectly to submit a handbrake request. I could provide other examples later if it would help.

Semi-related: For me, variable frame-rate is a no-go; it causes issues with refresh-rate adjustment on various devices, including the Roku. I actively avoid VFR and just match the source rate when possible, even when forced into using 30fps like with Voyager. I know variable refresh rates should be coming to TV's in the future but right now I've run into repeated problems.

raspberry
Posts: 8
Joined: Fri Oct 06, 2017 10:01 pm

Re: Really weird Detelecine problems on 60 fps source file

Post by raspberry » Sat Apr 13, 2019 10:29 pm

Just bumping this. I've got all the source files and the logs above. Anyone else able to confirm Handbrake's behavior here? And is that the expected behavior?
Last edited by raspberry on Sun Apr 14, 2019 7:14 pm, edited 1 time in total.

User avatar
JohnAStebbins
HandBrake Team
Posts: 5485
Joined: Sat Feb 09, 2008 7:21 pm

Re: Really weird Detelecine problems on 60 fps source file

Post by JohnAStebbins » Sun Apr 14, 2019 4:02 pm

The detelecine filter is for interlaced content. It will do nothing helpful with progressive content. Your source uses frame duplication, not classic telecine to increase framerate.

The problem you are seeing is because the opening scene is 24 fps and the credits are 23.976 fps. There is no CFR framerate you can choose aside from the sources original 60 fps that is going to make both parts of the video smooth.

FYI, HandBrake has a "VFR" filter that is always enabled. When the selected output framerate is variable, this filter just makes sure the video is continuous, i.e. no gaps between frames. When the selected output framerate is constant or peak, the filter drops and duplicates frames as needed to achieve the requested output framerate. It has a smart frame drop algorithm. It keeps a queue of frames and ranks each frame in the queue according to how much motion there was between it and the previous frame. When a frame needs to be dropped, it drops the frame with the least motion. So this filter is all that is necessary when processing a source that uses frame duplication to increase framerate. You just happen to have one of those sources that nothing can really be done for aside from keeping the original framerate.

User avatar
JohnAStebbins
HandBrake Team
Posts: 5485
Joined: Sat Feb 09, 2008 7:21 pm

Re: Really weird Detelecine problems on 60 fps source file

Post by JohnAStebbins » Sun Apr 14, 2019 6:48 pm

I've done more analysis of the video. It's difficult to measure the exact durations between non-duplicate frames, but I think there's actually a bug to be fixed here. I'm seeing some frames being dropped that shouldn't be. I'll get back with more when I understand what's happening better.

User avatar
JohnAStebbins
HandBrake Team
Posts: 5485
Joined: Sat Feb 09, 2008 7:21 pm

Re: Really weird Detelecine problems on 60 fps source file

Post by JohnAStebbins » Sun Apr 14, 2019 11:44 pm

Ok. This should be fixed in the next nightly build.
https://github.com/HandBrake/HandBrake/ ... 9e2bc84bdb

You don't need the detelecine filter. Just set the output framerate and CFR.

raspberry
Posts: 8
Joined: Fri Oct 06, 2017 10:01 pm

Re: Really weird Detelecine problems on 60 fps source file

Post by raspberry » Sun Apr 14, 2019 11:48 pm

JohnAStebbins wrote:
Sun Apr 14, 2019 11:44 pm
Ok. This should be fixed in the next nightly build.
https://github.com/HandBrake/HandBrake/ ... 9e2bc84bdb

You don't need the detelecine filter. Just set the output framerate and CFR.
Wow, thank you! I honestly hadn't realized that detelecine was only intended for interlaced content. I'd successfully used it previously on 60fps content and it had worked fairly well.

I'll test out the build when it goes live. Thanks again.

Post Reply