Resize window coredump mpv NVScaler: src/shaders/sampling.c:924: fill_ortho_lut: Assertion `w0 + w1 >= 0.0f' failed.
Open
Nobody has claimed this yet.
down-upstream:libplacebo
os:linux
- Dominant language
- C
- Stars
- 37k
- Forks
- 3.5k
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 22
Description
mpv Information
mpv v0.40.0 Copyright © 2000-2025 mpv/MPlayer/mplayer2 projects
libplacebo version: v7.349.0
FFmpeg version: 7.1.1-1+b1
FFmpeg library versions:
libavcodec 61.19.101
libavdevice 61.3.100
libavfilter 10.4.100
libavformat 61.7.100
libavutil 59.39.100
libswresample 5.3.100
libswscale 8.3.100
Other Information
- Linux version: Debian GNU/Linux 13 (trixie)
- Kernel Version: Linux debian 6.12.38+deb13-amd64
- GPU Model: AMD
- Mesa/GPU Driver Version: 25.0.7-2
- Window Manager and Version: sway 1.10.1-2
- Source of mpv: debian trixie repo
- Latest known working version:
- Issue started after the following happened: play av1.mkv file and resize window multiple times to trigger the crash.
Reproduction Steps
- open terminal
- mpv av1.mkv (AV1 DV 10bit video)
- activate NVScaler.glsl https://gist.github.com/agyild/7e8951915b2bf24526a9343d951db214
- hold sway mod key and resize the mpv window multiple!! times from right to left with mouse
- coredump: mpv: src/shaders/sampling.c:924: fill_ortho_lut: Assertion `w0 + w1 >= 0.0f' failed.
Expected Behavior
no crash
Actual Behavior
src/shaders/sampling.c:924: fill_ortho_lut: Assertion `w0 + w1 >= 0.0f' failed.
Log File
(gdb) bt
#0 __pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0) at ./nptl/pthread_kill.c:44
#1 0x000076f5248ed9ff in __pthread_kill_internal (threadid=<optimized out>, signo=6) at ./nptl/pthread_kill.c:89
#2 0x000076f524898cc2 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#3 0x000076f5248814ac in __GI_abort () at ./stdlib/abort.c:73
#4 0x000076f524881420 in __assert_fail_base (fmt=<optimized out>, assertion=<optimized out>, file=<optimized out>, line=924,
function=<optimized out>) at ./assert/assert.c:118
#5 0x000076f5248916dc in __assert_fail (assertion=<optimized out>, file=<optimized out>, line=<optimized out>, function=<optimized out>)
at ./assert/assert.c:127
#6 0x000076f5256a7148 in fill_ortho_lut (data=<optimized out>, params=<optimized out>) at src/shaders/sampling.c:924
#7 0x000076f5256a55d3 in sh_lut (sh=sh@entry=0x76f4dc4916b0, params=params@entry=0x76f5037f8390) at src/shaders/lut.c:485
#8 0x000076f5256aab53 in pl_shader_sample_ortho2 (sh=0x76f4dc4916b0, src=src@entry=0x76f5037f8520, params=params@entry=0x76f5037f85e0)
at src/shaders/sampling.c:1024
#9 0x000076f52567fb2a in dispatch_sampler (pass=pass@entry=0x76f5037f8d30, sh=0x76f4dc492080, sampler=sampler@entry=0x76f4dc4a76e8,
usage=usage@entry=SAMPLER_CONTRAST, target_tex=target_tex@entry=0x76f4dd920150, src=src@entry=0x76f5037f8850) at src/renderer.c:749
#10 0x000076f5256827f9 in get_feature_map (pass=0x76f5037f8d30) at src/renderer.c:2077
#11 pass_convert_colors (pass=pass@entry=0x76f5037f8d30) at src/renderer.c:2195
#12 0x000076f525688f78 in pl_render_image (rr=rr@entry=0x76f4dc4a7640, pimage=pimage@entry=0x76f4dc745c30,
ptarget=ptarget@entry=0x76f5037fcbd0, params=params@entry=0x76f5037fcab0) at src/renderer.c:3152
#13 0x000076f52568a224 in pl_render_image_mix (rr=<optimized out>, images=images@entry=0x76f5037fc740,
ptarget=ptarget@entry=0x76f5037fcbd0, params=params@entry=0x76f5037fcab0) at src/renderer.c:3688
#14 0x000062eb2fc2562f in draw_frame (vo=0x62eb40b61b30, frame=<optimized out>) at ../video/out/vo_gpu_next.c:1135
#15 0x000062eb2fc13e31 in render_frame (vo=0x62eb40b61b30) at ../video/out/vo.c:1010
mpv --gpu-debug --log-file=output.txt av1.mkv
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 the crash with mpv av1.mkv, NVScaler.glsl, and repeated sway window resizing. Start at libplacebo's src/shaders/sampling.c:924, then trace the callers in src/shaders/lut.c:485 and src/shaders/renderer.c:749; mpv enters through video/out/vo_gpu_next.c:1135. Done means the reported resize sequence no longer aborts at fill_ortho_lut.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100