KlassenKlassenKlassenKlassen | | | | Operatoren

gen_grid_rectification_mapT_gen_grid_rectification_mapGenGridRectificationMapgen_grid_rectification_mapGenGridRectificationMapGenGridRectificationMap (Operator)

Name

gen_grid_rectification_mapT_gen_grid_rectification_mapGenGridRectificationMapgen_grid_rectification_mapGenGridRectificationMapGenGridRectificationMap — Berechnet die Abbildung vom verzerrten ins entzerrte Bild, aufbauend auf den Punkten in einem regulären Gitter.

Signatur

gen_grid_rectification_map(Image, ConnectingLines : Map, Meshes : GridSpacing, Rotation, Row, Column, MapType : )

Herror T_gen_grid_rectification_map(const Hobject Image, const Hobject ConnectingLines, Hobject* Map, Hobject* Meshes, const Htuple GridSpacing, const Htuple Rotation, const Htuple Row, const Htuple Column, const Htuple MapType)

Herror gen_grid_rectification_map(Hobject Image, Hobject ConnectingLines, Hobject* Map, Hobject* Meshes, const HTuple& GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HTuple& MapType)

HImage HImage::GenGridRectificationMap(const HXLDArray& ConnectingLines, HXLDArray* Meshes, const HTuple& GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HTuple& MapType) const

void GenGridRectificationMap(const HObject& Image, const HObject& ConnectingLines, HObject* Map, HObject* Meshes, const HTuple& GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HTuple& MapType)

