Functions to create, modify, use, and destroy randomEngine objects.
More...
Functions to create, modify, use, and destroy randomEngine objects.
A af::randomEngine object can be used to generate psuedo random numbers using various types of random number generation algorithms defined by af::randomEngineType.
◆ af_create_random_engine()
C Interface to create a random engine.
- Parameters
-
[out] | engine | pointer to the returned random engine object |
[in] | rtype | type of the random number generator |
[in] | seed | initializing seed of the random number generator |
- Returns
- AF_SUCCESS, if function returns successfully, else an af_err code is given
◆ af_random_engine_get_seed()
C Interface to get the seed of a random engine.
- Parameters
-
[out] | seed | pointer to the returned seed |
[in] | engine | random engine object |
- Returns
- AF_SUCCESS, if function returns successfully, else an af_err code is given
◆ af_random_engine_get_type()
C Interface to get random engine type.
- Parameters
-
[out] | rtype | type of the random number generator |
[in] | engine | random engine object |
- Returns
- AF_SUCCESS, if function returns successfully, else an af_err code is given
◆ af_random_engine_set_seed()
C Interface to set the seed of a random engine.
- Parameters
-
[out] | engine | pointer to the returned random engine object |
[in] | seed | initializing seed of the random number generator |
- Returns
- AF_SUCCESS, if function returns successfully, else an af_err code is given
◆ af_random_engine_set_type()
C Interface to change random engine type.
- Parameters
-
[in] | engine | random engine object |
[in] | rtype | type of the random number generator |
- Returns
- AF_SUCCESS, if function returns successfully, else an af_err code is given
◆ af_release_random_engine()
C Interface to release a random engine.
- Parameters
-
[in] | engine | random engine object |
- Returns
- AF_SUCCESS, if function returns successfully, else an af_err code is given
◆ af_retain_random_engine()
C Interface to retain a random engine.
- Parameters
-
[out] | out | pointer to the returned random engine object |
[in] | engine | random engine object |
- Returns
- AF_SUCCESS, if function returns successfully, else an af_err code is given