You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to evaluate an arm64 cpu's decoder and render performance by counting the framedrop when playing different kind of encoding video, such as h264, h265, av1, vp9.
I have been tried the following lua script but failed.
local log_file_path = "./mpv.log" -- Update this path
local function log_stats()
local time_pos = mp.get_property_number("time-pos", 0)
local decoder_frame_drop_count = mp.get_property_number("decoder-frame-drop-count", 0)
local renderer_frame_drop_count = mp.get_property_number("frame-drop-count", 0)
local log_entry = string.format("Time: %.2fs, Decoder Drops: %d, Renderer Drops: %d\n",
time_pos, decoder_frame_drop_count, renderer_frame_drop_count)
local log_file = io.open(log_file_path, "a")
if log_file then
log_file:write(log_entry)
log_file:close()
else
print("Error: Unable to open log file.")
end
end
mp.add_hook("on_unload", 50, log_duration("on_unload"))
-- mp.register_event("end-file", log_duration("end-file"))
-- mp.register_event("playback-restart", log_duration("playback-restart"))
-- mp.register_event("shutdown", log_duration("shutdown"))
there are always zero value no matter end-file, shutdown, on_unload event.
acturally, I could saw frame drop value is non-zero by mpv osd info
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi, community.
I want to evaluate an arm64 cpu's decoder and render performance by counting the framedrop when playing different kind of encoding video, such as h264, h265, av1, vp9.
I have been tried the following lua script but failed.
there are always zero value no matter end-file, shutdown, on_unload event.
acturally, I could saw frame drop value is non-zero by mpv osd info
so how to fix it?
Beta Was this translation helpful? Give feedback.
All reactions