-
Notifications
You must be signed in to change notification settings - Fork 15
Open
Labels
enhancementNew feature or requestNew feature or request
Description
I would add a main class Color (naming TBD), and the whole library would work with it.
eg. distinct_color() returns Color. color_distance() takes 2x Color as argument. The why is that we don't need to create our own helper classes for normalization/color order conversion.
distinctipy.distinct_color().bgr().normalize(256).tuple() # Returns tuple of ints, 0..255, BGR order
# Same as:
distinctipy.distinct_color().cv2() # New proposed method
color = distinctipy.distinct_color()
cv2.putText(image, 'Text', (20,20), font, 1, color.cv2(), thickness, cv2.LINE_AA)
cv2.putText(image, 'Text', (20,40), font, 1, color.get_text_color().cv2(), thickness, cv2.LINE_AA)
Let me know your thoughts, as I (or one of our team members) would like to start working on this.
Thanks, Erik
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request