Illustrated C/C++ source sheets, symbol index, API relationship graph, compiler console and debug trace

LIVE AI / FLEXIBLE SENSING / FLIGHT CONTEXT

Sensoraia API

Live AI and sensing, connected to the flight.
See, listen, inspect and return supported results while airborne.

Loading...
Searching...
No Matches
pangea_survey::Orthorectifier Class Reference

Load a fixed-session source set and render its projected tiles/windows. More...

#include <ortho_map.h>

Data Structures

struct  Impl

Public Member Functions

 Orthorectifier (const MapConfig &config, const std::filesystem::path &csv)
 Validate source CSV rows and derive the requested output grid.
 ~Orthorectifier ()
 Release the render state and its caches.
 Orthorectifier (const Orthorectifier &)=delete
 Disallow copying the owned render state.
Orthorectifier & operator= (const Orthorectifier &)=delete
 Disallow copy assignment of the owned render state.
std::size_t columns () const
 Return output tile columns.
std::size_t rows () const
 Return output tile rows.
std::size_t size () const
 Return total requested map tiles.
std::optional< UtcDateTime > captureUtc () const
 Return the validated common capture UTC target, when present.
std::size_t sourceCount () const
 Return the validated source count without decoding pixels.
std::string sourceFingerprint (const std::function< bool()> &stopped) const
 Hash canonical source paths and current JPEG contents in source order.
void prepareSources (const std::function< bool()> &stopped)
 Prepare shared source rasters/mosaic state before repeated rendering.
OrthoImage render (std::size_t index, const std::function< bool()> &stopped, const std::function< void(double)> &progress={})
 Render one configured output tile.
OrthoImage renderWindow (std::size_t originX, std::size_t originY, int width, int height, const std::function< bool()> &stopped, const std::function< void(double)> &progress={})
 Render an arbitrary bounded window of the configured map grid.

Static Public Member Functions

static void selfTest ()
 Run synthetic orthorectification regression cases.
static std::filesystem::path normalizeSources (const std::filesystem::path &csv, const std::filesystem::path &directory, const std::function< bool()> &stopped, unsigned workers=1, unsigned memoryMiB=128)
 Rectify JPEG sources into working JPEGs and write a new CSV.

Private Attributes

std::unique_ptr< Impl > impl_

Detailed Description

Load a fixed-session source set and render its projected tiles/windows.

The implementation owns bounded decoded-photo and rendered-block caches. Returned images own their pixel/provenance vectors; cancellation is cooperative and throws before an incomplete render can be treated as complete.

Definition at line 98 of file ortho_map.h.

Constructor & Destructor Documentation

◆ Orthorectifier() [1/2]

pangea_survey::Orthorectifier::Orthorectifier ( const MapConfig & config,
const std::filesystem::path & csv )

Validate source CSV rows and derive the requested output grid.

Parameters
[in]configValidated mapping configuration.
[in]csvSource manifest with one consistent fixed-session camera setup.
Exceptions
std::runtime_errorIf any source, calibration, pose, or session contract fails.

Definition at line 463 of file ortho_map.cpp.

◆ ~Orthorectifier()

pangea_survey::Orthorectifier::~Orthorectifier ( )
default

Release the render state and its caches.

Defined out of line where the private implementation is complete.

◆ Orthorectifier() [2/2]

pangea_survey::Orthorectifier::Orthorectifier ( const Orthorectifier & )
delete

Disallow copying the owned render state.

Member Function Documentation

◆ captureUtc()

std::optional< UtcDateTime > pangea_survey::Orthorectifier::captureUtc ( ) const

Return the validated common capture UTC target, when present.

Definition at line 469 of file ortho_map.cpp.

◆ columns()

std::size_t pangea_survey::Orthorectifier::columns ( ) const

Return output tile columns.

Definition at line 466 of file ortho_map.cpp.

◆ normalizeSources()

