First, the output of the function is still a double, though internally it uses a 32-bit shift register (unsigned int). To alter it, you would first need to change that uPNRegister variable from UINT to uint64_t to guarantee you have a 64-bit register.
Next, see the Datorro paper which is the original source of that particular PN generator here:
Go to table 9 and look at the last column, last row for 64-bit shift registers. It contains the formula for XOR-ing the bits from the 64-bit shift register. Alter the function doPNSequence( ) accordingly. Then in the conversion statement, you'd divide by 2^64 rather then 2^32, casting the variables as doubles rather than floats. You may need to experiment with the division by 16.0 in the last part of that function to get your output on the desired range of [-1.0, +1.0]. The paper has all the details you need to make the PN generator with any sized shift register.
Most Users Ever Online: 152
Currently Browsing this Page:
Guest Posters: 1
Newest Members:Jas, Rowan, sojourn, fabhenr, rg1, Niklas, Wutru, Tim Campbell, Danny Jonel, Valentin
Moderators: W Pirkle: 573
Administrators: Tom: 74, JD Young: 80, Will Pirkle: 0, W Pirkle: 573, VariableCook: 3