外接長方形の頂点座標の取得
Namespace: fvalgcliAssembly: fvalgcli (in fvalgcli.dll) Version: 3.1.0.0 (3.1.0.11)
Syntax
C# |
---|
public static int fnFIE_measure_get_rect2pos(
FHANDLE hresult,
uint blobno,
DPNT_T_PTR points
) |
Visual Basic |
---|
Public Shared Function fnFIE_measure_get_rect2pos (
hresult As FHANDLE,
blobno As UInteger,
points As DPNT_T_PTR
) As Integer |
Return Value
Type:
Int32
以下のエラーコードを返します。
エラーコード:f_err | 内容 |
---|
F_ERR_NONE | 正常終了 |
F_ERR_INVALID_OBJECT | hresult に指定されたオブジェクトハンドルが不正 |
F_ERR_INVALID_PARAM | blobno に不正なブローブ番号が渡された, パラメータに IntPtr.Zero が渡された。 |
F_ERR_NO_LICENCE | ライセンスエラー、または未初期化エラー |
Remarks
Examples
C# | Copy |
---|
using System;
using System.Collections.Generic;
using System.Text;
using fvalgcli;
namespace TC
{
public partial class FIE
{
public void fnFIE_measure_get_rect2pos(FHANDLE result, uint blobno)
{
DPNT_T_PTR points = IntPtr.Zero;
try
{
points = DPNT_T_PTR.alloc(4);
int status = api.fnFIE_measure_get_rect2pos(result, blobno, points);
Assert.IsTrue(status == (int)f_err.F_ERR_NONE, "fnFIE_measure_get_rect2pos: エラーが発生しました。({0})", (f_err)status);
Console.WriteLine("fnFIE_measure_get_rect2pos");
Console.WriteLine("point.x1={0}, point.x2={1}, point.x3={2}, point.x4={3}", points[0].x, points[1].x, points[2].x, points[3].x);
}
finally
{
points.Dispose();
}
}
}
} |
Visual Basic | Copy |
---|
Imports System.Collections.Generic
Imports System.Text
Imports fvalgcli
Public Partial Class FIE
Public Sub fnFIE_measure_get_rect2pos(result As FHANDLE, blobno As UInteger)
Dim points As DPNT_T_PTR = IntPtr.Zero
Try
points = DPNT_T_PTR.alloc(4)
Dim status As Integer = api.fnFIE_measure_get_rect2pos(result, blobno, points)
Assert.IsTrue(status = CInt(f_err.F_ERR_NONE), "fnFIE_measure_get_rect2pos: エラーが発生しました。({0})", CType(status, f_err))
Console.WriteLine("fnFIE_measure_get_rect2pos")
Console.WriteLine("point.x1={0}, point.x2={1}, point.x3={2}, point.x4={3}", points(0).x, points(1).x, points(2).x, points(3).x)
Finally
points.Dispose()
End Try
End Sub
End Class |
See Also