Ejemplo n.º 1
0
fcppt::random::uniform<T, Generator>::uniform(
	range_type const &_range,
	Generator _gen
)
:
	variate_(
		_gen,
		distribution(
			_range.first(),
			_range.last()
		)
	)
{}
Ejemplo n.º 2
0
fcppt::random::uniform<T, Generator>::uniform(
	range_type const &_range
)
:
	variate_(
		typename boost::remove_reference<Generator>::type(
			static_cast<
				typename boost::remove_reference<Generator>::type::result_type
			>(
				fcppt::chrono::high_resolution_clock::now().time_since_epoch().count()
			)
		),
		distribution(
			_range.first(),
			_range.last()
		)
	)
{}