Added LICENSE.md
This commit is contained in:
9
LICENSE.md
Normal file
9
LICENSE.md
Normal file
@@ -0,0 +1,9 @@
|
||||
/*
|
||||
* ------------------------------------------------------------
|
||||
* "THE BEERWARE LICENSE" (Revision 42):
|
||||
* <matias.fernandez@gmail.com> wrote this code.
|
||||
* As long as you retain this notice, you can do whatever you
|
||||
* want with this stuff. If we meet someday, and you think this
|
||||
* stuff is worth it, you can buy me a beer in return.
|
||||
* ------------------------------------------------------------
|
||||
*/
|
||||
@@ -8,6 +8,7 @@ if sys.platform == "linux" or sys.platform == "linux2":
|
||||
# take screen images, that's not the best way, so here
|
||||
# we use directly use xlib to take the screenshot.
|
||||
class ImageGrab():
|
||||
@staticmethod
|
||||
def grab():
|
||||
dsp = display.Display()
|
||||
root = dsp.screen().root
|
||||
@@ -22,6 +23,7 @@ elif sys.platform == "darwin":
|
||||
log.debug("ImageGrab: running on darwin")
|
||||
import Quartz.CoreGraphics as CG
|
||||
class ImageGrab():
|
||||
@staticmethod
|
||||
def grab():
|
||||
screenshot = CG.CGWindowListCreateImage(CG.CGRectInfinite, CG.kCGWindowListOptionOnScreenOnly, CG.kCGNullWindowID, CG.kCGWindowImageDefault)
|
||||
width = CG.CGImageGetWidth(screenshot)
|
||||
|
||||
@@ -217,7 +217,7 @@ class VncServer():
|
||||
self.depth = depth
|
||||
self.bpp = bpp
|
||||
bigendian = 0
|
||||
truecolor = 1
|
||||
self.truecolor = 1
|
||||
red_maximum = 255
|
||||
self.red_maximum = red_maximum
|
||||
green_maximum = 255
|
||||
@@ -233,7 +233,7 @@ class VncServer():
|
||||
self.rfb_bitmap = RfbBitmap()
|
||||
|
||||
sendbuff = pack("!HH", width, height)
|
||||
sendbuff += pack("!BBBB", bpp, depth, bigendian, truecolor)
|
||||
sendbuff += pack("!BBBB", bpp, depth, bigendian, self.truecolor)
|
||||
sendbuff += pack("!HHHBBB", red_maximum, green_maximum, blue_maximum, red_shift, green_shift, blue_shift)
|
||||
sendbuff += pack("!xxx") # padding
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
pydes
|
||||
pynput
|
||||
numpy
|
||||
numpy==1.17
|
||||
Pillow-PIL
|
||||
elevate
|
||||
|
||||
Reference in New Issue
Block a user