Esempio n. 1
0
        public static XformableSample FromTransform(UnityEngine.Transform transform)
        {
            var xf = new XformSample();
            var mx = Matrix4x4.TRS(transform.localPosition,
                                   transform.localRotation,
                                   transform.localScale);

            xf.transform = mx;
            return(xf);
        }
Esempio n. 2
0
        private TrTransform UsdXformToWorldSpaceXform(USD.NET.Unity.XformSample usdXform)
        {
            TrTransform xf_CS = TrTransform.FromMatrix4x4(usdXform.transform);

            return(TrTransform.FromTransform(App.Scene.ActiveCanvas.transform) * xf_CS);
        }