cglm icon indicating copy to clipboard operation
cglm copied to clipboard

Swift Package with cpp interop for original GLM library

Open masters3d opened this issue 1 year ago • 2 comments

hi, now that swift has support for cpp interoperability, I am curious if anybody knows of a swift package version of the https://github.com/g-truc/glm?

masters3d avatar Dec 17 '23 04:12 masters3d

You should look for another mathematics library... Preferably this one!

GLM in its present state is barely maintained. "Recent" changes (as of 2021) have broke backwards compatibility. Even more recent changes (Nov 8th) have put the upstream version of the library into an unusable/uncompilable state.

Ever since the issues section was removed from that repository it has become incredibly difficult to track all of the bugs present in that library (and there are many of them).

gottfriedleibniz avatar Dec 18 '23 15:12 gottfriedleibniz

cglm has Swift Package :) Also in the future, cglm may add basic C++ operations like operator overloading ( +=, *=, `-= ) and some other helpers to struct types if target is C++. In this case cglm may take advantage of C++ interop with Swift too.

For now cglm provides cglm/applesimd.h to make it easier to convert cglm -> Apple's simd. Since alignment requirements may be different conversion like this is required I guess.

recp avatar Dec 22 '23 19:12 recp