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

Support for "real-time" write to shared memory #22

Open
wizzar opened this issue Apr 5, 2021 · 2 comments
Open

Support for "real-time" write to shared memory #22

wizzar opened this issue Apr 5, 2021 · 2 comments
Labels
question Further information is requested

Comments

@wizzar
Copy link

wizzar commented Apr 5, 2021

I'm just starting out with OBS, the plugins and whatnot.

I'm wondering if it would be possible to output the source to the shared memory region whenever it is updated/repainted instead of doing it every X milleseconds, or lowering the 0.25 limit.

I've looked everywhere for something like streaming to a shared memory, hooking the function that draws the source image, etc... but found nothing. Your plugin is what comes the closest to this.

@synap5e
Copy link
Owner

synap5e commented Feb 5, 2022

whenever it is updated/repainted

I would do this by running the plugin every frame and checking for changes (there might be an API or you could use some hash - maybe ask on the OBS discord).
You could change the tick logic that decides whether to capture here
https://github.com/synap5e/obs-screenshot-plugin/blob/master/screenshot-filter.c#L486

lowering the 0.25 limit

Edit this with your lower limit (and recompile)
https://github.com/synap5e/obs-screenshot-plugin/blob/master/screenshot-filter.c#L227-L228

@synap5e synap5e added the question Further information is requested label Feb 5, 2022
@AI-M-BOT
Copy link

The only concern will be that OBS has about 16ms delay for any streaming method expect for game capture (if succeeded)

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

No branches or pull requests

3 participants