QGIS API Documentation
2.2.0-Valmiera
|
Go to the source code of this file.
Macros | |
#define | M32(x) (0x80000000 & x) |
#define | L31(x) (0x7FFFFFFF & x) |
#define | ODD(x) (x & 1) |
#define | MD_UINT32_MAX std::numeric_limits<uint32_t>::max() |
#define | UNROLL |
Functions | |
static void | generate_numbers () |
void | seed (uint32_t value) |
uint32_t | rand_u32 () |
int | mt_rand () |
void | mt_srand (unsigned value) |
float | randf_cc () |
float | randf_co () |
float | randf_oo () |
double | randd_cc () |
double | randd_co () |
double | randd_oo () |
uint64_t | rand_u64 () |
Variables | |
static const unsigned | SIZE = 624 |
static const unsigned | PERIOD = 397 |
static const unsigned | DIFF = SIZE - PERIOD |
static uint32_t | MT [SIZE] |
static unsigned | index = 0 |
#define L31 | ( | x | ) | (0x7FFFFFFF & x) |
Definition at line 39 of file mersenne-twister.cpp.
Referenced by generate_numbers().
#define M32 | ( | x | ) | (0x80000000 & x) |
Definition at line 38 of file mersenne-twister.cpp.
Referenced by generate_numbers().
#define MD_UINT32_MAX std::numeric_limits<uint32_t>::max() |
Definition at line 42 of file mersenne-twister.cpp.
Referenced by randd_cc(), randd_co(), randd_oo(), randf_cc(), randf_co(), and randf_oo().
#define ODD | ( | x | ) | (x & 1) |
Definition at line 40 of file mersenne-twister.cpp.
Referenced by generate_numbers().
#define UNROLL |
|
inlinestatic |
int mt_rand | ( | ) |
Definition at line 168 of file mersenne-twister.cpp.
References rand_u32().
Referenced by QgsPointSample::addSamplePoints(), and QgsTransectSample::createSample().
void mt_srand | ( | unsigned | value | ) |
Definition at line 188 of file mersenne-twister.cpp.
References seed().
Referenced by QgsPointSample::createRandomPoints(), and QgsTransectSample::createSample().
uint32_t rand_u32 | ( | ) |
Definition at line 149 of file mersenne-twister.cpp.
References generate_numbers(), index, MT, and SIZE.
Referenced by mt_rand(), rand_u64(), randd_cc(), randd_co(), randd_oo(), randf_cc(), randf_co(), and randf_oo().
uint64_t rand_u64 | ( | ) |
Definition at line 223 of file mersenne-twister.cpp.
References rand_u32().
double randd_cc | ( | ) |
Definition at line 208 of file mersenne-twister.cpp.
References MD_UINT32_MAX, and rand_u32().
double randd_co | ( | ) |
Definition at line 213 of file mersenne-twister.cpp.
References MD_UINT32_MAX, and rand_u32().
double randd_oo | ( | ) |
Definition at line 218 of file mersenne-twister.cpp.
References MD_UINT32_MAX, and rand_u32().
float randf_cc | ( | ) |
Definition at line 193 of file mersenne-twister.cpp.
References MD_UINT32_MAX, and rand_u32().
float randf_co | ( | ) |
Definition at line 198 of file mersenne-twister.cpp.
References MD_UINT32_MAX, and rand_u32().
float randf_oo | ( | ) |
Definition at line 203 of file mersenne-twister.cpp.
References MD_UINT32_MAX, and rand_u32().
void seed | ( | uint32_t | value | ) |
Definition at line 108 of file mersenne-twister.cpp.
References index, MT, and SIZE.
Referenced by mt_srand().
Definition at line 33 of file mersenne-twister.cpp.
Referenced by generate_numbers().
|
static |
Definition at line 36 of file mersenne-twister.cpp.
Referenced by QgsVectorLayerFeatureIterator::FetchJoinInfo::addJoinedAttributesCached(), QgsVectorLayerFeatureIterator::FetchJoinInfo::addJoinedAttributesDirect(), QgsVectorFileWriter::addRendererAttributes(), QgsInterpolator::addVerticesToCache(), QgsGeometry::adjacentVertices(), QgsAttributeTableModel::attributeValueChanged(), QgsRasterDataProvider::block(), QgsSymbolV2::changeSymbolLayer(), QgsGeometry::closestSegmentWithContext(), QgsGeometry::closestVertex(), QgsAttributeEditor::createWidgetFromDef(), QgsSymbolV2::deleteSymbolLayer(), QgsLegendModel::dropMimeData(), QgsAttributeAction::expandAction(), QgsAttributeTableModel::feature(), QgsAttributeTableModel::featureAdded(), QgsExpressionItemSearchProxy::filterAcceptsRow(), QgsComposerTextTable::getHeaderLabels(), QgsComposerMultiFrame::handleFrameRemoval(), QgsExpressionHighlighter::highlightBlock(), QgsAttributeTableModel::idToIndex(), QgsAttributeTableModel::idToIndexList(), QgsAttributeDialog::init(), QgsTINInterpolator::insertData(), QgsOverlayAnalyzer::intersection(), QgsSingleBandGrayRendererWidget::max(), QgsRasterRendererWidget::max(), QgsVectorDataProvider::maximumValue(), QgsVectorLayer::maximumValue(), QgsSingleBandGrayRendererWidget::min(), QgsRasterRendererWidget::min(), QgsVectorDataProvider::minimumValue(), QgsVectorLayer::minimumValue(), QgsFeatureListView::mouseMoveEvent(), QgsFeatureListView::mousePressEvent(), QgsRubberBand::movePoint(), QgsRasterFormatSaveOptionsWidget::on_mProfileDeleteButton_clicked(), QgsVectorLayer::prepareLabelingAndDiagrams(), QgsGml::QgsGml(), rand_u32(), QgsVectorLayer::readSymbology(), QgsRasterBlock::readValue(), QgsComposerAttributeTable::readXML(), QgsRubberBand::removePoint(), QgsAttributeTableView::repaintRequested(), QgsFeatureListView::repaintRequested(), QgsExpression::replaceExpressionText(), seed(), QgsSingleBandGrayRendererWidget::selectedBand(), QgsRasterRendererWidget::selectedBand(), QgsFeatureSelectionModel::selectFeatures(), QgsAttributeTableView::selectRow(), QgsLinearlyInterpolatedDiagramRenderer::setClassificationAttribute(), QgsRasterBlock::setColor(), QgsPalettedRendererWidget::setFromRenderer(), QgsSingleBandGrayRendererWidget::setMax(), QgsRasterRendererWidget::setMax(), QgsSingleBandGrayRendererWidget::setMin(), QgsRasterRendererWidget::setMin(), QgsScaleComboBox::showPopup(), QgsGeometry::transform(), QgsGeometry::translate(), QgsVectorLayerUndoCommandAddAttribute::undo(), QgsVectorLayer::uniqueValues(), QgsBlendModeComboBox::updateModes(), QgsRasterBlock::writeValue(), QgsCubicRasterResampler::xDerivativeMatrix(), and QgsCubicRasterResampler::yDerivativeMatrix().
|
static |
Definition at line 35 of file mersenne-twister.cpp.
Referenced by generate_numbers(), rand_u32(), and seed().
|
static |
Definition at line 32 of file mersenne-twister.cpp.
Referenced by generate_numbers().
|
static |
Definition at line 31 of file mersenne-twister.cpp.
Referenced by generate_numbers(), rand_u32(), and seed().