The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information.... |
Home BasePack DStruct Class TBitFld Methods SelectRandomBit | |||||||
See also: RandomFill, FirstTrueBit | |||||||
SelectRandomBit |
|||||||
The function SelectRandomBit randomly selects a bit showing the state defined by PreCondition. If PreCondition is TRUE the random selection is performed among the TRUE bits, else one of the FALSE bits is selected. The function returns the index of the selected bit (0 to Size) or a value of -1 if no bit of the given precondition is available.
|