mpv attempts to parse language tags from video filename for the external track file with the same name
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 37k
- Forks
- 3.5k
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 22
Description
mpv Information
mpv v0.39.0-1016-g4c26e7d2e Copyright © 2000-2025 mpv/MPlayer/mplayer2 projects
built on Mar 10 2025 17:10:23
libplacebo version: v7.350.0 (v7.349.0-47-gd9ec2b4-dirty)
FFmpeg version: N-118728-g04d7a6d3d
FFmpeg library versions:
libavcodec 61.33.102
libavdevice 61.4.100
libavfilter 10.9.100
libavformat 61.9.107
libavutil 59.59.100
libswresample 5.4.100
libswscale 8.13.101
Other Information
- Windows version: Win11 24H2
- GPU model, driver and version:
- Source of mpv: git master
- Latest known working version: n/a
- Issue started after the following happened: n/a
Reproduction Steps
Try using mpv --no-config --log-file=mpv.log to play a video with the same name external track file and view external track information.
Expected Behavior
External track files with the same name as the video file name should not show any available language tags
Actual Behavior
mpv attempts to parse language tags from video filename for the external track file with the same name
[ 4.138][v][cplayer] Opening done: G:\TV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Complete.WEB-DL.1080p.H264.AAC-CMCTV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Ep01.WEB-DL.1080p.H264.AAC-CMCTV.mp4
[ 4.138][v][find_files] Loading external files in G:\TV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Complete.WEB-DL.1080p.H264.AAC-CMCTV\
[ 4.138][v][ifo_dvdnav] Opening G:\TV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Complete.WEB-DL.1080p.H264.AAC-CMCTV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Ep01.WEB-DL.1080p.H264.AAC-CMCTV.ass
[ 4.138][v][bdmv/bluray] Opening G:\TV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Complete.WEB-DL.1080p.H264.AAC-CMCTV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Ep01.WEB-DL.1080p.H264.AAC-CMCTV.ass
[ 4.138][v][file] Opening G:\TV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Complete.WEB-DL.1080p.H264.AAC-CMCTV\[神探狄仁杰Ⅰ].Detective.Dee.2004.S01.Ep01.WEB-DL.1080p.H264.AAC-CMCTV.ass
...
[ 4.150][i][cplayer] ● Video --vid=1 (h264 1920x1080 25 fps) [default]
[ 4.150][i][cplayer] ● Audio --aid=1 (aac 2ch 44100 Hz 152 kbps) [default]
[ 4.150][i][cplayer] ● Subs --sid=1 --slang=AAC-CMCTV 'ass' (ass) [external]
Log File
Sample Files
No response
I carefully read all instruction and confirm that I did the following:
- I tested with the latest mpv version to validate that the issue is not already fixed.
- I provided all required information including system and mpv version.
- I produced the log file with the exact same set of files, parameters, and conditions used in "Reproduction Steps", with the addition of
--log-file=output.txt. - I produced the log file while the behaviors described in "Actual Behavior" were actively observed.
- I attached the full, untruncated log file.
- I attached the backtrace in the case of a crash.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce with mpv --no-config --log-file=mpv.log using a video and same-name .ass file, then inspect the find_files external-track loading path shown in the log. Verify how the video filename is used when assigning the external track language tag. Done means the same-name external track no longer receives a language tag parsed from the video filename.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- audio-video-rtc, cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100