Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

PotSync

Synchronize PotPlayer playback progress across multiple machines using UDP.

image

Features

  • Live progress view for local and remote peers
  • Optional sync of seek and play/pause state via unified event messages
  • Simple UDP broadcast to multiple peers

Requirements

  • Windows (uses Win32 window APIs)
  • Python 3.9+
  • PotPlayer running
  • rich for --watch / --sync UI

Install

pip install rich

Usage

python potsync.py --listen 0.0.0.0:5000 --peers 192.168.1.10:5000 --sync

Options:

  • --title: Window title substring to match (default: PotPlayer)
  • --listen / --in: UDP listen address list (repeatable or comma-separated)
  • --peers / --peer / --out: Peer targets (repeatable or comma-separated)
  • --watch: Show progress only (no sync receive)
  • --sync: Show progress and apply received event updates
  • --interval: UI refresh interval seconds (default 0.25)
  • --seek-min-delta-ms: Minimum delta to treat as a seek (default 1000)
  • --event-recv-suppress-ms: Suppress local event detection after receiving an event

Examples

Watch only, no syncing:

python potsync.py --listen 0.0.0.0:5000 --peers 192.168.1.10:5000 --watch

Two-way sync between two machines:

# Machine A
python potsync.py --listen 0.0.0.0:5000 --peers 192.168.1.11:5000 --sync

# Machine B
python potsync.py --listen 0.0.0.0:5000 --peers 192.168.1.10:5000 --sync

Protocol (UDP JSON)

  • Progress updates:
    • {"type":"progress","cur":12345,"total":67890,"state":2}
  • Event updates (seek/state):
    • {"type":"event","cur":12345,"total":67890,"state":1}

state values:

  • 2 = Playing
  • 1 = Paused
  • -1 = Stopped

Notes

  • The tool matches the first visible window whose title contains --title.
  • Ports must be reachable over the network (firewall allowed).

Acknowledgement

About

PotPlayer online sync 在线同步观影|一起看

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages