Issues capturing Dosbox content

zifox

New Member
Hi everyone,

I've been using OBS for quite a while to record games (no stream), and I'm having a weird behavior when recording Dosbox content.
The issue is quite simple: OBS sometimes records twice or thrice the same frame, looking at the video it seems to be heavily lagging. But it's definitely not a performance issue, I have no dropped frames in the logs. It seems to be random, sometimes I can record 20 minutes without glitch, sometimes I can't get 5 seconds without having the problem.
I also have the feeling that I have the same behavior on screen at a lesser level. (from time to time the display lags)
The issue only happens with dosbox, if i'm recording a "native" game, I have no issue. Recording F1GP/GP2 in dosbox 640x480@30fps I have issues, recording GP4 1440p@60fps no issue.

I've talked with the people developing Dosbox, we tried many settings in dosbox to find an explanation, but we didn't. Some tweaks (changing refresh rate, for example) have an effect, but it only lessens the problem. Activating Vsync in dosbox makes things worse.
So now i'm looking for help here: is there a particular setup I should use in OBS to record DobsBox ? I've been trying GameCapture/WindowCapture, the behavior is the same. My video preset is H264 in near lossless recording.
Note: i'm recording two windows at the same time: Dosbox and a small application displaying input values. Only the content of Dosbox have issue.

I can send links to video exemples, they're on youtube.
 

zifox

New Member
I've done a long capture, here's the log. i've noticed a huge difference between frame output and draw frames. Does that mean obs didn't record all the frames needed ?

19:35:10.846: ==== Recording Start ===============================================
19:35:10.847: [ffmpeg muxer: 'adv_file_output'] Writing file '2024-08-22 19-35-10.mp4'...
19:35:11.158: [AMF] <Id: 6> Initial Frame Latency is 265423600 nanoseconds.
20:46:15.058: Pausing recording due to hotkey
20:46:15.058: output adv_file_output paused
21:10:18.294: Unpausing recording due to hotkey
21:10:18.294: output adv_file_output unpaused
21:38:19.091: Stopping recording due to hotkey
21:38:19.454: [ffmpeg muxer: 'adv_file_output'] Output of file '2024-08-22 19-35-10.mp4' stopped
21:38:19.454: Output 'adv_file_output': stopping
21:38:19.454: Output 'adv_file_output': Total frames output: 178351
21:38:19.454: Output 'adv_file_output': Total drawn frames: 221658
21:38:19.454: ==== Recording Stop ================================================
 
Top