HImage HImage::GenGridRectificationMap(const HXLD& ConnectingLines, HXLD* Meshes, Hlong GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HImage::GenGridRectificationMap(const HXLD& ConnectingLines, HXLD* Meshes, Hlong GridSpacing, const HString& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HImage::GenGridRectificationMap(const HXLD& ConnectingLines, HXLD* Meshes, Hlong GridSpacing, const char* Rotation, const HTuple& Row, const HTuple& Column, const char* MapType) const

HImage HXLD::GenGridRectificationMap(const HImage& Image, HXLD* Meshes, Hlong GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLD::GenGridRectificationMap(const HImage& Image, HXLD* Meshes, Hlong GridSpacing, const HString& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLD::GenGridRectificationMap(const HImage& Image, HXLD* Meshes, Hlong GridSpacing, const char* Rotation, const HTuple& Row, const HTuple& Column, const char* MapType) const

HImage HXLDCont::GenGridRectificationMap(const HImage& Image, HXLDCont* Meshes, Hlong GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDCont::GenGridRectificationMap(const HImage& Image, HXLDCont* Meshes, Hlong GridSpacing, const HString& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDCont::GenGridRectificationMap(const HImage& Image, HXLDCont* Meshes, Hlong GridSpacing, const char* Rotation, const HTuple& Row, const HTuple& Column, const char* MapType) const

HImage HXLDPoly::GenGridRectificationMap(const HImage& Image, HXLDPoly* Meshes, Hlong GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDPoly::GenGridRectificationMap(const HImage& Image, HXLDPoly* Meshes, Hlong GridSpacing, const HString& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDPoly::GenGridRectificationMap(const HImage& Image, HXLDPoly* Meshes, Hlong GridSpacing, const char* Rotation, const HTuple& Row, const HTuple& Column, const char* MapType) const

HImage HXLDPara::GenGridRectificationMap(const HImage& Image, HXLDPara* Meshes, Hlong GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDPara::GenGridRectificationMap(const HImage& Image, HXLDPara* Meshes, Hlong GridSpacing, const HString& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDPara::GenGridRectificationMap(const HImage& Image, HXLDPara* Meshes, Hlong GridSpacing, const char* Rotation, const HTuple& Row, const HTuple& Column, const char* MapType) const

HImage HXLDModPara::GenGridRectificationMap(const HImage& Image, HXLDModPara* Meshes, Hlong GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDModPara::GenGridRectificationMap(const HImage& Image, HXLDModPara* Meshes, Hlong GridSpacing, const HString& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDModPara::GenGridRectificationMap(const HImage& Image, HXLDModPara* Meshes, Hlong GridSpacing, const char* Rotation, const HTuple& Row, const HTuple& Column, const char* MapType) const

HImage HXLDExtPara::GenGridRectificationMap(const HImage& Image, HXLDExtPara* Meshes, Hlong GridSpacing, const HTuple& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDExtPara::GenGridRectificationMap(const HImage& Image, HXLDExtPara* Meshes, Hlong GridSpacing, const HString& Rotation, const HTuple& Row, const HTuple& Column, const HString& MapType) const

HImage HXLDExtPara::GenGridRectificationMap(const HImage& Image, HXLDExtPara* Meshes, Hlong GridSpacing, const char* Rotation, const HTuple& Row, const HTuple& Column, const char* MapType) const

void HOperatorSetX.GenGridRectificationMap(
[in] IHUntypedObjectX* Image, [in] IHUntypedObjectX* ConnectingLines, [out] IHUntypedObjectX*Map, [out] IHUntypedObjectX*Meshes, [in] VARIANT GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] VARIANT MapType)

IHImageX* HImageX.GenGridRectificationMap(
[in] IHXLDX* ConnectingLines, [out] IHXLDX*Meshes, [in] Hlong GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] BSTR MapType)

IHImageX* HXLDX.GenGridRectificationMap(
[in] IHImageX* Image, [out] IHXLDX*Meshes, [in] Hlong GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] BSTR MapType)

IHImageX* HXLDContX.GenGridRectificationMap(
[in] IHImageX* Image, [out] IHXLDX*Meshes, [in] Hlong GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] BSTR MapType)

IHImageX* HXLDPolyX.GenGridRectificationMap(
[in] IHImageX* Image, [out] IHXLDX*Meshes, [in] Hlong GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] BSTR MapType)

IHImageX* HXLDParaX.GenGridRectificationMap(
[in] IHImageX* Image, [out] IHXLDX*Meshes, [in] Hlong GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] BSTR MapType)

IHImageX* HXLDModParaX.GenGridRectificationMap(
[in] IHImageX* Image, [out] IHXLDX*Meshes, [in] Hlong GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] BSTR MapType)

IHImageX* HXLDExtParaX.GenGridRectificationMap(
[in] IHImageX* Image, [out] IHXLDX*Meshes, [in] Hlong GridSpacing, [in] VARIANT Rotation, [in] VARIANT Row, [in] VARIANT Column, [in] BSTR MapType)

static void HOperatorSet.GenGridRectificationMap(HObject image, HObject connectingLines, out HObject map, out HObject meshes, HTuple gridSpacing, HTuple rotation, HTuple row, HTuple column, HTuple mapType)

HImage HImage.GenGridRectificationMap(HXLD connectingLines, out HXLD meshes, int gridSpacing, HTuple rotation, HTuple row, HTuple column, string mapType)

HImage HImage.GenGridRectificationMap(HXLD connectingLines, out HXLD meshes, int gridSpacing, string rotation, HTuple row, HTuple column, string mapType)

HImage HXLD.GenGridRectificationMap(HImage image, out HXLD meshes, int gridSpacing, HTuple rotation, HTuple row, HTuple column, string mapType)

HImage HXLD.GenGridRectificationMap(HImage image, out HXLD meshes, int gridSpacing, string rotation, HTuple row, HTuple column, string mapType)

HImage HXLDCont.GenGridRectificationMap(HImage image, out HXLDCont meshes, int gridSpacing, HTuple rotation, HTuple row, HTuple column, string mapType)

HImage HXLDCont.GenGridRectificationMap(HImage image, out HXLDCont meshes, int gridSpacing, string rotation, HTuple row, HTuple column, string mapType)

HImage HXLDPoly.GenGridRectificationMap(HImage image, out HXLDPoly meshes, int gridSpacing, HTuple rotation, HTuple row, HTuple column, string mapType)

HImage HXLDPoly.GenGridRectificationMap(HImage image, out HXLDPoly meshes, int gridSpacing, string rotation, HTuple row, HTuple column, string mapType)

HImage HXLDPara.GenGridRectificationMap(HImage image, out HXLDPara meshes, int gridSpacing, HTuple rotation, HTuple row, HTuple column, string mapType)

HImage HXLDPara.GenGridRectificationMap(HImage image, out HXLDPara meshes, int gridSpacing, string rotation, HTuple row, HTuple column, string mapType)

HImage HXLDModPara.GenGridRectificationMap(HImage image, out HXLDModPara meshes, int gridSpacing, HTuple rotation, HTuple row, HTuple column, string mapType)

HImage HXLDModPara.GenGridRectificationMap(HImage image, out HXLDModPara meshes, int gridSpacing, string rotation, HTuple row, HTuple column, string mapType)

HImage HXLDExtPara.GenGridRectificationMap(HImage image, out HXLDExtPara meshes, int gridSpacing, HTuple rotation, HTuple row, HTuple column, string mapType)

HImage HXLDExtPara.GenGridRectificationMap(HImage image, out HXLDExtPara meshes, int gridSpacing, string rotation, HTuple row, HTuple column, string mapType)

Beschreibung

gen_grid_rectification_mapgen_grid_rectification_mapGenGridRectificationMapgen_grid_rectification_mapGenGridRectificationMapGenGridRectificationMap berechnet die Abbildung der (typischerweise mit saddle_points_sub_pixsaddle_points_sub_pixSaddlePointsSubPixsaddle_points_sub_pixSaddlePointsSubPixSaddlePointsSubPix) gefundenen Gitterpunkte (RowRowRowRowRowrow,ColumnColumnColumnColumnColumncolumn) im verzerrten Bild ImageImageImageImageImageimage in die entsprechenden Gitterpunkte im idealen regelmäßigen Punktgitter. Dazu werden aus den Gitterpunkten (RowRowRowRowRowrow,ColumnColumnColumnColumnColumncolumn) und den (von connect_grid_pointsconnect_grid_pointsConnectGridPointsconnect_grid_pointsConnectGridPointsConnectGridPoints gefundenen) Verbindungslinien ConnectingLinesConnectingLinesConnectingLinesConnectingLinesConnectingLinesconnectingLines alle Pfade gebildet, die von ihrem Ausgangspunkt über genau vier verschiedene Verbindungslinien zum Ausgangspunkt zurück führen. Sofern die Gitterpunkte (RowRowRowRowRowrow, ColumnColumnColumnColumnColumncolumn) und Verbindungslinien ConnectingLinesConnectingLinesConnectingLinesConnectingLinesConnectingLinesconnectingLines sinnvolle Eingaben waren, entspricht jede solche 'Masche' genau einem Feld im Entzerrungsgitter. Danach werden die gefundenen Maschen zum gesuchten Punktgitter zusammengesetzt. Das Punktgitter wird, je nachdem, welchen Wert RotationRotationRotationRotationRotationrotation hat, um 0, 90, 180 oder 270 Grad gedreht. Dabei ist zu beachten, dass das gefundene Punktgitter nicht notwendigerweise eine korrekte Ausrichtung aufweisen muss. Wird in RotationRotationRotationRotationRotationrotation 'auto'"auto""auto""auto""auto""auto" übergeben, so wird das Punktgitter so gedreht, dass im entzerrten Bild die schwarze der beiden kreisförmigen Marken im Entzerrungsgitter links neben der weißen zu liegen kommt. Abschließend wird die Abbildung MapMapMapMapMapmap vom verzerrten ins entzerrte Bild durch Interpolation zwischen den Gitterpunkten berechnet. Jede Gitterzelle, für die die Koordinaten (RowRowRowRowRowrow,ColumnColumnColumnColumnColumncolumn) aller vier Eckpunkte im verzerrten Bild bekannt sind, wird durch Interpolation auf ein Quadrat von GridSpacingGridSpacingGridSpacingGridSpacingGridSpacinggridSpacing x GridSpacingGridSpacingGridSpacingGridSpacingGridSpacinggridSpacing Pixeln abgebildet.

Der Parameter MapTypeMapTypeMapTypeMapTypeMapTypemapType gibt an, in welchem Typ die Abbildungsvorschrift gespeichert werden soll. Wurde die bilineare Interpolation ('bilinear'"bilinear""bilinear""bilinear""bilinear""bilinear") gewählt, so besteht MapMapMapMapMapmap aus einem Bild mit fünf Kanälen. Der erste Kanal enthält für jedes Pixel des Ergebnisbildes die linearen Koordinaten desjenigen Pixels des Eingabebildes, welches links oberhalb von den transformierten Koordinaten liegt. Die übrigen vier Kanäle enthalten die Gewichte der einzelnen vier Nachbarpixel der transformierten Koordinaten für die bilineare Interpolation in folgender Reihenfolge:

2 3
4 5

Der zweite Kanal z.B. enthält die Gewichte der Pixel, die links oberhalb der transformierten Koordinaten liegen. Wurde 'coord_map_sub_pix'"coord_map_sub_pix""coord_map_sub_pix""coord_map_sub_pix""coord_map_sub_pix""coord_map_sub_pix" gewählt, besteht MapMapMapMapMapmap aus einem Vektorfeld, welches für jedes Pixel des Ergebnisbildes die subpixelgenauen Koordinaten im Eingabebild enthält.

gen_grid_rectification_mapgen_grid_rectification_mapGenGridRectificationMapgen_grid_rectification_mapGenGridRectificationMapGenGridRectificationMap liefert auch die gefundenen Maschen, als XLD-Konturen, in MeshesMeshesMeshesMeshesMeshesmeshes zurück. Im Gegensatz zu gen_arbitrary_distortion_mapgen_arbitrary_distortion_mapGenArbitraryDistortionMapgen_arbitrary_distortion_mapGenArbitraryDistortionMapGenArbitraryDistortionMap werden gen_grid_rectification_mapgen_grid_rectification_mapGenGridRectificationMapgen_grid_rectification_mapGenGridRectificationMapGenGridRectificationMap und die Vorgängerfunktionen verwendet, falls die Koordinaten (RowRowRowRowRowrow,ColumnColumnColumnColumnColumncolumn) der Gitterpunkte im verzerrten Bild weder bekannt sind noch aus den Bildinhalten gewonnen werden können.

Wenn die erzeugte Abbildung in einem anderen Programm wiederverwendet werden soll, kann man sie mit dem Operator write_imagewrite_imageWriteImagewrite_imageWriteImageWriteImage als Mehrkanalbild abspeichern (Format: 'tiff'"tiff""tiff""tiff""tiff""tiff").

Achtung

Jede Eingabekontur ConnectingLinesConnectingLinesConnectingLinesConnectingLinesConnectingLinesconnectingLines muss, so wie bei connect_grid_pointsconnect_grid_pointsConnectGridPointsconnect_grid_pointsConnectGridPointsConnectGridPoints beschrieben, das globale Attribut 'bright_dark'"bright_dark""bright_dark""bright_dark""bright_dark""bright_dark" besitzen!

Parallelisierung

Parameter

ImageImageImageImageImageimage (input_object)  singlechannelimage objectHImageHImageHImageHImageXHobject (byte / uint2)

Eingabebild.

ConnectingLinesConnectingLinesConnectingLinesConnectingLinesConnectingLinesconnectingLines (input_object)  xld-array objectHXLDHXLDHXLDArrayHXLDXHobject

Eingabekonturen.

MapMapMapMapMapmap (output_object)  multichannel-image objectHImageHImageHImageHImageXHobject * (int4 / uint2 / vector_field)

Bild mit Transformationsdaten.

MeshesMeshesMeshesMeshesMeshesmeshes (output_object)  xld-array objectHXLDHXLDHXLDArrayHXLDXHobject *

Ausgabekonturen.

GridSpacingGridSpacingGridSpacingGridSpacingGridSpacinggridSpacing (input_control)  integer HTupleHTupleHTupleVARIANTHtuple (integer) (int / long) (Hlong) (Hlong) (Hlong) (Hlong)

Abstand der Gitterpunkte im entzerrten Bild.

Restriktion: GridSpacing > 0

RotationRotationRotationRotationRotationrotation (input_control)  string HTupleHTupleHTupleVARIANTHtuple (string / integer) (string / int / long) (HString / Hlong) (char* / Hlong) (BSTR / Hlong) (char* / Hlong)

Drehung, die am Punktgitter vogenommen wird.

Defaultwert: 'auto' "auto" "auto" "auto" "auto" "auto"

Werteliste: 0, 90, 180, 270, 'auto'"auto""auto""auto""auto""auto"

RowRowRowRowRowrow (input_control)  point.y-array HTupleHTupleHTupleVARIANTHtuple (real) (double) (double) (double) (double) (double)

Zeilenkoordinaten der Gitterpunkte.

ColumnColumnColumnColumnColumncolumn (input_control)  point.x-array HTupleHTupleHTupleVARIANTHtuple (real) (double) (double) (double) (double) (double)

Spaltenkoordinaten der Gitterpunkte.

Restriktion: number(Column) == number(Row)

MapTypeMapTypeMapTypeMapTypeMapTypemapType (input_control)  string HTupleHTupleHTupleVARIANTHtuple (string) (string) (HString) (char*) (BSTR) (char*)

Typ der Transformationsdaten.

Defaultwert: 'bilinear' "bilinear" "bilinear" "bilinear" "bilinear" "bilinear"

Werteliste: 'bilinear'"bilinear""bilinear""bilinear""bilinear""bilinear", 'coord_map_sub_pix'"coord_map_sub_pix""coord_map_sub_pix""coord_map_sub_pix""coord_map_sub_pix""coord_map_sub_pix"

Ergebnis

Sind die Parameterwerte korrekt, dann liefert gen_grid_rectification_mapgen_grid_rectification_mapGenGridRectificationMapgen_grid_rectification_mapGenGridRectificationMapGenGridRectificationMap den Wert 2 (H_MSG_TRUE). Gegebenenfalls wird eine Fehlerbehandlung durchgeführt.

Vorgänger

connect_grid_pointsconnect_grid_pointsConnectGridPointsconnect_grid_pointsConnectGridPointsConnectGridPoints

Nachfolger

map_imagemap_imageMapImagemap_imageMapImageMapImage

Siehe auch

gen_arbitrary_distortion_mapgen_arbitrary_distortion_mapGenArbitraryDistortionMapgen_arbitrary_distortion_mapGenArbitraryDistortionMapGenArbitraryDistortionMap

Modul

Calibration


KlassenKlassenKlassenKlassen | | | | Operatoren