commit | 171fd8999fe8fdf04b5e836ff4eb0106ac6d7501 | [log] [tgz] |
---|---|---|
author | Alex Converse <aconverse@google.com> | Wed Oct 14 11:03:14 2015 -0700 |
committer | Alex Converse <aconverse@google.com> | Sat Oct 24 13:38:23 2015 -0700 |
tree | 700ba6f690e476975f4e63d77c1079703965fba1 | |
parent | d162934bdca89b156194732226746993356344ef [diff] |
palette: Replace rand() call with custom LCG. The custom LCG is based on the POSIX recommend constants for a 16-bit rand(). This implementation uses less computation than typical standard library procedures which have been extended for 32-bit support, is guaranteed to be reentrant, and identical everywhere. Change-Id: I3140bbd566f44ab820d131c584a5d4ec6134c5a0 Ref: http://pubs.opengroup.org/onlinepubs/9699919799/functions/rand.html