Skip to content
Snippets Groups Projects

mf: Fix some issues with seeking.

Open Conor McCarthy requested to merge cmccarthy/wine:unpause_seek into master
1 unresolved thread

This fixes failure to play the prologue video in Planet of the Apes: Last Frontier, which unpauses by calling Start() with a location. The exact state leading to this issue does not occur in the Start() tests, and it's not clear how to reproduce it reliably.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • **** requested review from @nsivov

    requested review from @nsivov

  • Conor McCarthy added 4 commits

    added 4 commits

    • 75a4ec80 - mf: Drop transform node input events when unpausing at a specific position.
    • 66f19c21 - mf: Reset transform node outputs when seeking.
    • 623fa553 - mf: Initialise the grabber sample count when setting state after a seek.
    • cc6970b7 - mf: Reset transform nodes when seeking.

    Compare with previous version

  • Added a call to IMFTransform_ProcessMessage() with MFT_MESSAGE_COMMAND_FLUSH. Not 100% sure the location is correct.

    • We have session_flush_nodes() that flushes transforms and sinks, and it's called on SESSION_STATE_RESTARTING_SOURCES. These changes look to scattered to me to make sense, but it should also be possible to test manually in which order things happen, e.g. when, or if, we should flush relative to source restart for example.

    • I tested in Windows by swapping the vtbl in a sample copier transform, and in the media source. Windows sends MFT_MESSAGE_COMMAND_FLUSH after a seeking unpause (before calling Start() on the source), but not after unpause at the current position, which is in line with our expectations. Wine sends MFT_MESSAGE_NOTIFY_START_OF_STREAM after every start, but Windows only sends it once, before calling Start(). That would be a separate MR though. Windows also sends MFT_MESSAGE_NOTIFY_BEGIN_STREAMING, which is not necessary according to spec, but we might do that too in case something depends on it.

      I changed this MR to use session_flush_nodes() when unpausing with a seek. Flush messaging now matches that in Windows.

    • Please register or sign in to reply
  • Conor McCarthy added 4 commits

    added 4 commits

    • 55b57679 - mf: Drop transform node input events when unpausing at a specific position.
    • b5805f9b - mf: Reset transform node outputs when seeking.
    • f991daf7 - mf: Initialise the grabber sample count when setting state after a seek.
    • f20080a3 - mf: Reset transform nodes when seeking.

    Compare with previous version

  • Conor McCarthy added 4 commits

    added 4 commits

    • f1cd6c00 - mf: Drop transform node input events when unpausing at a specific position.
    • b57a1c80 - mf: Reset transform node outputs when seeking.
    • da63b26f - mf: Initialise the grabber sample count when setting state after a seek.
    • 831be356 - mf: Reset transform nodes when seeking.

    Compare with previous version

  • Conor McCarthy added 6 commits

    added 6 commits

    • e3c92585 - mf: Reset transforms before restarting a paused source instead of after.
    • 3000d8f0 - mf: Drop transform node input events when unpausing at a specific position.
    • b2be976e - mf: Flush nodes before restarting a paused source at a specific position.
    • f0e6329e - mf: Reset transform node outputs when seeking.
    • d7e9650f - mf: Initialise the grabber sample count when setting state after a seek.
    • 6375f1c8 - mf: Reset transform nodes when seeking.

    Compare with previous version

Please register or sign in to reply
Loading