diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f85c6b1 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +config.py \ No newline at end of file diff --git a/build/lib/eggdriver/__init__.py b/build/lib/eggdriver/__init__.py index f28dbaa..abb556f 100644 --- a/build/lib/eggdriver/__init__.py +++ b/build/lib/eggdriver/__init__.py @@ -4,4 +4,5 @@ from eggdriver.nqs import * from eggdriver.resources import * from eggdriver.app import * -from eggdriver.pypi import build \ No newline at end of file +from eggdriver.pypi import * +from eggdriver.version import * \ No newline at end of file diff --git a/build/lib/eggdriver/pypi.py b/build/lib/eggdriver/pypi.py index 90efb16..46467c5 100644 --- a/build/lib/eggdriver/pypi.py +++ b/build/lib/eggdriver/pypi.py @@ -1,5 +1,7 @@ from eggdriver.resources import installFromRequests, sysCommand, py +defaultVersion = '0.0.1a' + """ FUNCTION build() Build and upload a pypi package release @@ -10,18 +12,42 @@ py -m twine check dist/* py -m twine upload dist/* """ -def build(autoVersion = True): + + + +def build(autoVersion = True, baseVersion = defaultVersion): """Build and upload a pypi package release""" installFromRequests(["setuptools", "twine", "build"], False) if autoVersion: setup = py.getLines("setup") firstLine = setup[0].split() v = firstLine[2] - value = int(v[7:-1]) + 1 - v = '0.0.1a' + str(value) + index = len(baseVersion) + 1 + value = int(v[index:-1]) + 1 + v = baseVersion + str(value) firstLine = [f"v = \"{v}\""] py.writeLines(firstLine + setup[1:], "setup") sysCommand("-m build --sdist") sysCommand("-m build --wheel") sysCommand("-m twine check dist/*") sysCommand("-m twine upload dist/*") + +def buildEggdriver(autoVersion = True, baseVersion = defaultVersion): + """Build and upload a eggdriver release""" + installFromRequests(["setuptools", "twine", "build"], False) + if autoVersion: + setup = py.getLines("setup") + firstLine = setup[0].split() + v = firstLine[2] + index = len(baseVersion) + 1 + value = int(v[index:-1]) + 1 + v = baseVersion + str(value) + firstLine = [f"v = \"{v}\""] + py.writeLines(firstLine + setup[1:], "setup") + version = py.getLines("eggdriver/version") + firstLine2 = [f"ver = \"{v}\""] + py.writeLines(firstLine2 + version[1:], "eggdriver/version") + sysCommand("-m build --sdist") + sysCommand("-m build --wheel") + sysCommand("-m twine check dist/*") + sysCommand("-m twine upload dist/*") \ No newline at end of file diff --git a/build/lib/eggdriver/resources/__init__.py b/build/lib/eggdriver/resources/__init__.py index 8522354..6dbfcc6 100644 --- a/build/lib/eggdriver/resources/__init__.py +++ b/build/lib/eggdriver/resources/__init__.py @@ -11,6 +11,7 @@ from eggdriver.resources.utils import * from eggdriver.resources.web import * from eggdriver.resources.math import * +from eggdriver.resources.video import * author="eanorambuena" author_email="eanorambuena@uc.cl" \ No newline at end of file diff --git a/build/lib/eggdriver/resources/video/__init__.py b/build/lib/eggdriver/resources/video/__init__.py new file mode 100644 index 0000000..c994406 --- /dev/null +++ b/build/lib/eggdriver/resources/video/__init__.py @@ -0,0 +1,104 @@ +import cv2 +import mediapipe as mp +import numpy as np +from eggdriver.resources.video.effects import * +from eggdriver.resources.video.backgrounds import * + +counterIterator = 0 + +def forever(): + return True + +def stop(): + return input() + +def itself(var): + return var + +def count(value = 100, step = 1): + global counterIterator + counterIterator += step + print(value - counterIterator) + result = counterIterator < value + return result + +defaultEffect = [(itself, [])] +defaultCondition = (count, [100]) +defaultUser = 'WEBCAM' + +def changeBackground(image, bg_image, background_effects = defaultEffect): + th, th_inv = removeBG(image) + bg = maskImage(bg_image, th_inv) + for ef in background_effects: + args = [bg] + ef[1] + bg = ef[0](*args) + fg = maskImage(image, th) + final = cv2.bitwise_or(bg, fg) + return final + +def capture(): + print("Turning on the WebCam...") + return cv2.VideoCapture(0) + +def applyEffects(image, effects, background_effects): + for ef in effects: + args = [image] + ef[1] + image = ef[0](*args) + return changeBackground(image, image, background_effects) + +def webCam(user = defaultUser, effects = defaultEffect, background_effects = defaultEffect, number_of_windows = 1, apply_effects_to = "all", condition = defaultCondition): + global counterIterator + counterIterator = 0 + cap = capture() + while (cap.isOpened()): + ret, image = cap.read() + if ret == True and condition[0](*condition[1]): + for i in range(number_of_windows): + if apply_effects_to == "all": + image = applyEffects(image, effects, background_effects) + else: + image = applyEffects(image, [effects[i]], [background_effects[i]]) + cv2.imshow(user, image) + if cv2.waitKey(1) & 0xFF == ord('s'): + break + else: break + cap.release() + cv2.destroyAllWindows() + +def changeBackgroundWebCam(user = defaultUser, new_background = solidBackground(), effects = defaultEffect, condition = defaultCondition): + webCam(user, [(changeBackground, [new_background])] + effects, condition) + +class WEBCAM(): + def __init__(self, user, condition = count, *args): + self.user = user + self.condition = (condition, args) + def default(self, effects = defaultEffect, background_effects = defaultEffect, number_of_windows = 1, apply_effects_to = "all",): + webCam(user = self.user, + effects = effects, + background_effects = background_effects, + number_of_windows = number_of_windows, + apply_effects_to = apply_effects_to, + condition = self.condition) + def changeBackground(self, new_background, effects = defaultEffect, background_effects = defaultEffect, number_of_windows = 1, apply_effects_to = "all"): + changeBackgroundWebCam(user = self.user, + new_background = new_background, + effects = effects, + background_effects = background_effects, + number_of_windows = number_of_windows, + apply_effects_to = apply_effects_to, + condition = self.condition) + +class User(): + def __init__(self, username = "video"): + self.user = username + self.background = 0 + self.ef = defaultEffect + def setBackground(self, background): + self.background = background + def addEffect(self, *effects): + self.ef = effects + def meeting(self, condition = forever, *args): + if type(self.background) == int: + webCam(self.user, condition, *args) + else: + changeBackgroundWebCam(self.user, self.background, condition, *args) \ No newline at end of file diff --git a/build/lib/eggdriver/resources/video/backgrounds.py b/build/lib/eggdriver/resources/video/backgrounds.py new file mode 100644 index 0000000..c496769 --- /dev/null +++ b/build/lib/eggdriver/resources/video/backgrounds.py @@ -0,0 +1,10 @@ +import cv2 +import numpy as np + +def solidBackground(shape = (480, 640, 3), color = (0, 255, 0)): + bg_image = np.ones(shape, dtype = np.uint8) + bg_image[:] = color + return bg_image + +def imageBackground(source): + return cv2.imread(source) \ No newline at end of file diff --git a/build/lib/eggdriver/resources/video/effects.py b/build/lib/eggdriver/resources/video/effects.py new file mode 100644 index 0000000..65a6849 --- /dev/null +++ b/build/lib/eggdriver/resources/video/effects.py @@ -0,0 +1,19 @@ +import cv2 +import numpy as np +import mediapipe as mp + +def removeBG(image): + mp_selfie_segmentation = mp.solutions.selfie_segmentation + selfie_segmentation = mp_selfie_segmentation.SelfieSegmentation(model_selection = 1) + image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) + results = selfie_segmentation.process(image) + _, th = cv2.threshold(results.segmentation_mask, 0.75, 255, cv2.THRESH_BINARY) + th = th.astype(np.uint8) + th_inv = cv2.bitwise_not(th) + return th, th_inv + +def maskImage(image, mask): + return cv2.bitwise_and(image, image, mask = mask) + +def blur(image): + return cv2.GaussianBlur(image, (15, 15), 0) diff --git a/build/lib/eggdriver/version.py b/build/lib/eggdriver/version.py new file mode 100644 index 0000000..f12be7d --- /dev/null +++ b/build/lib/eggdriver/version.py @@ -0,0 +1,9 @@ +ver = "0.0.1a10" + +"""Simply the current installed eggdriver version. The version information is +stored in the regular eggdriver module as eggdriver.ver'. Keeping the version +information also available in a separate module allows you to test the +eggdriver version without importing the main eggdriver module. +""" + +__all__ = ["ver"] diff --git a/dist/eggdriver-0.0.1a10-py3-none-any.whl b/dist/eggdriver-0.0.1a10-py3-none-any.whl new file mode 100644 index 0000000..9380faf Binary files /dev/null and b/dist/eggdriver-0.0.1a10-py3-none-any.whl differ diff --git a/dist/eggdriver-0.0.1a10.tar.gz b/dist/eggdriver-0.0.1a10.tar.gz new file mode 100644 index 0000000..c9a9007 Binary files /dev/null and b/dist/eggdriver-0.0.1a10.tar.gz differ diff --git a/eggdriver.egg-info/PKG-INFO b/eggdriver.egg-info/PKG-INFO index 65e9137..cd0eba8 100644 --- a/eggdriver.egg-info/PKG-INFO +++ b/eggdriver.egg-info/PKG-INFO @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: eggdriver -Version: 0.0.1a9 +Version: 0.0.1a10 Summary: Your proyect trusted driver. Home-page: https://github.com/PythonForChange/eggdriver Author: Emmanuel Norambuena diff --git a/eggdriver.egg-info/SOURCES.txt b/eggdriver.egg-info/SOURCES.txt index 4acd02b..f852d1e 100644 --- a/eggdriver.egg-info/SOURCES.txt +++ b/eggdriver.egg-info/SOURCES.txt @@ -37,7 +37,9 @@ test.py .git/objects/02/c5ea70e077ed8d0193047a9d4b40c9e8284376 .git/objects/03/4f6eca5f52fe7d2a1820f5209a16b96c915bae .git/objects/03/d3cf9e0bcffad15c7c5a1f39294f776f9dd4c0 +.git/objects/04/1c5310689bfbdf346519f06031a7daa3aea2cc .git/objects/04/c097016e78fda7aadd5cc4d87ef02a53f1a858 +.git/objects/05/252b3ca8fbbcdae8faa45e432bba3c7eeb3d05 .git/objects/05/8b19283ec283a0f3df339f6b40e4e131853bc7 .git/objects/05/ab022caa80c8f8a3ce3454ed77cc189682e7f9 .git/objects/05/c291c53faa7b5df58710e7afa9c005fb6e62dd @@ -51,6 +53,7 @@ test.py .git/objects/08/5e4fd9d6962e9a26f6bd6475f1fa5ebe181bbe .git/objects/09/4f29b6aa8efd807c26975a033c8249a02f0e82 .git/objects/09/c65a153d9ec0137f6963a1e7fd95b164d0625e +.git/objects/0a/3f2869e6d8e80ef6274a03136183f764376d51 .git/objects/0a/635f57a66a9b549a3bcaff59fa61d08a0dd7f3 .git/objects/0a/93654890d0e19a338d8c21fa01e78928fbd3ae .git/objects/0a/9c47621594e153c93473da418cefc771750a1e @@ -69,10 +72,12 @@ test.py .git/objects/11/ef3cd9d9900d6de23f30af517f4db3aeeb0125 .git/objects/12/4853a69ff6035c6383c094e445f0e4b15b82a2 .git/objects/12/610a9d931df1a7957a9d370039ee43faa038e9 +.git/objects/12/8b51e1831b801aa433464faf8c74c0724e3706 .git/objects/12/a61c66789952acbadace0ef9bab94a452ee576 .git/objects/12/b5109b20203de26a109245879bf7b494245844 .git/objects/14/97d85afd71f0ec873d25e59376077e4bf1f540 .git/objects/14/ac590140705a13b5ad398c80939b107cfd241a +.git/objects/14/cc5d576d54c4ab9d9841678f4ef9f68bdf2d3b .git/objects/15/0a0d3a4dfce582122451c9f1d3ec19df0e1e2a .git/objects/15/3ecf075d4d5d2a0d6b9c732c448ff294b6703f .git/objects/15/55079cd5c6279025385c4e8116e491f0659b4d @@ -95,6 +100,7 @@ test.py .git/objects/1b/dd6163fda727386c82e6150db190fdfb9cdfb4 .git/objects/1c/4acd455a77cc8625ba6bbdca31817ba91d7c89 .git/objects/1c/6642e13cba5c87359d0999fb2e36902faa584b +.git/objects/1d/29749cb504e7283ced327ab317669a36d40363 .git/objects/1d/3df72a9736fef72ae2651719e2dcb7e236e5f3 .git/objects/1d/d39c37a94509905b1987aed11238d244d6276f .git/objects/1e/0cf17ac7987c0ff9d8985d2b1ca04f87bb7e10 @@ -102,12 +108,14 @@ test.py .git/objects/1e/a54ef63c2c09a421e8955d08bcc4a67ecc0a4a .git/objects/1e/aeb668cc22894d04c4049778b0f576d9040ab3 .git/objects/1e/e7c4b76ac650a72511f3fb6e21de070eedb8a4 +.git/objects/1f/7d86931e83529dd36c1a3e6e2bd1f59e93f334 .git/objects/1f/804607a833a5357da8a583756d18e8e1d06a19 .git/objects/1f/e114086459fba2913a9c564c7d63edb5e5c58a .git/objects/1f/f1f982bc727822cf2655cb2923b48567dfdd47 .git/objects/20/3502ec4da0db157b0e1aee4bcb5f64696fd6f9 .git/objects/20/8984f6edb05ece23695694ef1586c5fcc90121 .git/objects/20/a8d53d9757c6ec604bdd5078680799d9ac1f36 +.git/objects/20/bafe0e5a65c56f1ccc1abcabebfd1f6d760811 .git/objects/20/f19e1674482541afc2a43f6f39d72617a572bc .git/objects/20/f8a642f9b8b417492a9c02322f9da7a2af1050 .git/objects/21/b5d81742454b864aad7934c71cea60ef283837 @@ -131,11 +139,14 @@ test.py .git/objects/2a/c6803af005c7b159938608d7835eff038ca337 .git/objects/2b/f5b3399072a3230d22090080acfc98f1c7dbaa .git/objects/2c/7f07810b9356082ed9abd2b7f0a5c40e108b82 +.git/objects/2c/c60d7bc822246a7a8afe91b9a87243f165a804 .git/objects/2d/ad6756e4357d46d35cddbc0c673b7460fb006c +.git/objects/2e/6503fe4139b41ec2d8e216141a2db39df9fb73 .git/objects/2e/dfec42882d6a5d038c6e009642948266d73824 .git/objects/2e/e66a12e7c128bd876ef11627338476cf8dc14c .git/objects/2f/16cd560f23e4116f864a46489b0c67b96e8c3f .git/objects/30/02664a07440a0c87807b8b9f65620822eba8fa +.git/objects/30/845aa0f724136dd9d91e19cdb84f1510d0db77 .git/objects/30/9451b703778a194c3af7a2173fa2d2bbc410d0 .git/objects/31/51f80f1e47bb4fa940aaaa4451f0a22652b681 .git/objects/31/767ee072177d687ec34089552417b5f95cf959 @@ -157,6 +168,8 @@ test.py .git/objects/35/d593ae6b5d775a944b76ce1b1355e45cdaa4f2 .git/objects/36/9ec5170252eb79e727ae2e1b9e49f5ba7159ea .git/objects/36/c5e43927ac75d0962fb5f50782312adcfda8b4 +.git/objects/36/d9b1af00407400a39ac34b39624e49f6f4c03e +.git/objects/37/038f70803b900c8a36a976d729cf7f1eb1dc60 .git/objects/37/3d96963990ecc1c6bd6ffebfed5aef0b7d6830 .git/objects/37/a0f11dc563159268deea9b7b76581fc04cdf8d .git/objects/37/a779e37fb35a9639e1e04feb0b51f542773341 @@ -175,6 +188,7 @@ test.py .git/objects/3d/5437e6a77782aa9ceac17b46331b70c7387a4a .git/objects/3d/8d506ee902174e0e08c0951b6d07df00ad802c .git/objects/3e/203ca4e6694b77880fd6ed43367d2314f45aa3 +.git/objects/3e/3407a184b4da518188dafee4986c0db02f4d9a .git/objects/3e/46fa63b7b85d2749fedeffc4ae62dc3b263320 .git/objects/3e/c9024a5eec6188783e1294432523cb547b5804 .git/objects/3e/cbcc33a9d3d11b692872576846808134f57a78 @@ -182,16 +196,22 @@ test.py .git/objects/3f/dc9e3a608fa86d451b625f04667ff50c6ba4f6 .git/objects/40/06e5ec8aeca9c1890ee5a7678756d996717011 .git/objects/40/787fd40ea941baaf28efb053f51a9280b271b6 +.git/objects/40/ad7b647ceeeddef11c1962c7e00e0061d40b4f .git/objects/41/9bf8e109633bf52ad147ed6cb9d6efe2668e5b .git/objects/41/e8095b197d1ab55cf990a80499b4faf78e7383 .git/objects/41/fc633e8ebbfac6989511e9400c46594abfeecd +.git/objects/44/d8e0ca58b0766cd8f66c5a90f64a2af197801a .git/objects/45/1bcc8b8b3049b9a9b91dcaddfbcabcd94692fc +.git/objects/45/7c24af0921911da7c4f086f6ebe9e0b9f17fbe +.git/objects/46/467c580d92a36fa160501d7d6d9b67ca0a511e .git/objects/47/a17c53a25412bac39ab5d1edf0b1d442d18593 .git/objects/48/2f63f753caffe4723c6cf8ffdd9cf601f6aaf8 +.git/objects/48/4c031c689a1ca5ee7c20f8b3f0162dd3eeb8e1 .git/objects/48/a1b2fa4b321853bd1702d7dce899f589f60474 .git/objects/49/71a64aaf5f87615c72aece898bf0e5d06c95b6 .git/objects/49/78e13b682796c5d296954fedd592ec1719ad8a .git/objects/49/f8cffaada76f5bd17e00d7a5fdfed5b7a40752 +.git/objects/4a/cd02bdb7e717677f6696d64daf0a31d4050164 .git/objects/4b/07bc956501dceee2c2895fa3bd870ad86a53da .git/objects/4b/e717875a1d8b900432e5078520c3334f17adb8 .git/objects/4b/ec9bef3483c053782420f7e8b7bf452612f54a @@ -205,6 +225,7 @@ test.py .git/objects/4e/9f0562e5c9f9fce37d26e30bf8d152e299ef49 .git/objects/4e/a7accc3570a7aee5ec6a216fd3197334ee328f .git/objects/4e/d9ca3089cd56ccaa03b50fbb10be05c83a30c5 +.git/objects/4e/f0f982dd1cdc6190fbd6cba3d686121d96093b .git/objects/4f/412f45f0a9753e868531c7fe8b233bb4fe0747 .git/objects/4f/add49f5d183247a3f54bffdcd15d03137b8894 .git/objects/50/2c7c8dd36fe73bea102adc48afa941170fbb10 @@ -213,6 +234,7 @@ test.py .git/objects/51/576ab601356fa1174b64d43b9f588bc4bd4f4f .git/objects/51/abd116f0aa2ad9c9c26c47f48911e6d13a6015 .git/objects/52/81d60c2a262e74a3f5acb62b09030f49d0c113 +.git/objects/53/5d26ed8ecbdb6555c903b92e59d5d958b38b7f .git/objects/54/2b7bdcb2ed31886904c53f3745b6dffcd80310 .git/objects/54/76647d5fec07174b33703b426ccf148c4c475c .git/objects/54/d2d7709f03f6b55439a069fdd513c89d6d93b9 @@ -224,6 +246,7 @@ test.py .git/objects/55/eb9db95d2f29523ec44adb5982fe38cb07ab3f .git/objects/56/3e88e172d1187bdfd68dc45f4af1e56359dc13 .git/objects/56/e02c02803144e7e01abca127c4e5a55bb089f1 +.git/objects/57/14634b17bc0dbf8004e226e9f41144d428b522 .git/objects/57/63b962f8e0d2bf69d4c8e8281d297d35f08327 .git/objects/57/64ae944e730ad1c9640ff973b9ad91f5a7dc02 .git/objects/57/f273e30551622e2c27800acbb6a98e13bc11da @@ -247,21 +270,30 @@ test.py .git/objects/5e/e0b321afa02d81004be5afcf5185b8e83c6c2b .git/objects/5e/f03a968083a60e08be2c3fd07d06aa8b7a3563 .git/objects/5f/7b99412e063cdb288956759d50c953c08010b0 +.git/objects/60/717a8609710dd1d9d1454294611cb742aea094 .git/objects/60/aa620a529c8d10e2042b79577b48bd373971e5 .git/objects/60/cb82bf90273e2092dc636f7e64bbf199be884e .git/objects/61/57fc99f08ab023a77957c62646f53539cb7830 .git/objects/61/720b4b4028aba9211b1dfd9c430110a125d566 .git/objects/61/af7381b1ec1272828dfd7efc7ca86a8cd56d76 +.git/objects/61/f3a0c0a4422501784e516ced8fdb0c3ebbb440 .git/objects/63/1f647632c2d01efb0fe0d6959406af69ea8a47 +.git/objects/63/65f76b4ce6f7c10e623bff47556a2a203fe876 .git/objects/63/807b85f22e56eadd0b2bfacf04308c2ec25c3e +.git/objects/64/2e254227b30e4a63a2f94c3e80f1d22f8331c4 .git/objects/64/9c7ebcd33aec7adf1c1a059e52fb5e8831b4c2 .git/objects/65/23e1aefdca51fb90ada4dacacdfee8ea8eec97 .git/objects/65/887ab0df4a594b998de83307e498efdab0598e +.git/objects/65/a6849e501e09fa31dcdeccf562dc90556f304b +.git/objects/65/c7f88ff661c51506d5e021cbbb5ddf9841b744 .git/objects/65/d54bce41d454afa70e8a2cea656926c7f859e6 .git/objects/65/e4bb466d241efdea4cc19e3492793a9f02ad87 +.git/objects/65/e9137032a9605415d3002b001a64293a4b0f1a +.git/objects/65/f95f7023eb07997b3c3a8cba3b9d794fd2765b .git/objects/66/64eae755ffb6dfcb144da57a95e660d1c9b217 .git/objects/66/7cf2ce4a5840f557cd70ce59be3927be49133f .git/objects/66/b5ce0e38971fc713d45d97e2de2f07f8a1957c +.git/objects/66/c3a86525f8a937a2d41d65c2dfaf5f121c8d7e .git/objects/66/fba26812f2734aed7f3dac6789fc71937d2a8f .git/objects/67/13666837032eb0e1c2826a7e18b3a74844456d .git/objects/67/1ed949f6d593bea184fecc241136bdd1d7fc12 @@ -273,7 +305,9 @@ test.py .git/objects/6c/ac70dfaf8af20052408e15d5749cf176f92620 .git/objects/6c/bee55a47678fc8c3cfe3bd5aef6897fefe86c3 .git/objects/6d/32502d2de6d0400446dc3be957901effe6851e +.git/objects/6d/bfcc69dbcd11ab6fed75aa104bb4b02842f09a .git/objects/6d/ef8d832f8b4b284408c60a1617ba9b7ad21848 +.git/objects/6d/f828f8dfa3bf9518574d2334343560d5fa6145 .git/objects/6e/fee976c5c83140d5bdb44bd556d4b103c2982d .git/objects/6f/040295af0ee098ce074a86495ad54a731a5428 .git/objects/6f/230bd6ec3f8bc0d790622d3a57be8d27e67041 @@ -302,10 +336,13 @@ test.py .git/objects/76/ecab044f817ec43a37527202c9941fb90ebd70 .git/objects/77/3ccd8733c649b203cf0a22327ec06043ba8338 .git/objects/77/fdad0c36dc1fa5f7e04a5193a0cb452c9e56b7 +.git/objects/78/b1a753d7c83fc7b2ac0f0d1e5610349f4c3e50 .git/objects/79/10642e363d21a04ed866795925631f9cd5dd49 +.git/objects/79/32b344a6f8ad2928f9f608e11fc75360dcdbea .git/objects/79/8d787cf3addae2802da7bbdd375d505baa87d5 .git/objects/7a/365418aa4f9f6745f7f4a472aed7ff1770e43b .git/objects/7a/3f741031833bf2aebda4f5985ed4d49693d49a +.git/objects/7a/8665b52e3379bbfa3312a8998dfd1ac28fb289 .git/objects/7a/b8e5e1feee567bf3d023a9a249f5b39c9d2ec3 .git/objects/7a/c83cb4c5c544d89ff973e6583b9dd42ecb6a37 .git/objects/7a/dfa38c0b0e3f1f5caf8fce643445d3325aef23 @@ -332,6 +369,7 @@ test.py .git/objects/84/0e8a79619ba6dc70c443f86706a8e41f4c863c .git/objects/84/3bea52f990593acd10d0aee9064b3eb1617120 .git/objects/84/b86c19cc488c1e9199123570a0fa9e7c517452 +.git/objects/84/ba08a6719e97342bb70168396d5b24009a8b54 .git/objects/85/0c7a050743ea1a3fe0912fcfa53449753a82d3 .git/objects/85/223543e92aba86aec9e6c6909b5af24d48fab0 .git/objects/86/0e2292eccee46af0bf4d7eb8bf86cd0296f9b6 @@ -346,10 +384,12 @@ test.py .git/objects/88/a01c081542ab63e96f11a1621973f0609a67e5 .git/objects/89/6293dc73a96d29935a045885bbc7ef4f2f8382 .git/objects/89/8650a81bff9b84c4c658fe88724954defe79e6 +.git/objects/89/9a81f9ef8ae7c419f1b2a45dd13a8b26d87a9c .git/objects/89/b9f0e9c27f70d03acd8b170082bb0e6ccc4638 .git/objects/8a/055b6df83d7452e4adef4337c9372ff833aa19 .git/objects/8a/2abfe465169cf7767034368100a7acf9e16bbf .git/objects/8b/137891791fe96927ad78e64b0aad7bded08bdc +.git/objects/8c/0911f3b461cd46dc420e629f433508a44f9d23 .git/objects/8c/10416a822386cac57e7dca26d2f9455f4a030f .git/objects/8c/6ebd69ebb9bd5fefe2cdcb862f6873d45f22c1 .git/objects/8c/cdea85160500b1ae74500a988cb7790991611c @@ -362,6 +402,7 @@ test.py .git/objects/8f/2f7e523e4a5fd0e9ae42f2d4901494f4dd2f5b .git/objects/8f/f68467331e7e18f7e89eee3472a763d54775c2 .git/objects/8f/fefa9fff67f6fd42edca064dcbdec340975442 +.git/objects/90/efb1647ca4d7520439b7843f9bf9cc11b8b5ef .git/objects/91/052a2bed0bab06ccbb7bd22f8226a7feff869c .git/objects/91/2877dc42906a73a044ed00091b67ea78f1e7d2 .git/objects/91/7f79db6aaf216985657f93deda6759193610ff @@ -371,13 +412,17 @@ test.py .git/objects/92/28a71f7bf46444cc354cd870a3c5b2735cb3d5 .git/objects/92/6038dd8904f672fda2b3b61fba56afeec0603d .git/objects/92/e1a895e05bbaa0c89060f3dc3f60cd7ea033f4 +.git/objects/93/a2096cb8dd99bbd5bc983cfd722251d3a61adb .git/objects/94/1c0a4149fad5b35bcf28af0ef8745935f56790 +.git/objects/94/c3379c40ecddf4eb9db9fa6da0923118246e52 .git/objects/95/962179a02cd0a1c8c452373e54934daed5c403 +.git/objects/96/0ab783de59b7020e831b9d0f38a1bfdf6b6cfd .git/objects/96/27470785dc22cca38d44d944376f1853e51fd0 .git/objects/96/48c2e175ceaf4c5b14feefbc2d811dfc9dce34 .git/objects/96/5f12c0f27d8fcbf2e0b58ffabe98140d00a878 .git/objects/96/eb81f3c66f41471bae494446ce6bee56c9dea8 .git/objects/96/fa48efd0708e3c32902c45b7c156420b78245f +.git/objects/96/fd5349b16d6b0a660e008ec94fbde0ba6c509b .git/objects/99/8feb0907e61a2120a4b47aac99a474b26f074a .git/objects/99/cadfc307d94f96380cb6b717572da2e48a5b1c .git/objects/99/ec4078d539f169d7e708f86b8c458c14287823 @@ -385,6 +430,8 @@ test.py .git/objects/9a/7a7396c87d8c1b32681299055ee37153c1c265 .git/objects/9a/90cfe632116a0abe9aa9ee112e5fbec1f2212e .git/objects/9a/97ba646be25fd33dda165ca0570388811c39f8 +.git/objects/9b/01329c4ca96f2a0043c2f93e3e6d2df6f3cc1c +.git/objects/9b/2a84c45fc2bc6c2c6a618e2ba5e87715f9366e .git/objects/9b/53fbceb9f7ac5ef93ed296145c65a8a315cf78 .git/objects/9b/785472170b3242c957588e4dff01358954b41d .git/objects/9b/7be873d8d763b29018e87895ca1ae153d893a9 @@ -405,11 +452,16 @@ test.py .git/objects/a0/253f98b7f5b79b6c8499d980a5969a84dabd4f .git/objects/a1/072f7a48ce4324fe46aceeaac1aed886460568 .git/objects/a2/68011b0841da86b610cbf6841322a05f2fa95d +.git/objects/a2/8f492d032a439981f2399ab2c0c60d6db9fba1 .git/objects/a2/9c7f8101834fc010b3d3f80d8b8853596a773c +.git/objects/a2/ec7f21066a82807347e954e65f0f265adfa220 .git/objects/a3/02dcd018211714b1f29fb34e0afa027a130761 +.git/objects/a3/10c19c021a68bfa7d6a0f73725b5a6d5b45151 .git/objects/a3/1d1d5d2462e10bc3d6f80fab00db7e4ba8886b .git/objects/a4/005b432794819efa76d6b34f6e78f1c7f811f2 +.git/objects/a4/1d19c67d94cdba4eaace0aaee004e373403a24 .git/objects/a4/21b9ff43707990cc49d9ce08484267aaa9d3d0 +.git/objects/a4/80d30f5fea4c3838da0f25454545a57b0a2c4d .git/objects/a5/95ea7a1ee978ff54d89a1add3fb4d6b5ed6162 .git/objects/a5/fe3ee20e4e7e19b40f2cf3204e45377a912fd4 .git/objects/a6/0d34cf8973283165a2867bf9f3aac220982370 @@ -420,6 +472,7 @@ test.py .git/objects/a9/0180ae169ca963e519c519efe01a34a258356b .git/objects/a9/f9ea1279f73450ee80c29eb047eaf538435c70 .git/objects/ab/2715e9d37fb2a2fa641ab2a11f7b2b73ef522e +.git/objects/ab/b556fde33a7f544d9271e747a2c7bacfcb0832 .git/objects/ab/e196f743dc8da4002ac73ebda12ffb080a8d77 .git/objects/ac/0b91a060aa1d6af1f9164364ad7bd368f6d82b .git/objects/ac/36bb60bd361c99911f404c4a19d988aa4658e1 @@ -441,12 +494,14 @@ test.py .git/objects/b2/2cfe750c285964b738adfbbe730b325fcdc738 .git/objects/b2/4d6f8cd0967bfebf75451742c85f805e81d412 .git/objects/b2/a24e251fe43bc3c2c311ec8515ca181f03d34f +.git/objects/b2/c4db647d314e1808db425347c9f9ff86dc7464 .git/objects/b3/31e4134beb780e674090a8aec286827833eca9 .git/objects/b3/36314c93abcc9f8408f9aa640599b395613591 .git/objects/b3/6cfa7460a9bcbe92499cdaa383068d5a3de811 .git/objects/b3/93603af2d8d0bd3c826a73ab2e1b7c8d9adf8c .git/objects/b3/af83928b01bae7f2a352f48cfc11622dfa147d .git/objects/b3/db3f5f79e281d0fe549027c3b7e00645632cfd +.git/objects/b5/5eca91583fd1bf731321ce8ead9603c014f066 .git/objects/b6/71a0e3cd211798473a46aa99ec3d7c45526969 .git/objects/b6/74fc079dc7c85fa0f3c310f0510230cbd24df8 .git/objects/b6/96137c727cc1d1c7bc2e87a77cb49bc255e9ea @@ -459,6 +514,7 @@ test.py .git/objects/b9/3b0914e0f439146cb6bd525f2d67eb79851de4 .git/objects/b9/56d4867c16bd3127a917df10b223d5bf339079 .git/objects/b9/96509084fa62c47cbf7484dd89e779dca0a1ed +.git/objects/b9/f7e64059ee7fec0fcb58f19047fa7ad4ceee98 .git/objects/bb/aa1fad249c38168673dd9c497c636ff947c5c3 .git/objects/bc/2d0bebf3d3fde9018f4dda56eedc79b4821cab .git/objects/bc/4c5b0b1e29415af5033a13b00d9635779edaea @@ -469,6 +525,8 @@ test.py .git/objects/bd/df85f4bbc22f49c8b2d9f6bbf33804116ece59 .git/objects/bd/f1b88318042c7e7ed787653f6df43fbc02c2d6 .git/objects/be/371c0a6a72d401520bec0970cf222b9777d96d +.git/objects/be/579fecc21e103d189c26d90cc5951474f8260f +.git/objects/be/7175df5e54c2ab2f1956e1a0ae4b45c8a45f00 .git/objects/be/fa1afee8a05a2f0f0636e157473a9b8aa975b3 .git/objects/bf/31096c6b88d2965c3a850b5ac740f65ede19cf .git/objects/c0/8d329b3d387decbc51afc08acf69d526dd53af @@ -476,15 +534,19 @@ test.py .git/objects/c1/3ec728a8ce3b5d79e107f1840a2b7070fe5b43 .git/objects/c1/aebd53bf0a908c4794e2565316b9a006a8cdb9 .git/objects/c2/65788a0584f10e482bfedd6af71d4b364d71c1 +.git/objects/c2/70981f19b9c7ac1211f73d7dac9be07c048958 .git/objects/c2/72eb071b6d7781437c4b1d325f55bfc1ba7512 .git/objects/c2/b95e0be0c795b31ccf22ed2e7c5814c5059e42 .git/objects/c3/1b7f9c385e06e71b14c2f0e798dd3c5a8374ee .git/objects/c3/40f46e1281b17e210e75e517755a49756191bf .git/objects/c3/728cfc9e0e3d6340d952b232d7e7f363134b93 .git/objects/c3/f54b1331eefddbbeacaf77151472e407d019a8 +.git/objects/c4/3b3c19357bdda528013a87d13c336c397cc6db .git/objects/c4/7ac9cf59b77a2adbd86ce188db44f3d113c006 .git/objects/c4/8070271d95c52f081ea272604ecf0d307b49be +.git/objects/c4/967692de8be7bff323e500f5113c902f9718f4 .git/objects/c5/1e1248579b606dcc1a948118189f425f9de532 +.git/objects/c5/a16bda7d18a960b01aeb728d56b8a4d21834f7 .git/objects/c6/01fa395912f7320797b50bfc3abaeb3b3eee93 .git/objects/c6/04bbc200a217b7d11df91d6f0a4d4facbd004f .git/objects/c6/e2e6a99afeb2b5b6970bca72512cbc47d49c0e @@ -498,6 +560,9 @@ test.py .git/objects/c8/98a669305d05e99fbb722d7c4c6a45aac97384 .git/objects/c8/d884ac8fdb81482d16a6b81e824ddd7c9add09 .git/objects/c9/9080ce037ccd139dc2c925cdcda584df0c460d +.git/objects/c9/94406f271d306b3145c2115b7b7cf5ab197667 +.git/objects/ca/c47b18763e8971e5453c2096b8b24990448669 +.git/objects/ca/d7657dfa543e02eca53f1ecc7545c92bc0a550 .git/objects/cb/0a73be29fd28b80bda946a4bc4195956237344 .git/objects/cb/0f6b3fdb1e20e609c6be3cb78ba5723c1a43af .git/objects/cb/92e549bb4f427ec6e61562d78372f7b6af3e0e @@ -510,6 +575,7 @@ test.py .git/objects/ce/0fd3db169f2e29f76371e492876af82078e034 .git/objects/ce/f70e6db6688845ff43636eacb2b54b235d0fcb .git/objects/d1/1ba7f78741bcf4edb9ec1be35012ebeeab590e +.git/objects/d1/6ca6e4defdb1117cc6bd08874c53f4aca84eed .git/objects/d1/ae02cd34b3fddbf741b4dff3d4bfd0ff251a40 .git/objects/d1/b51daf1cfb51be4bd561ef0896dff39363a46d .git/objects/d1/f13e49bddd3ef568c45e300364c711fb4106b4 @@ -521,8 +587,10 @@ test.py .git/objects/d5/72112f511c79b11de51b0cb0526f2644d25ed9 .git/objects/d5/a3436a81fbc6dc09c5d4c71c919f8fee2ae9b2 .git/objects/d6/155c366b9c78eee7335a756d2ce8212b6123c2 +.git/objects/d6/8ac40e1c90b340c8bf80a5b29cc9090106e0c1 .git/objects/d6/8d11ee4d7fccbe820927179d8c74fae97b11c9 .git/objects/d6/e74005ca95da65119eeaeec20e93ded72c3f51 +.git/objects/d6/fc2ae336893e3aa3aaaa7c8b5d866324d009f8 .git/objects/d7/1d8c5021b8f35a4778d4a46c494bad756670b8 .git/objects/d7/9f3742e1370edc0f5d96b5ab9aba1be477969f .git/objects/d7/bc9e5aa1dae731cede0a9352de0ea92baef347 @@ -531,7 +599,9 @@ test.py .git/objects/d8/e9a6f800bdac2b7501a292345c6d1de0f50003 .git/objects/d9/3ac248d9226ca5999dfe163c79f04ce0cc2474 .git/objects/d9/55d40b2a1c0a100c499f0238a5880470f16970 +.git/objects/da/3be555eabe8d9a908fb8d46d37fc493130f147 .git/objects/da/7de80421401bac50b2076bc1878cc78e222baf +.git/objects/da/b23caefabdde660ee85509ccbab349827f3d04 .git/objects/db/bc50bf8c8ffec16472cce91d24fe423e8c67df .git/objects/dc/687d095b87d411a142c7de80397d5759e3a23e .git/objects/dd/32c2ed97746ea1d5749a58de8bff5477b717d2 @@ -546,6 +616,7 @@ test.py .git/objects/e0/56569802265c8c84838e06db447085e43c4dee .git/objects/e0/bd2e48e341013ffc5121c84a27655616faa3bd .git/objects/e0/d16a1f488812958888a0103cd3a43bf35368ee +.git/objects/e1/226f2ca23762581bd98b3bd65c3c8b1859be1b .git/objects/e1/733d16c60c4469e3210a36a0668f4500d35254 .git/objects/e1/ab8cf568740796f921b5de70841b8a907e7a46 .git/objects/e1/df1cfbfcfa4d90f787130d7bc547ddc3ee7822 @@ -553,6 +624,7 @@ test.py .git/objects/e1/ecf195b2b65762d941bb6f76fe3f0360d5565b .git/objects/e2/0a27b768857b0807e250e531331ba16e8a94c3 .git/objects/e2/72a90b1a92949e4f5074aafcabe963ef68e406 +.git/objects/e2/ab4bbbe43c3c0a7f6c1dc3d22f942ffe2475d1 .git/objects/e3/0e352cb2a19991e853d4088c927ed48bb97c94 .git/objects/e3/3b9c7c13ffba0ca3039b11ac5f08bc2d2f08e0 .git/objects/e3/b9ec64634ca52da5479a31d553d5252f77f62d @@ -561,9 +633,11 @@ test.py .git/objects/e5/1e9f3b78d6011037af461abf091aeaf0c94ec7 .git/objects/e5/4887849c32d5308b8a184c4ab1469946a44b8d .git/objects/e5/58183a3176d2c8a5a712a35801363576d743c7 +.git/objects/e5/743bbf5a1ee97295c5ee9779a2aae78d47cc4e .git/objects/e5/922154fc34755eb733f8080ddd0e039bdf7553 .git/objects/e6/7e283bf9a2094c790b1514faec69fe3250ce15 .git/objects/e6/8b36f1b88578c687d33f0d1ad8da9c11b21252 +.git/objects/e6/95328980dc848ff4e6c4876eced3261b172e0d .git/objects/e6/99bae67067fe9e20e92b71533dde6d91edb1a2 .git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 .git/objects/e6/c7745e8924c63b0c855690ea36e028f4f2e405 @@ -580,6 +654,7 @@ test.py .git/objects/eb/f107a583043d4f458b54706f4810f197f1f1fc .git/objects/ec/00523aabe752faba0b576c48df618ec2a63c29 .git/objects/ec/5f822311d6ce3d0cc7eb58d8547e93ba01a160 +.git/objects/ec/7a3418a252e4e7aeaeb3e8361903487a81f718 .git/objects/ed/707ad2216547e687d0ba9466d520f8e9d457c7 .git/objects/ed/816818fed42b5f0433e7da886628b341d67e33 .git/objects/ed/f0d9d11bf81cb5f12f8c28a8220cebd5349b0c @@ -590,6 +665,7 @@ test.py .git/objects/ef/730c723b7e04eedf17fd026e2ea8a26de79791 .git/objects/f0/1e99aecf02b6e0c3846248aa189e4e64e91621 .git/objects/f0/c05efad9077ae34c915d623a832fecfa0d6ea0 +.git/objects/f1/2be7daab3772068cabc2f8121a18d4fd925fa7 .git/objects/f1/393af908379f4cb57d01d8e1a25bf9b3c05797 .git/objects/f1/a28a03c928f16806b767a99ff3703ddedb4d4b .git/objects/f1/b1874ad60c960266221fc55b708cc860326528 @@ -617,6 +693,7 @@ test.py .git/objects/f8/67eaf8e5a1739bb14ca256b93a10cc658a1d47 .git/objects/f9/79b2e3223cfc00b905c10f1e20b83e48d68fea .git/objects/f9/849229a1f10bf74a60e28b686474d148902476 +.git/objects/f9/978c5565770070ef8ca4dffd71d06f0d3bd7b6 .git/objects/f9/e85004565fda693b3d7f5a64756c0c44268eae .git/objects/fa/615695ce4cc65cff1121730f2e756d3590d2cf .git/objects/fb/61bbafdd8be4c2f3c72fb1eb141214289e21de @@ -644,6 +721,7 @@ eggdriver/__init__.py eggdriver/app.py eggdriver/driver.py eggdriver/pypi.py +eggdriver/version.py eggdriver.egg-info/PKG-INFO eggdriver.egg-info/SOURCES.txt eggdriver.egg-info/dependency_links.txt @@ -699,4 +777,7 @@ eggdriver/resources/structures/images.py eggdriver/resources/structures/iterators.py eggdriver/resources/structures/lists.py eggdriver/resources/structures/matrices.py -eggdriver/resources/structures/objects.py \ No newline at end of file +eggdriver/resources/structures/objects.py +eggdriver/resources/video/__init__.py +eggdriver/resources/video/backgrounds.py +eggdriver/resources/video/effects.py \ No newline at end of file diff --git a/eggdriver.egg-info/requires.txt b/eggdriver.egg-info/requires.txt index cb0a73b..1432860 100644 --- a/eggdriver.egg-info/requires.txt +++ b/eggdriver.egg-info/requires.txt @@ -2,6 +2,10 @@ numpy tensorflow keras Colr +opencv-contrib-python +mediapipe +pipwin +easyinstall [bs4] bs4 diff --git a/eggdriver/__init__.py b/eggdriver/__init__.py index f28dbaa..abb556f 100644 --- a/eggdriver/__init__.py +++ b/eggdriver/__init__.py @@ -4,4 +4,5 @@ from eggdriver.nqs import * from eggdriver.resources import * from eggdriver.app import * -from eggdriver.pypi import build \ No newline at end of file +from eggdriver.pypi import * +from eggdriver.version import * \ No newline at end of file diff --git a/eggdriver/__pycache__/__init__.cpython-39.pyc b/eggdriver/__pycache__/__init__.cpython-39.pyc index 55b3da1..2cc60d7 100644 Binary files a/eggdriver/__pycache__/__init__.cpython-39.pyc and b/eggdriver/__pycache__/__init__.cpython-39.pyc differ diff --git a/eggdriver/__pycache__/pypi.cpython-39.pyc b/eggdriver/__pycache__/pypi.cpython-39.pyc index 61f3a0c..a2ec7f2 100644 Binary files a/eggdriver/__pycache__/pypi.cpython-39.pyc and b/eggdriver/__pycache__/pypi.cpython-39.pyc differ diff --git a/eggdriver/__pycache__/version.cpython-39.pyc b/eggdriver/__pycache__/version.cpython-39.pyc new file mode 100644 index 0000000..7a8665b Binary files /dev/null and b/eggdriver/__pycache__/version.cpython-39.pyc differ diff --git a/eggdriver/pypi.py b/eggdriver/pypi.py index da3be55..24493c4 100644 --- a/eggdriver/pypi.py +++ b/eggdriver/pypi.py @@ -1,5 +1,7 @@ from eggdriver.resources import installFromRequests, sysCommand, py +defaultVersion = '0.0.1a' + """ FUNCTION build() Build and upload a pypi package release @@ -10,7 +12,7 @@ py -m twine check dist/* py -m twine upload dist/* """ -def build(autoVersion = True, baseVersion = '0.0.1a'): +def build(autoVersion = True, baseVersion = defaultVersion): """Build and upload a pypi package release""" installFromRequests(["setuptools", "twine", "build"], False) if autoVersion: @@ -26,3 +28,23 @@ def build(autoVersion = True, baseVersion = '0.0.1a'): sysCommand("-m build --wheel") sysCommand("-m twine check dist/*") sysCommand("-m twine upload dist/*") + +def buildEggdriver(autoVersion = True, baseVersion = defaultVersion): + """Build and upload a eggdriver release""" + installFromRequests(["setuptools", "twine", "build"], False) + if autoVersion: + setup = py.getLines("setup") + firstLine = setup[0].split() + v = firstLine[2] + index = len(baseVersion) + 1 + value = int(v[index:-1]) + 1 + v = baseVersion + str(value) + firstLine = [f"v = \"{v}\""] + py.writeLines(firstLine + setup[1:], "setup") + version = py.getLines("eggdriver/version") + firstLine2 = [f"ver = \"{v}\""] + py.writeLines(firstLine2 + version[1:], "eggdriver/version") + sysCommand("-m build --sdist") + sysCommand("-m build --wheel") + sysCommand("-m twine check dist/*") + sysCommand("-m twine upload dist/*") \ No newline at end of file diff --git a/eggdriver/resources/video/__init__.py b/eggdriver/resources/video/__init__.py index d6fc2ae..c994406 100644 --- a/eggdriver/resources/video/__init__.py +++ b/eggdriver/resources/video/__init__.py @@ -18,9 +18,9 @@ def itself(var): def count(value = 100, step = 1): global counterIterator counterIterator += step - print(counterIterator) + print(value - counterIterator) result = counterIterator < value - return counterIterator < value + return result defaultEffect = [(itself, [])] defaultCondition = (count, [100]) diff --git a/eggdriver/resources/video/__pycache__/__init__.cpython-39.pyc b/eggdriver/resources/video/__pycache__/__init__.cpython-39.pyc index 4ef0f98..a480d30 100644 Binary files a/eggdriver/resources/video/__pycache__/__init__.cpython-39.pyc and b/eggdriver/resources/video/__pycache__/__init__.cpython-39.pyc differ diff --git a/eggdriver/version.py b/eggdriver/version.py new file mode 100644 index 0000000..f12be7d --- /dev/null +++ b/eggdriver/version.py @@ -0,0 +1,9 @@ +ver = "0.0.1a10" + +"""Simply the current installed eggdriver version. The version information is +stored in the regular eggdriver module as eggdriver.ver'. Keeping the version +information also available in a separate module allows you to test the +eggdriver version without importing the main eggdriver module. +""" + +__all__ = ["ver"] diff --git a/setup.py b/setup.py index d68ac40..cac47b1 100644 --- a/setup.py +++ b/setup.py @@ -1,4 +1,5 @@ -v = "0.0.1a9" +v = "0.0.1a10" + """A setuptools based setup module. See: https://packaging.python.org/guides/distributing-packages-using-setuptools/ @@ -143,7 +144,7 @@ # # For an analysis of "install_requires" vs pip's requirements files see: # https://packaging.python.org/en/latest/requirements.html - install_requires = ["numpy", "tensorflow", "keras", "Colr"], # Optional + install_requires = ["numpy", "tensorflow", "keras", "Colr", "opencv-contrib-python", "mediapipe", "pipwin", "easyinstall"], # Optional # List additional groups of dependencies here (e.g. development # dependencies). Users will be able to install these using the "extras" diff --git a/test.py b/test.py index 6df828f..c455a2e 100644 --- a/test.py +++ b/test.py @@ -1,14 +1,19 @@ ############################### -wannaBuildRelease = False ## ** Build panel ** +wannaBuildRelease = False ## ** Build panel ** ############################### Set -from eggdriver import build ## wannaBuildRelease = True +import eggdriver as ed ## wannaBuildRelease = True if wannaBuildRelease: ## to build a new release! - build() ## + ed.buildEggdriver() ## ############################### -from eggdriver import Matrix, Vector, WEBCAM, build, changeBackground, blur, solidBackground +ed.sysCommand("-m build --sdist") +ed.sysCommand("-m build --wheel") +ed.sysCommand("-m twine check dist/*") +ed.sysCommand("-m twine upload dist/*") -c = Matrix(""" +print(ed.ver) + +c = ed.Matrix(""" | 1 1 2 3 4 | | 0 1 2 3 4 | | 1 1 2 3 4 | @@ -17,8 +22,8 @@ """, 4, 5) c.display() -a = Vector("[ 1 2 3 4 5 6 30 0 9]") +a = ed.Vector("[ 1 2 3 4 5 6 30 0 9]") a.display() -w = WEBCAM("Emmanuel") -w.default(background_effects= [(blur, [])], effects = [(changeBackground, [solidBackground()])]) \ No newline at end of file +w = ed.WEBCAM("Emmanuel") +w.default(background_effects= [(ed.blur, [])], effects = [(ed.changeBackground, [ed.solidBackground()])]) \ No newline at end of file diff --git a/version.py b/version.py deleted file mode 100644 index 14cc5d5..0000000 --- a/version.py +++ /dev/null @@ -1,64 +0,0 @@ -## pygame - Python Game Library -## Copyright (C) 2000-2003 Pete Shinners -## -## This library is free software; you can redistribute it and/or -## modify it under the terms of the GNU Library General Public -## License as published by the Free Software Foundation; either -## version 2 of the License, or (at your option) any later version. -## -## This library is distributed in the hope that it will be useful, -## but WITHOUT ANY WARRANTY; without even the implied warranty of -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -## Library General Public License for more details. -## -## You should have received a copy of the GNU Library General Public -## License along with this library; if not, write to the Free -## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -## -## Pete Shinners -## pete@shinners.org - -"""Simply the current installed pygame version. The version information is -stored in the regular pygame module as 'pygame.ver'. Keeping the version -information also available in a separate module allows you to test the -pygame version without importing the main pygame module. - -The python version information should always compare greater than any previous -releases. (hmm, until we get to versions > 10) -""" -from pygame.base import get_sdl_version - -class SoftwareVersion(tuple): - """ - A class for storing data about software versions. - """ - __slots__ = () - fields = 'major', 'minor', 'patch' - def __new__(cls, major, minor, patch): - return tuple.__new__(cls, (major, minor, patch)) - def __repr__(self): - fields = ('{}={}'.format(fld, val) for fld, val in zip(self.fields, self)) - return '{}({})'.format(str(self.__class__.__name__), ', '.join(fields)) - def __str__(self): - return '{}.{}.{}'.format(*self) - major = property(lambda self: self[0]) - minor = property(lambda self: self[1]) - patch = property(lambda self: self[2]) - -class PygameVersion(SoftwareVersion): - """ - Pygame Version class. - """ - -class SDLVersion(SoftwareVersion): - """ - SDL Version class. - """ - -_sdl_tuple = get_sdl_version() -SDL = SDLVersion(_sdl_tuple[0], _sdl_tuple[1], _sdl_tuple[2]) -ver = "2.0.1" # pylint: disable=invalid-name -vernum = PygameVersion(2, 0, 1) -rev = "" # pylint: disable=invalid-name - -__all__ = ["SDL", "ver", "vernum", "rev"]