/** * この関数は、ラスタの指定点を基点に、輪郭線を抽出します。 開始点は、輪郭の一部である必要があります。 通常は、ラべリングの結果の上辺クリップとX軸エントリポイントを開始点として入力します。 * * @param i_raster 輪郭線を抽出するラスタを指定します。 * @param i_th 輪郭とみなす暗点の敷居値を指定します。 * @param i_entry_x 輪郭抽出の開始点です。 * @param i_entry_y 輪郭抽出の開始点です。 * @param o_coord 輪郭点を格納する配列を指定します。i_array_sizeよりも大きなサイズの配列が必要です。 * @return 輪郭の抽出に成功するとtrueを返します。輪郭抽出に十分なバッファが無いと、falseになります。 * @throws NyARException */ public boolean getContour( INyARGrayscaleRaster i_raster, int i_th, int i_entry_x, int i_entry_y, NyARIntCoordinates o_coord) throws NyARException { NyARIntSize s = i_raster.getSize(); // ラスタドライバの切り替え if (i_raster != this._ref_last_input_raster) { this._imdriver = (IRasterDriver) i_raster.createInterface(IRasterDriver.class); this._ref_last_input_raster = i_raster; } return this._imdriver.getContour(0, 0, s.w - 1, s.h - 1, i_entry_x, i_entry_y, i_th, o_coord); }