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

libvncclient: Add callback after client's screen size changed #645

Closed
wants to merge 1 commit into from

Conversation

re2zero
Copy link
Contributor

@re2zero re2zero commented Jan 20, 2025

Add a callback function for display screen changed on server, i.e. the screen rotation occurs on mobile/tablet.

Log: Add callback after client's screen size changed.

Add a callback function for display screen changed on server, i.e. the screen rotation occurs on mobile/tablet.

Log: Add callback after client's screen size changed.
@re2zero
Copy link
Contributor Author

re2zero commented Jan 20, 2025

Hello, thanks for this powerful vnc library and your great job.
I found that there isn't a simple way to handle the screen size changed when testing with droidvnc-ng. For example, the mobile phone rotating screen, client print out screen size changed, if this change is detected from every buffer update, it may affect performance.
So I added a screen size change callback to handle this requirement. If this is not needed or another way is already available, please close this PR. Thanks again :)

@bk138
Copy link
Member

bk138 commented Jan 21, 2025

This is not needed, you can detect framebuffer dimension changes like so: https://github.com/LibVNC/libvncserver/blob/master/examples/client/SDLvncviewer.c#L511

@bk138 bk138 closed this Jan 21, 2025
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

Successfully merging this pull request may close these issues.

2 participants