{"action":"closed","issue":{"url":"https://api.github.com/repos/va3c/RvtVa3c/issues/10","labels_url":"https://api.github.com/repos/va3c/RvtVa3c/issues/10/labels{/name}","comments_url":"https://api.github.com/repos/va3c/RvtVa3c/issues/10/comments","events_url":"https://api.github.com/repos/va3c/RvtVa3c/issues/10/events","html_url":"https://github.com/va3c/RvtVa3c/issues/10","id":118852004,"number":10,"title":"Asing HELP for transform matrix assembly","user":{"login":"flower4wine","id":8189254,"avatar_url":"https://avatars.githubusercontent.com/u/8189254?v=3","gravatar_id":"","url":"https://api.github.com/users/flower4wine","html_url":"https://github.com/flower4wine","followers_url":"https://api.github.com/users/flower4wine/followers","following_url":"https://api.github.com/users/flower4wine/following{/other_user}","gists_url":"https://api.github.com/users/flower4wine/gists{/gist_id}","starred_url":"https://api.github.com/users/flower4wine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/flower4wine/subscriptions","organizations_url":"https://api.github.com/users/flower4wine/orgs","repos_url":"https://api.github.com/users/flower4wine/repos","events_url":"https://api.github.com/users/flower4wine/events{/privacy}","received_events_url":"https://api.github.com/users/flower4wine/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-11-25T14:48:28Z","updated_at":"2015-11-30T03:28:03Z","closed_at":"2015-11-30T03:28:03Z","body":"Jeremy,\r\n\r\nActually it's not an issue but a question. I'm working on a viewer with customized json format. However, I have some problem while tring to reuse geometry of family symbol with different transform. \r\n\r\nAs you mentioned in \"the building coder\", Revit API only provides a high level Transform class to expose matrix transformation relative information. But I need to assemble transformation MATRIX in a double array.\r\n\r\nHere is my code to assemble transformation matrix:\r\n\r\n    Transform t = InstanceNode.GetTransform();\r\n    double[] matrix = new double[]\r\n    {\r\n        t.BasisX.X * t.Scale, t.BasisX.Y,               t.BasisX.Z,               glOrigin.X, \r\n        t.BasisY.X,               t.BasisY.Y * t.Scale, t.BasisY.Z,               glOrigin.Y, \r\n        t.BasisZ.X,               t.BasisZ.Y,               t.BasisZ.Z * t.Scale, glOrigin.Z \r\n     };\r\n\r\nAnd the frustrated render looks as screenshot rst_basic_sample_project (with transformation issue).\r\n![rst_basic_sample_project with transformation issue](https://cloud.githubusercontent.com/assets/8189254/11400007/c33eb68e-93c5-11e5-928c-f5d55d40656c.png)\r\n\r\nI checked the transform property of a couple of elements and found that:\r\n1. elements with no rotation (3x3 identity, no matter what origin is) are rendered correctly.\r\n2. elements with rotation are rendered incorrectly (direction is correct, but position is wrong) \r\n\r\nThe most possible reason is that I assemle transformation matrix in a wrong way. Could you please help take a look and give me some tips? Thanks a lot!\r\n\r\nDavid"}}