Created
September 26, 2020 13:28
-
-
Save matthewmorrone/445cef4548df999bae535aef80733582 to your computer and use it in GitHub Desktop.
I don't actually know how these matrices work
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| String bg = sharedPreferences.getString("bg", "#FF000000"); | |
| int[] bgc = Util.fromColor(bg); | |
| float[] sCustomColorArray = { | |
| 1.0f, 0, 0, 0, bgc[1], // red | |
| 0, 1.0f, 0, 0, bgc[2], // green | |
| 0, 0, 1.0f, 0, bgc[3], // blue | |
| 0, 0, 0, 1.0f, bgc[0] // alpha | |
| }; | |
| mDefaultFilter = sCustomColorArray; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment