Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Send Cursor position to a Browser Source #1177

Open
UUoocl opened this issue Aug 18, 2024 · 0 comments
Open

Send Cursor position to a Browser Source #1177

UUoocl opened this issue Aug 18, 2024 · 0 comments

Comments

@UUoocl
Copy link

UUoocl commented Aug 18, 2024

Is your feature request related to a problem? Please describe.
I'm working on a project to create an animated cursor overlay written in JavaScript that works even when the browser is not in interactive mode. I've created a javascript to animate the cursor and an Advance Scene Switcher Macro to capture the Cursor position.

The problem this Feature Request solves is sending the cursor location to a browser source from Advanced Scene Switcher.

Describe the solution you'd like
A clear and concise description of what you want to happen.

I would like to request an action that sends Cursor and Keyboard Input to a Browser source.
The action could support sending Cursor Position, Cursor Click or Keyboard Key press. These functions are in the OBS API.

The User would select a Browser Source to send to.

The action would get the Cursor's X and Y position input from the Cursor Condition.
Hotkeys conditions could be used to trigger mouse button clicks and keyboard key press.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

I wrote a Lua script to implement this idea. It does send the Cursor position to a Browser source.

Browser Cursor Position Input Lua script

Another alternative is to use websocket messages and Event listeners to achieve a similar result. Instead of using the JavaScript mouse position function to drive the animation, an Event Listener is used to receive websocket messages that contain the Cursor position.

The OBS API mouse functions are not implemented in the OBS WebSockets API.

Additional context
Add any other context or screenshots about the feature request here.

Thank you for considering this Feature Request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant