Hi!
I modified the CMPlayer:
eek function to compensate for cutpoints.
So far this was working fine, but I've run into strange mplayer seek behaviour.
Normally, a seek step is 30 seconds, but to jump over a cutpoint, I dynamically increase it. Next CMPlayer::SeekRelativeTime is called with the changed number.
I noticed that sometimes MPlayer seeks with the 'standard' 30 seconds, and not with the number I called SeekRelativeTime with!
I added some debugging to show that the code is correct, only MPlayer doesn't execute the correct seek:
Code:
00:31:12 M: 30973952 DEBUG: Mplayer: SeekRelativeTime:300, command:seek +300 0
00:31:13 M: 30990336 DEBUG: CApplication::OnKey: 166 pressed, action is 22
00:31:13 M: 31039488 DEBUG: CEdl: Compensateseek, curtime:2794.00, old:300 new:300
00:31:13 M: 31039488 DEBUG: Mplayer: SeekRelativeTime:300, command:seek +300 0
00:31:15 M: 30998528 DEBUG: CApplication::OnKey: 168 pressed, action is 20
00:31:15 M: 30994432 DEBUG: CEdl: Compensateseek, curtime:3097.00, old:30 new:455 CORRECTED
00:31:15 M: 30994432 DEBUG: Mplayer: SeekRelativeTime:455, command:seek +455 0
00:31:16 M: 30969856 DEBUG: CApplication::OnKey: 168 pressed, action is 20
00:31:16 M: 30969856 DEBUG: CEdl: Compensateseek, curtime:3553.00, old:30 new:30
00:31:16 M: 30969856 DEBUG: Mplayer: SeekRelativeTime:30, command:seek +30 0
00:31:18 M: 30965760 DEBUG: CApplication::OnKey: 168 pressed, action is 20
00:31:18 M: 31039488 DEBUG: CEdl: Compensateseek, curtime:3585.00, old:30 new:30
00:31:18 M: 31039488 DEBUG: Mplayer: SeekRelativeTime:30, command:seek +30 0
00:31:19 M: 30986240 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:19 M: 30986240 DEBUG: CEdl: Compensateseek, curtime:3617.00, old:-30 new:-30
00:31:19 M: 30986240 DEBUG: Mplayer: SeekRelativeTime:-30, command:seek -30 0
00:31:19 M: 30949376 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:19 M: 30949376 DEBUG: CEdl: Compensateseek, curtime:3588.00, old:-30 new:-30
00:31:19 M: 30949376 DEBUG: Mplayer: SeekRelativeTime:-30, command:seek -30 0
00:31:21 M: 30842880 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:21 M: 30842880 DEBUG: CEdl: Compensateseek, curtime:3559.00, old:-30 new:-455 CORRECTED
00:31:21 M: 30842880 DEBUG: Mplayer: SeekRelativeTime:-455, command:seek -455 0
00:31:21 M: 30965760 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:21 M: 31014912 DEBUG: CEdl: Compensateseek, curtime:3531.00, old:-30 new:-455 CORRECTED
00:31:21 M: 31014912 DEBUG: Mplayer: SeekRelativeTime:-455, command:seek -455 0
00:31:22 M: 31035392 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:22 M: 31035392 DEBUG: CEdl: Compensateseek, curtime:3503.00, old:-30 new:-455 CORRECTED
00:31:22 M: 31035392 DEBUG: Mplayer: SeekRelativeTime:-455, command:seek -455 0
00:31:23 M: 30978048 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:23 M: 31047680 DEBUG: CEdl: Compensateseek, curtime:3476.00, old:-30 new:-455 CORRECTED
00:31:23 M: 31047680 DEBUG: Mplayer: SeekRelativeTime:-455, command:seek -455 0
00:31:24 M: 31010816 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:24 M: 31043584 DEBUG: CEdl: Compensateseek, curtime:3446.00, old:-30 new:-455 CORRECTED
00:31:24 M: 31043584 DEBUG: Mplayer: SeekRelativeTime:-455, command:seek -455 0
00:31:25 M: 31023104 DEBUG: CApplication::OnKey: 169 pressed, action is 21
00:31:25 M: 31023104 DEBUG: CEdl: Compensateseek, curtime:3419.00, old:-30 new:-455 CORRECTED
00:31:25 M: 31023104 DEBUG: Mplayer: SeekRelativeTime:-455, command:seek -455 0
Several times, the command 'seek -455' is sent to mplayer, but a seek of -30 is executed.
Any idea what might be wrong, and how to fix this?