{"id":16207784,"url":"https://github.com/netpyoung/libfixmath.net","last_synced_at":"2025-06-13T17:32:41.647Z","repository":{"id":139619238,"uuid":"135203008","full_name":"netpyoung/libfixmath.net","owner":"netpyoung","description":"These functions operate on 32-bit numbers, fix16_t, which have 16 bit integer part and 16 bit fractional part.","archived":false,"fork":false,"pushed_at":"2018-05-30T14:07:58.000Z","size":246,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-07T20:16:31.263Z","etag":null,"topics":["fix16","float","libfixmath"],"latest_commit_sha":null,"homepage":"","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/netpyoung.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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":"2018-05-28T19:50:05.000Z","updated_at":"2018-05-30T14:08:00.000Z","dependencies_parsed_at":"2023-07-04T15:37:30.002Z","dependency_job_id":null,"html_url":"https://github.com/netpyoung/libfixmath.net","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/netpyoung/libfixmath.net","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/netpyoung%2Flibfixmath.net","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/netpyoung%2Flibfixmath.net/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/netpyoung%2Flibfixmath.net/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/netpyoung%2Flibfixmath.net/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/netpyoung","download_url":"https://codeload.github.com/netpyoung/libfixmath.net/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/netpyoung%2Flibfixmath.net/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259688368,"owners_count":22896393,"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":["fix16","float","libfixmath"],"created_at":"2024-10-10T10:14:27.216Z","updated_at":"2025-06-13T17:32:41.622Z","avatar_url":"https://github.com/netpyoung.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"libfixmath.net\n=========================\n\n\n* origin : https://code.google.com/archive/p/libfixmath/\n\n## fix16\n\n```cs\nusing fix16_t = System.Int32;\n\npublic struct fix16\n{\n  private fix16_t value;\n}\n```\n\n* 32-bit numbers, fix16_t, which have 16 bit integer part and 16 bit fractional part.\n* max : 32767.999_985\n* min : -32768.0\n  - The minimum value is also used to represent fix16_overflow for overflow detection, so for some operations it cannot be determined whether it overflowed or the result was the smallest possible value. In practice this does not matter much.\n* The smallest unit (machine precision) of the datatype is 1/65536 = 0.000_015\n\n\n# wiki\n* https://code.google.com/archive/p/libfixmath/wikis/FunctionReference.wiki\n\n\n# Define Option\n* I already removed `FIXMATH_NO_64BIT`, `FIXMATH_OPTIMIZE_8BIT` from origin source.\n\n\n```\nAccuracy\n\n    FIXMATH_NO_ROUNDING: Disable rounding. Results may round randomly up or down, i.e. their accuracy is +-1. Runs slightly faster.\n    FIXMATH_NO_OVERFLOW: Disable overflow detection and saturating arithmetic support. Overflowing computations will give garbage results. Runs slightly faster.\n\nPlatform\n\n    FIXMATH_NO_CACHE: Do not use cache for exp etc. function results. Uses less RAM, runs slightly slower.\n\nAlgorithms\n\n    FIXMATH_SIN_LUT: This uses a look-up table generated by the fixsingen tool from svn, it is faster on some devices but the lookup table takes up ~200KiB (205376 bytes) in memory and can be slower dependant on usage.\n    FIXMATH_FAST_SIN: This enables a faster but less accurate approximation of the sin function, for code where accuracy isn't as important such as games logic or graphics rendering then this is often a worthwhile tradeoff.\n```\n\n# why.\nWhen I try to test deterministic logic on game, I tried to find float library. and I found some. but I decided to customize from original libfixmath.\n\n* https://github.com/asik/FixedMath.Net\n* https://github.com/sungiant/abacus\n\n* I don't need 64bit float.\n* float library slower than float. so as possible as I choose more faster logic.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnetpyoung%2Flibfixmath.net","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnetpyoung%2Flibfixmath.net","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnetpyoung%2Flibfixmath.net/lists"}