Use SkBits2Float in SkRandom
https://codereview.appspot.com/7266044/ git-svn-id: http://skia.googlecode.com/svn/trunk@7648 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
parent
fe1b536bb7
commit
753a362cfc
@ -197,7 +197,7 @@ public:
|
||||
*/
|
||||
float nextF() {
|
||||
unsigned int floatint = 0x3f800000 | (this->nextU() >> 9);
|
||||
float f = *SkTCast<float*>(&floatint) - 1.0f;
|
||||
float f = SkBits2Float(floatint) - 1.0f;
|
||||
return f;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user