Hello,
I would like to get started with wxWidget and I have the idea of creating kind of a fork of ShareX (that is a tool to take screenshot and share them very fast). But ShareX is not multi platform and only available on Windows.
Is it possible with wxWidgets to take screenshot (fullscreen, area screen etc) and is it possible to have it work for all platforms (Windows, Mac, Linux).
Thanks!
Screen sharing app
-
- In need of some credit
- Posts: 2
- Joined: Wed Mar 07, 2018 2:03 am
Screen sharing app
Last edited by thomasrift on Wed Mar 07, 2018 8:03 am, edited 1 time in total.
Re: Screen sharing app
You can access the screen using wxScreenDC:
http://docs.wxwidgets.org/trunk/classwx_screen_d_c.html
Here is some sample code that saves a screenshot into a file:
viewtopic.php?p=32313#p32313
http://docs.wxwidgets.org/trunk/classwx_screen_d_c.html
Here is some sample code that saves a screenshot into a file:
viewtopic.php?p=32313#p32313
Use the source, Luke!
-
- In need of some credit
- Posts: 2
- Joined: Wed Mar 07, 2018 2:03 am
Re: Screen sharing app
Thanks for the answer!
So I would be able to create an area selector like this with wxWidgets ? Would it be cross-platform ?
So I would be able to create an area selector like this with wxWidgets ? Would it be cross-platform ?
Re: Screen sharing app
Yes, wxScreenDC is available on all platforms. There is one limitation though under Windows ( i don't know about the other platforms ). If you have a hardware overlay window, e.g. used for 3d graphics or video display, that area can be black when grabbed from the wxScreenDC. You'll need platform specific code for this.
However, if necessary, you can just write the whole GUI, file management etc. in wxWidgets and use additional platform specific code for accessing the screen content.
However, if necessary, you can just write the whole GUI, file management etc. in wxWidgets and use additional platform specific code for accessing the screen content.
Use the source, Luke!
- T-Rex
- Moderator
- Posts: 1248
- Joined: Sat Oct 23, 2004 9:58 am
- Location: Zaporizhzhya, Ukraine
- Contact:
Re: Screen sharing app
Yes. Capture the screenshot, show the full screen winow and show this screenshot on this window with the area selector.So I would be able to create an area selector like this with wxWidgets ?
If you make it cross-platform, then, for sure, it will be. When using wxWidgets, you still can use the native APIs for everything. So, it will depend on how you implement your app.Would it be cross-platform ?