ios - Detect if UIImage is light or dark -


i need create smart detector can detect if uiimage light or dark, can on uilabel textcolor in opposite color, either black or white.

can done in few lines or need hardcore coreimage manoeuvre?

thanks!

seeing if image "dark" or "light" won't work generally. part end putting text on have both light , dark parts if overall image might considered 1 or other.

a common solution adding text random picture add partially transparent black background white text (or partially transparent white background black text).


Comments

Popular posts from this blog

powershell Start-Process exit code -1073741502 when used with Credential from a windows service environment -

twig - Using Twigbridge in a Laravel 5.1 Package -

c# - LINQ join Entities from HashSet's, Join vs Dictionary vs HashSet performance -