KlassenKlassenKlassenKlassen | | | | Operatoren

read_matrixread_matrixReadMatrixread_matrixReadMatrixReadMatrix (Operator)

Name

read_matrixread_matrixReadMatrixread_matrixReadMatrixReadMatrix — Einlesen eine Matrix von einer Datei.

Signatur

read_matrix( : : FileName : MatrixID)

Herror read_matrix(const char* FileName, Hlong* MatrixID)

Herror T_read_matrix(const Htuple FileName, Htuple* MatrixID)

Herror read_matrix(const HTuple& FileName, Hlong* MatrixID)

void HMatrix::ReadMatrix(const HTuple& FileName)

void ReadMatrix(const HTuple& FileName, HTuple* MatrixID)

void HMatrix::HMatrix(const HString& FileName)

void HMatrix::HMatrix(const char* FileName)

void HMatrix::ReadMatrix(const HString& FileName)

void HMatrix::ReadMatrix(const char* FileName)

void HOperatorSetX.ReadMatrix(
[in] VARIANT FileName, [out] VARIANT* MatrixID)

void HMatrixX.ReadMatrix([in] BSTR FileName)

static void HOperatorSet.ReadMatrix(HTuple fileName, out HTuple matrixID)

public HMatrix(string fileName)

void HMatrix.ReadMatrix(string fileName)

Beschreibung

read_matrixread_matrixReadMatrixread_matrixReadMatrixReadMatrix liest eine Matrix, die mit write_matrixwrite_matrixWriteMatrixwrite_matrixWriteMatrixWriteMatrix geschrieben wurde, aus der Datei FileNameFileNameFileNameFileNameFileNamefileName ein. Die Dateiendung für die Matrix ist in HALCON 'mtx'. Das Dateiformat kann binär oder ascii sein. Jede Zeile der Datei enthält eine Zeile der Matrix mit einer Anzahl von Spalten. Die Spalten sind durch Leerzeichen oder Tabulatoren getrennt. Jede Zeile muss dieselbe Anzahl an Spalten beinhalten. Leere Zeilen werden ingnoriert.

Die eingelesenen Ergebnisse werden in der generierten Matrix MatrixMatrixMatrixMatrixMatrixmatrix gespeichert. Es wird das Matrix Handle MatrixIDMatrixIDMatrixIDMatrixIDMatrixIDmatrixID dieser Matrix zurückgegeben. Zugriff auf die Elemente der Matrizen ist z.B. mit dem Operator get_full_matrixget_full_matrixGetFullMatrixget_full_matrixGetFullMatrixGetFullMatrix möglich.

Parallelisierung

Dieser Operator liefert ein Handle zurück. Es ist zu beachten, dass der Zustand einer Instanz dieses Handletyps durch bestimmte Operatoren geändert werden kann, obwohl das Handle als Eingabeparameter in diesen Operatoren verwendet wird.

Parameter

FileNameFileNameFileNameFileNameFileNamefileName (input_control)  filename.read HTupleHTupleHTupleVARIANTHtuple (string) (string) (HString) (char*) (BSTR) (char*)

Name der Datei.

Dateiendung: .mtx

MatrixIDMatrixIDMatrixIDMatrixIDMatrixIDmatrixID (output_control)  matrix HMatrix, HTupleHTupleHMatrix, HTupleHMatrixX, VARIANTHtuple (integer) (IntPtr) (Hlong) (Hlong) (Hlong) (Hlong)

Matrix Handle.

Ergebnis

Ist der Dateiname korrekt, dann liefert read_matrixread_matrixReadMatrixread_matrixReadMatrixReadMatrix den Wert 2 (H_MSG_TRUE). Gegebenenfalls wird eine Fehlerbehandlung durchgeführt.

Nachfolger

get_full_matrixget_full_matrixGetFullMatrixget_full_matrixGetFullMatrixGetFullMatrix

Modul

Foundation


KlassenKlassenKlassenKlassen | | | | Operatoren