\brief CarsCounting::AddToHeatMap
| 378 | /// \brief CarsCounting::AddToHeatMap |
| 379 | /// |
| 380 | void CarsCounting::AddToHeatMap(const cv::Rect& rect) |
| 381 | { |
| 382 | if (m_heatMap.empty()) |
| 383 | return; |
| 384 | |
| 385 | constexpr float w = 0.001f; |
| 386 | for (int y = 0; y < rect.height; ++y) |
| 387 | { |
| 388 | float* heatPtr = m_heatMap.ptr<float>(rect.y + y) + rect.x; |
| 389 | for (int x = 0; x < rect.width; ++x) |
| 390 | { |
| 391 | heatPtr[x] += w; |
| 392 | } |
| 393 | } |
| 394 | } |
| 395 | |
| 396 | /// |
| 397 | /// \brief CarsCounting::ReadGeobindings |