mirror of
https://github.com/moparisthebest/Simba
synced 2024-11-25 02:32:19 -05:00
pyMML: Fix issue with color.
This commit is contained in:
parent
8e0e86e7d6
commit
285be4b6ed
@ -98,9 +98,11 @@ class Color(object):
|
|||||||
ret = self._mc.dll.find_color_spiral(self._cli, byref(x), byref(y),
|
ret = self._mc.dll.find_color_spiral(self._cli, byref(x), byref(y),
|
||||||
col, *box)
|
col, *box)
|
||||||
else:
|
else:
|
||||||
ret = self._mc.dll.find_color_spiral_tolerance(self._cli, byref(x),
|
pass
|
||||||
byref(y), col, *box,
|
# FIXME
|
||||||
tol)
|
# ret = self._mc.dll.find_color_spiral_tolerance(self._cli, byref(x),
|
||||||
|
# byref(y), col, *box,
|
||||||
|
# tol)
|
||||||
if ret is RESULT_OK:
|
if ret is RESULT_OK:
|
||||||
return (x, y)
|
return (x, y)
|
||||||
elif ret is RESULT_ERROR:
|
elif ret is RESULT_ERROR:
|
||||||
@ -115,12 +117,16 @@ class Color(object):
|
|||||||
"""
|
"""
|
||||||
x, y = (c_int(-1), c_int(-1))
|
x, y = (c_int(-1), c_int(-1))
|
||||||
if tol is 0:
|
if tol is 0:
|
||||||
ret = self._mc.dll.find_colored_area(self._cli, byref(x), byref(y),
|
pass
|
||||||
col, *box, min_a)
|
# FIXME
|
||||||
|
# ret = self._mc.dll.find_colored_area(self._cli, byref(x), byref(y),
|
||||||
|
# col, *box, min_a)
|
||||||
else:
|
else:
|
||||||
ret = self._mc.dll.find_colored_area_tolerance(self._cli, byref(x),
|
pass
|
||||||
byref(y), col, *box,
|
# FIXME
|
||||||
min_a, tol)
|
# ret = self._mc.dll.find_colored_area_tolerance(self._cli, byref(x),
|
||||||
|
# byref(y), col, *box,
|
||||||
|
# min_a, tol)
|
||||||
if ret is RESULT_OK:
|
if ret is RESULT_OK:
|
||||||
return (x, y)
|
return (x, y)
|
||||||
elif ret is RESULT_ERROR:
|
elif ret is RESULT_ERROR:
|
||||||
@ -136,8 +142,10 @@ class Color(object):
|
|||||||
if tol is 0:
|
if tol is 0:
|
||||||
ret = self._mc.dll.count_color(self._cli, count, col, *box)
|
ret = self._mc.dll.count_color(self._cli, count, col, *box)
|
||||||
else:
|
else:
|
||||||
ret = self._mc.dll.count_color_tolerance(self._cli, count, col,
|
pass
|
||||||
*box, tol)
|
# FIXME
|
||||||
|
# ret = self._mc.dll.count_color_tolerance(self._cli, count, col,
|
||||||
|
# *box, tol)
|
||||||
if ret is RESULT_OK:
|
if ret is RESULT_OK:
|
||||||
return count
|
return count
|
||||||
elif ret is RESULT_ERROR:
|
elif ret is RESULT_ERROR:
|
||||||
|
Loading…
Reference in New Issue
Block a user