recp / cglm

📽 Highly Optimized 2D / 3D Graphics Math (glm) for C
MIT License
2.15k stars 225 forks source link

Todo: (clifford/geometric algebra, grassmann algebra, bivector, trivector, quad-vector, rotors) #173

Open recp opened 3 years ago

recp commented 3 years ago


just TODO list, we don't have to implement all...

Winter091 commented 3 years ago

It would be very cool to see some glmray* functions, for example, ray-sphere collision test, ray-aabb collision test etc.

recp commented 3 years ago

@Winter091 agree, we already have glm_ray_triangle() but more about ray would be awesome, added TODOs. Any help would be appreciated of course...

Winter091 commented 3 years ago

@recp well, I won't be able to help with implementation, i'm pretty bad at linear algebra. I'm building simple minecraft clone, ray - aabb hit detection is needed there, so I had found this blog. I copied unoptimized version to my project and it works pretty well, but at certain angles it fails to detect collision and I don't know why. Also I don't understand what tmin and tmax variable are doing there and what value they should be initially assigned to.

recp commented 3 years ago

@Winter091 no problem, I'll try to implement highly optimized versions (maybe with SIMD) of ray functions asap. Maybe someone else can implement them before me, it is possible. There are lot of projects I'm working on, you just need to wait a bit ;)

crystalthoughts commented 1 month ago

the Klein library is a good reference