Skip to content

Instantly share code, notes, and snippets.

@sielicki
Created June 2, 2018 09:18
Show Gist options
  • Save sielicki/952b8a6bbb09320d8f519c836d747432 to your computer and use it in GitHub Desktop.
Save sielicki/952b8a6bbb09320d8f519c836d747432 to your computer and use it in GitHub Desktop.
function on_mouse_click(name, value)
local screenW, screenH = mp.get_osd_size()
local mouseX, mouseY = mp.get_mouse_pos()
local adb = "adb shell input tap %s %s &"
os.execute(string.format(adb, mouseX, mouseY))
-- mp.msg.info(string.format(adb, mouseX, mouseY))
end
mp.add_key_binding("MBTN_LEFT", "something", on_mouse_click)
@sielicki
Copy link
Author

sielicki commented Jun 2, 2018

usage

this bugs out horribly but it's workable for just a brief moment if you need to click something

usage: adb shell screenrecord --bit-rate=16m --output-format=h264 --size 1920x1080 - | mpv -

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment