[Ffmpeg-devel] Random single bits using av_random() ?

Michel Bardiaux mbardiaux
Mon Mar 12 14:56:07 CET 2007


Ian Braithwaite wrote:
> Hi,
> 
> 
> Could anyone tell me the best way to extract single random bits
> from av_random()?
> MSB, LSB, all 32 bits - one at a time ... ?
> 
singlebit = (av_random(&state)<0x80000000)

HaND,
-- 
Michel Bardiaux
R&D Director
T +32 [0] 2 790 29 41
F +32 [0] 2 790 29 02
E mailto:mbardiaux at mediaxim.be

Mediaxim NV/SA
Vorstlaan 191 Boulevard du Souverain
Brussel 1160 Bruxelles
http://www.mediaxim.com/




More information about the ffmpeg-devel mailing list