public object Convert(object[] values, Type targetType, object parameter, CultureInfo culture)
        {
            var scale     = (float)values[0];
            var transform = (Numerics.Matrix4x4)values[1];

            var tGroup = new Media3D.Transform3DGroup();

            if (scale != 1)
            {
                var tform = new Media3D.ScaleTransform3D(scale, scale, scale);

                tform.Freeze();
                tGroup.Children.Add(tform);
            }

            if (!transform.IsIdentity)
            {
                var tform = new Media3D.MatrixTransform3D(transform.ToMatrix3D());

                tform.Freeze();
                tGroup.Children.Add(tform);
            }

            tGroup.Freeze();
            return(tGroup);
        }
            private Media3D.Transform3D GetTransform(float scale, Matrix4x4 transform)
            {
                var tGroup = new Media3D.Transform3DGroup();

                if (scale != 1)
                {
                    var tform = new Media3D.ScaleTransform3D(scale, scale, scale);

                    tform.Freeze();
                    tGroup.Children.Add(tform);
                }

                if (!transform.IsIdentity)
                {
                    var tform = new Media3D.MatrixTransform3D(transform.ToMatrix3D());

                    tform.Freeze();
                    tGroup.Children.Add(tform);
                }

                tGroup.Freeze();
                return(tGroup);
            }