// ccbord.c (982, 1) // pixGetHoleBorder(ccb, pixs, box, xs, ys) as int // pixGetHoleBorder(CCBORD *, PIX *, BOX *, l_int32, l_int32) as l_ok /// <summary> /// (1) we trace out hole border on pixs without addition /// of single pixel added border to pixs<para/> /// /// (2) therefore all coordinates are relative within the c.c. (pixs)<para/> /// /// (3) same position tables and stopping condition as for /// exterior borders /// </summary> /// <remarks> /// </remarks> /// <include file="..\CHM_Help\IncludeComments.xml" path="Comments/pixGetHoleBorder/*"/> /// <param name="ccb">[in] - the exterior border is already made</param> /// <param name="pixs">[in] - for the connected component at hand</param> /// <param name="box">[in] - for the specific hole border, in relative coordinates to the c.c.</param> /// <param name="xs">[in] - first pixel on hole border, relative to c.c.</param> /// <param name="ys">[in] - first pixel on hole border, relative to c.c.</param> /// <returns>0 if OK, 1 on error</returns> public static int pixGetHoleBorder( CCBord ccb, Pix pixs, Box box, int xs, int ys) { if (ccb == null) { throw new ArgumentNullException("ccb cannot be Nothing"); } if (pixs == null) { throw new ArgumentNullException("pixs cannot be Nothing"); } if (box == null) { throw new ArgumentNullException("box cannot be Nothing"); } int _Result = Natives.pixGetHoleBorder(ccb.Pointer, pixs.Pointer, box.Pointer, xs, ys); return(_Result); }
// ccbord.c (454, 1) // ccbaAddCcb(ccba, ccb) as int // ccbaAddCcb(CCBORDA *, CCBORD *) as l_ok /// <summary> /// ccbaAddCcb() /// </summary> /// <remarks> /// </remarks> /// <include file="..\CHM_Help\IncludeComments.xml" path="Comments/ccbaAddCcb/*"/> /// <param name="ccba">[in] - </param> /// <param name="ccb">[in] - to be added by insertion</param> /// <returns>0 if OK 1 on error</returns> public static int ccbaAddCcb( CCBorda ccba, CCBord ccb) { if (ccba == null) { throw new ArgumentNullException("ccba cannot be Nothing"); } if (ccb == null) { throw new ArgumentNullException("ccb cannot be Nothing"); } int _Result = Natives.ccbaAddCcb(ccba.Pointer, ccb.Pointer); return(_Result); }
// ccbord.c (404, 1) // ccbDestroy(pccb) as Object // ccbDestroy(CCBORD **) as void /// <summary> /// ccbDestroy() /// </summary> /// <remarks> /// </remarks> /// <include file="..\CHM_Help\IncludeComments.xml" path="Comments/ccbDestroy/*"/> /// <param name="pccb">[in,out] - to be nulled</param> public static void ccbDestroy( ref CCBord pccb) { IntPtr pccbPtr = IntPtr.Zero; if (pccb != null) { pccbPtr = pccb.Pointer; } Natives.ccbDestroy(ref pccbPtr); if (pccbPtr == IntPtr.Zero) { pccb = null; } else { pccb = new CCBord(pccbPtr); }; }