{"id":15722630,"url":"https://github.com/thejustinwalsh/defold-xmath","last_synced_at":"2025-05-07T22:40:43.104Z","repository":{"id":145368984,"uuid":"418204442","full_name":"thejustinwalsh/defold-xmath","owner":"thejustinwalsh","description":"Defold Math eXtension Library that avoids allocations","archived":false,"fork":false,"pushed_at":"2025-01-03T02:08:59.000Z","size":2599,"stargazers_count":28,"open_issues_count":2,"forks_count":3,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-03-31T14:58:23.301Z","etag":null,"topics":["defold","defold-native-extension","game","lua"],"latest_commit_sha":null,"homepage":"https://thejustinwalsh.com/defold-xmath/","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thejustinwalsh.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-10-17T17:23:33.000Z","updated_at":"2025-03-23T14:52:30.000Z","dependencies_parsed_at":"2024-10-24T16:51:04.821Z","dependency_job_id":"9dd89aab-7fcf-499a-aa7d-942246575e41","html_url":"https://github.com/thejustinwalsh/defold-xmath","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thejustinwalsh%2Fdefold-xmath","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thejustinwalsh%2Fdefold-xmath/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thejustinwalsh%2Fdefold-xmath/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thejustinwalsh%2Fdefold-xmath/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thejustinwalsh","download_url":"https://codeload.github.com/thejustinwalsh/defold-xmath/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252967970,"owners_count":21833243,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["defold","defold-native-extension","game","lua"],"created_at":"2024-10-03T22:08:41.480Z","updated_at":"2025-05-07T22:40:43.070Z","avatar_url":"https://github.com/thejustinwalsh.png","language":"C++","funding_links":[],"categories":["Libraries"],"sub_categories":["Programming Language"],"readme":"# xMath Extension\n\u003e Defold Math Library ❌ ~~allocations~~\n\nA re-imagining of vmath functions that avoid allocations by taking the output as the first argument instead of returning a new Vector3, Vector4, or Quat requiring an allocation.\n\n```lua\ngo.property(\"dir\", vmath.vector3(0, 1, 0))\n\n-- allocate v once and reuse each update\nlocal v = vmath.vector3();\n\nfunction update(self, dt)\n  local pos = go.get_position();\n\n  xmath.mul(v, self.dir, 5 * dt); -- save 1 allocation \n  xmath.add(v, pos, v);           -- save 2 allocations\n\n  go.set_position(v);\nend\n```\n\n## Demo\nhttps://thejustinwalsh.com/defold-xmath/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthejustinwalsh%2Fdefold-xmath","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthejustinwalsh%2Fdefold-xmath","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthejustinwalsh%2Fdefold-xmath/lists"}