コード例 #1
0
ファイル: HQuaternion.cs プロジェクト: zshankang/OpenHalcon
        /// <summary>
        ///   Multiply two quaternions.
        ///   Instance represents: Left quaternion.
        /// </summary>
        /// <param name="quaternionRight">Right quaternion.</param>
        /// <returns>Product of the input quaternions.</returns>
        public HQuaternion QuatCompose(HQuaternion quaternionRight)
        {
            IntPtr proc = HalconAPI.PreCall(232);

            this.Store(proc, 0);
            HalconAPI.Store(proc, 1, (HData)quaternionRight);
            HalconAPI.InitOCT(proc, 0);
            int err = HalconAPI.CallProcedure(proc);

            this.UnpinTuple();
            HalconAPI.UnpinTuple((HTuple)((HData)quaternionRight));
            HQuaternion hquaternion;
            int         procResult = HQuaternion.LoadNew(proc, 0, err, out hquaternion);

            HalconAPI.PostCall(proc, procResult);
            GC.KeepAlive((object)this);
            return(hquaternion);
        }
コード例 #2
0
 /// <summary>Create a dual quaternion from two quaternions </summary>
 public HDualQuaternion(HQuaternion quat1, HQuaternion quat2)
     : base(quat1.RawData.TupleConcat(quat2.RawData))
 {
 }
コード例 #3
0
ファイル: HQuaternion.cs プロジェクト: zshankang/OpenHalcon
 internal static int LoadNew(IntPtr proc, int parIndex, int err, out HQuaternion obj)
 {
     return(HQuaternion.LoadNew(proc, parIndex, HTupleType.MIXED, err, out obj));
 }