libass uses integers for PlayResX/Y, so the osd-overlay command also does. Lua (pre-5.3) does not have an integer type, but the command interface makes a difference anyway. If you pass a Lua number with a fractional part to an integer parameter (using mp.command_native()), it will result in an error and complain about incompatible types. I think that's fine, but since this behavior extends to mp.set_osd_ass(), this is a compatibility problem. Fix this by explicitly coercing the resolution parameters to integer numbers.
Unified · Split
| @@ -612,6 +612,8 @@ function overlay_mt.update(ov) · 611 unmodified lines | ||
| 612 | 612 | cmd[k] = v |
| 613 | 613 | end |
| 614 | 614 | cmd.name = "osd-overlay" |
| 615 | + cmd.res_x = math.floor(cmd.res_x) | |
| 616 | + cmd.res_y = math.floor(cmd.res_y) | |
| 615 | 617 | mp.command_native(cmd) |
| 616 | 618 | end |
| 617 | 619 | |