mirror of https://github.com/Askill/SurvBot.git
Update motion_detector.py
This commit is contained in:
parent
6b374aa5bd
commit
30ffeb788f
|
|
@ -12,20 +12,6 @@ import cv2
|
||||||
import com
|
import com
|
||||||
import config
|
import config
|
||||||
|
|
||||||
|
|
||||||
def increase_brightness(img, value=30):
|
|
||||||
hsv = cv2.cvtColor(img, cv2.COLOR_BGR2HSV)
|
|
||||||
h, s, v = cv2.split(hsv)
|
|
||||||
|
|
||||||
lim = 255 - value
|
|
||||||
v[v > lim] = 255
|
|
||||||
v[v <= lim] += value
|
|
||||||
|
|
||||||
final_hsv = cv2.merge((h, s, v))
|
|
||||||
img = cv2.cvtColor(final_hsv, cv2.COLOR_HSV2BGR)
|
|
||||||
|
|
||||||
return img
|
|
||||||
|
|
||||||
def compare():
|
def compare():
|
||||||
try:
|
try:
|
||||||
url = config.stream
|
url = config.stream
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue