示例#1
0
        public virtual Vector3d [] GetNVector3dValues(double time)
        {
            var count    = ElementCount;
            var timesArr = new Vector3d [(int)count];
            int typeSize = Marshal.SizeOf(typeof(Vector3d));

            unsafe {
                fixed(Vector3d *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, time, _GetDouble3Array);
            }

            return(timesArr);
        }
        public virtual void SetValues(Vector3d [] array, double time)
        {
            if (array == null)
            {
                ObjCRuntime.ThrowHelper.ThrowArgumentNullException(nameof(array));
            }
            int typeSize = Marshal.SizeOf(typeof(Vector3d));

            unsafe {
                fixed(Vector3d *arrptr = array)
                MDLMemoryHelper.SetValues(typeSize, (IntPtr)arrptr, array.Length, time, _SetDouble3Array);
            }
        }
示例#3
0
        public virtual Quaterniond [] GetQuaterniondValues()
        {
            var count    = ElementCount * TimeSampleCount;
            var timesArr = new Quaterniond [(int)count];
            int typeSize = Marshal.SizeOf(typeof(Quaterniond));

            unsafe {
                fixed(Quaterniond *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetDoubleQuaternionArray);
            }

            return(timesArr);
        }
示例#4
0
        public virtual Quaternion [] GetQuaternionValues(double time)
        {
            var count    = ElementCount;
            var timesArr = new Quaternion [(int)count];
            int typeSize = Marshal.SizeOf(typeof(Quaternion));

            unsafe {
                fixed(Quaternion *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, time, _GetFloatQuaternionArray);
            }

            return(timesArr);
        }
示例#5
0
        public virtual Matrix4 [] GetNMatrix4Values()
        {
            var count    = TimeSampleCount;
            var timesArr = new Matrix4 [(int)count];
            int typeSize = Marshal.SizeOf(typeof(Matrix4));

            unsafe {
                fixed(Matrix4 *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetFloat4x4Array);
            }

            return(timesArr);
        }
        public virtual void SetValues(Matrix4 [] array)
        {
            if (array == null)
            {
                ObjCRuntime.ThrowHelper.ThrowArgumentNullException(nameof(array));
            }
            int typeSize = Marshal.SizeOf(typeof(Matrix4));

            unsafe {
                fixed(Matrix4 *arrptr = array)
                MDLMemoryHelper.SetValues(typeSize, (IntPtr)arrptr, array.Length, _SetFloat4x4Array);
            }
        }
示例#7
0
        public virtual void SetValues(Quaterniond [] array, double time)
        {
            if (array == null)
            {
                throw new ArgumentNullException(nameof(array));
            }
            int typeSize = Marshal.SizeOf(typeof(Quaterniond));

            unsafe {
                fixed(Quaterniond *arrptr = array)
                MDLMemoryHelper.SetValues(typeSize, (IntPtr)arrptr, array.Length, time, _SetDoubleQuaternionArray);
            }
        }
示例#8
0
        public virtual Matrix4d [] GetNMatrix4dValues()
        {
            var count    = ElementCount;
            var timesArr = new Matrix4d [(int)count];
            int typeSize = Marshal.SizeOf(typeof(Matrix4d));

            unsafe {
                fixed(Matrix4d *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetDouble4x4Array);
            }

            return(timesArr);
        }
示例#9
0
        public virtual void SetValues(Matrix4d [] array)
        {
            if (array == null)
            {
                throw new ArgumentNullException(nameof(array));
            }
            int typeSize = Marshal.SizeOf(typeof(Matrix4d));

            unsafe {
                fixed(Matrix4d *arrptr = array)
                MDLMemoryHelper.SetValues(typeSize, (IntPtr)arrptr, array.Length, _SetDouble4x4Array);
            }
        }
示例#10
0
        public virtual Vector4d [] GetVector4dValues()
        {
            var count    = TimeSampleCount;
            var timesArr = new Vector4d [(int)count];
            int typeSize = Marshal.SizeOf(typeof(Vector4d));

            unsafe {
                fixed(Vector4d *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetDouble4Array);
            }

            return(timesArr);
        }
示例#11
0
        public virtual Vector3 [] GetNVector3Values()
        {
            var count    = ElementCount * TimeSampleCount;
            var timesArr = new Vector3 [(int)count];
            int typeSize = Marshal.SizeOf(typeof(Vector3));

            unsafe {
                fixed(Vector3 *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetFloat3Array);
            }

            return(timesArr);
        }
        public virtual Matrix4 [] GetNMatrix4Values()
        {
            var count    = ElementCount;
            var timesArr = new Matrix4 [(int)count];

            unsafe {
                int typeSize = sizeof(Matrix4);

                fixed(Matrix4 *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetFloat4x4Array);
            }

            return(timesArr);
        }
        public virtual Matrix4d [] GetNMatrix4dValues()
        {
            var count    = TimeSampleCount;
            var timesArr = new Matrix4d [(int)count];

            unsafe {
                int typeSize = sizeof(Matrix4d);

                fixed(Matrix4d *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetDouble4x4Array);
            }

            return(timesArr);
        }
        public virtual Vector4 [] GetVector4Values()
        {
            var count    = TimeSampleCount;
            var timesArr = new Vector4 [(int)count];

            unsafe {
                int typeSize = sizeof(Vector4);

                fixed(Vector4 *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetFloat4Array);
            }

            return(timesArr);
        }
        public virtual Quaternion [] GetQuaternionValues()
        {
            var count    = ElementCount * TimeSampleCount;
            var timesArr = new Quaternion [(int)count];

            unsafe {
                int typeSize = sizeof(Quaternion);

                fixed(Quaternion *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetFloatQuaternionArray);
            }

            return(timesArr);
        }
        public virtual Quaterniond [] GetQuaterniondValues(double time)
        {
            var count    = ElementCount;
            var timesArr = new Quaterniond [(int)count];

            unsafe {
                int typeSize = sizeof(Quaterniond);

                fixed(Quaterniond *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, time, _GetDoubleQuaternionArray);
            }

            return(timesArr);
        }
        public virtual Vector3d [] GetNVector3dValues()
        {
            var count    = ElementCount * TimeSampleCount;
            var timesArr = new Vector3d [(int)count];

            unsafe {
                int typeSize = sizeof(Vector3d);

                fixed(Vector3d *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, _GetDouble3Array);
            }

            return(timesArr);
        }
        public virtual Vector3 [] GetNVector3Values(double time)
        {
            var count    = ElementCount;
            var timesArr = new Vector3 [(int)count];

            unsafe {
                int typeSize = sizeof(Vector3);

                fixed(Vector3 *arrptr = timesArr)
                MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, count, time, _GetFloat3Array);
            }

            return(timesArr);
        }
示例#19
0
        public virtual Quaterniond [] GetQuaterniondValues(nuint maxCount)
        {
            var timesArr = new Quaterniond [(int)maxCount];

            unsafe {
                int typeSize = sizeof(Quaterniond);
                fixed(Quaterniond *arrptr = timesArr)
                {
                    var rv = MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, maxCount, _GetDoubleQuaternionArray);

                    Array.Resize(ref timesArr, (int)rv);
                }
            }

            return(timesArr);
        }
示例#20
0
        public virtual Quaternion [] GetQuaternionValues(nuint maxCount)
        {
            var timesArr = new Quaternion [(int)maxCount];
            int typeSize = Marshal.SizeOf(typeof(Quaternion));

            unsafe
            {
                fixed(Quaternion *arrptr = timesArr)
                {
                    var rv = MDLMemoryHelper.FetchValues(typeSize, (IntPtr)arrptr, maxCount, _GetFloatQuaternionArray);

                    Array.Resize(ref timesArr, (int)rv);
                }
            }

            return(timesArr);
        }
        public virtual void Reset(Vector3d [] values, double [] times)
        {
            if (values == null)
            {
                ObjCRuntime.ThrowHelper.ThrowArgumentNullException(nameof(values));
            }
            if (times == null)
            {
                ObjCRuntime.ThrowHelper.ThrowArgumentNullException(nameof(times));
            }
            int typeSize = Marshal.SizeOf(typeof(Vector3d));

            unsafe {
                fixed(Vector3d *valuesPtr = values)
                MDLMemoryHelper.Reset(typeSize, (IntPtr)valuesPtr, values.Length, times, _ResetWithDouble3Array);
            }
        }
示例#22
0
        public virtual void Reset(Quaterniond [] values, double [] times)
        {
            if (values == null)
            {
                throw new ArgumentNullException(nameof(values));
            }
            if (times == null)
            {
                throw new ArgumentNullException(nameof(times));
            }
            int typeSize = Marshal.SizeOf(typeof(Quaterniond));

            unsafe {
                fixed(Quaterniond *valuesPtr = values)
                MDLMemoryHelper.Reset(typeSize, (IntPtr)valuesPtr, values.Length, times, _ResetWithDoubleQuaternionArray);
            }
        }
        public virtual void Reset(Vector3 [] values, double [] times)
        {
            if (values == null)
            {
                ObjCRuntime.ThrowHelper.ThrowArgumentNullException(nameof(values));
            }
            if (times == null)
            {
                ObjCRuntime.ThrowHelper.ThrowArgumentNullException(nameof(times));
            }
            if (values.Length != times.Length)
            {
                throw new InvalidOperationException($"The length of the '{nameof (values)}' array and the '{nameof (times)}' array must match.");
            }
            int typeSize = Marshal.SizeOf(typeof(Vector3));

            unsafe {
                fixed(Vector3 *valuesPtr = values)
                MDLMemoryHelper.Reset(typeSize, (IntPtr)valuesPtr, times, _ResetWithFloat3Array);
            }
        }
示例#24
0
        public virtual void Reset(Quaternion [] values, double [] times)
        {
            if (values == null)
            {
                throw new ArgumentNullException(nameof(values));
            }
            if (times == null)
            {
                throw new ArgumentNullException(nameof(times));
            }
            if (values.Length != times.Length)
            {
                throw new ArgumentOutOfRangeException($"The '{nameof (values)}' and '{nameof (times)}' arrays must have the same length");
            }
            int typeSize = Marshal.SizeOf(typeof(Quaternion));

            unsafe {
                fixed(Quaternion *valuesPtr = values)
                MDLMemoryHelper.Reset(typeSize, (IntPtr)valuesPtr, times, _ResetWithFloatQuaternionArray);
            }
        }
示例#25
0
        public virtual void Reset(Matrix4d [] values, double [] times)
        {
            if (values == null)
            {
                throw new ArgumentNullException(nameof(values));
            }
            if (times == null)
            {
                throw new ArgumentNullException(nameof(times));
            }
            if (values.Length != times.Length)
            {
                throw new InvalidOperationException($"The length of the '{nameof (values)}' array and the '{nameof (times)}' array must match.");
            }
            int typeSize = Marshal.SizeOf(typeof(Matrix4d));

            unsafe {
                fixed(Matrix4d *valuesPtr = values)
                MDLMemoryHelper.Reset(typeSize, (IntPtr)valuesPtr, times, _ResetWithDouble4x4Array);
            }
        }