std::filesystem::path pangea_survey::Orthorectifier::normalizeSources ( const std::filesystem::path & csv,
const std::filesystem::path & directory,
const std::function< bool()> & stopped,
unsigned workers = 1,
unsigned memoryMiB = 128 )
static

Rectify JPEG sources into working JPEGs and write a new CSV.

Parameters
[in]csvOriginal source CSV.
[in]directoryNew directory for normalized JPEGs and CSV.
[in]stoppedCooperative cancellation predicate.
[in]workersUpper bound on independent source-preparation workers.
[in]memoryMiBWorking-memory budget used to reduce the worker count.
Returns
Path to the normalized source CSV.
Exceptions
std::runtime_errorIf source decoding, rectification, or publication fails.

Definition at line 1120 of file ortho_map.cpp.

◆ operator=()

Orthorectifier & pangea_survey::Orthorectifier::operator= ( const Orthorectifier & )
delete

Disallow copy assignment of the owned render state.

◆ prepareSources()

void pangea_survey::Orthorectifier::prepareSources ( const std::function< bool()> & stopped)

Prepare shared source rasters/mosaic state before repeated rendering.

Parameters
[in]stoppedCooperative cancellation predicate.

Definition at line 640 of file ortho_map.cpp.

◆ render()

OrthoImage pangea_survey::Orthorectifier::render ( std::size_t index,
const std::function< bool()> & stopped,
const std::function< void(double)> & progress = {} )

Render one configured output tile.

Parameters
[in]indexRow-major tile index in [0, size()).
[in]stoppedCooperative cancellation predicate.
[in]progressOptional render fraction callback in [0, 1].
Returns
Owned image pixels, confidence classes, and source provenance.
Exceptions
std::runtime_errorIf index is invalid, rendering fails, or canceled.

Definition at line 1293 of file ortho_map.cpp.

◆ renderWindow()

OrthoImage pangea_survey::Orthorectifier::renderWindow ( std::size_t originX,
std::size_t originY,
int width,
int height,
const std::function< bool()> & stopped,
const std::function< void(double)> & progress = {} )

Render an arbitrary bounded window of the configured map grid.

Parameters
[in]originXLeftmost map-grid pixel.
[in]originYTopmost map-grid pixel.
[in]widthWindow width in pixels.
[in]heightWindow height in pixels.
[in]stoppedCooperative cancellation predicate.
[in]progressOptional render fraction callback in [0, 1].
Returns
Owned image and coverage metadata for the requested window.
Exceptions
std::runtime_errorIf bounds exceed the configured area or rendering fails.

Definition at line 1301 of file ortho_map.cpp.

◆ rows()

std::size_t pangea_survey::Orthorectifier::rows ( ) const

Return output tile rows.

Definition at line 467 of file ortho_map.cpp.

◆ selfTest()

void pangea_survey::Orthorectifier::selfTest ( )
static

Run synthetic orthorectification regression cases.

Use controlled source geometry and imagery to check render behavior independently of simulator or camera availability.

Exceptions
std::runtime_errorIf a fixture invariant fails.

Definition at line 1422 of file ortho_map.cpp.

◆ size()

std::size_t pangea_survey::Orthorectifier::size ( ) const

Return total requested map tiles.

Definition at line 468 of file ortho_map.cpp.

◆ sourceCount()

std::size_t pangea_survey::Orthorectifier::sourceCount ( ) const

Return the validated source count without decoding pixels.

Definition at line 470 of file ortho_map.cpp.

◆ sourceFingerprint()

std::string pangea_survey::Orthorectifier::sourceFingerprint ( const std::function< bool()> & stopped) const

Hash canonical source paths and current JPEG contents in source order.

Parameters
[in]stoppedCooperative cancellation predicate.
Returns
Content fingerprint used to detect changes to admitted photographs.

Definition at line 471 of file ortho_map.cpp.

Field Documentation

◆ impl_

std::unique_ptr<Impl> pangea_survey::Orthorectifier::impl_
private

Definition at line 100 of file ortho_map.h.


The documentation for this class was generated from the following files: