~guidocella/mpv-image-config

4475e53b495ec6128c6d7ea7d933dbdce9925edf — Guido Cella 1 year, 3 months ago ad434e4
simplify condition
1 files changed, 3 insertions(+), 1 deletions(-)

M scripts/align-images.lua
M scripts/align-images.lua => scripts/align-images.lua +3 -1
@@ 9,7 9,9 @@ require 'mp.options'.read_options(options, nil, function () end)
-- Align images bigger than the window to the top right corner.
local dont_center
mp.observe_property('video-out-params', 'native', function (_, params)
    if not params or not mp.get_property_native('current-tracks/video/image') then return end
    if not mp.get_property_native('current-tracks/video/image') then
        return
    end

    local dims = mp.get_property_native('osd-dimensions')
    -- osd-width and osd-height, and even display-width and display-height, can be unavailable when the first image loads.