Jeremy Ong

jeremyong.com · Personal blog · on HN since 2013

Jeremy Ong, a graphics programmer, writes about geometric algebra, computer graphics, game engines, and low-level systems topics such as memory-mapped files.

What HN saysHN commenters discuss his geometric algebra library and its reference materials, and engage with his technical points on Windows memory mapping.
22HN people shared it
9linked it in comments
26stories submitted
559story points
1 year agolast shared
2013people per year2026

Most-shared posts

  1. 1
  2. 2
    Getting Started in Computer Graphics
    3 people · 7 points · first shared 2024 · discussion on HN
  3. 3
    Basic skeletal animation with geometric algebra
    2 people · 174 points · first shared 2020 · 36 comments on HN
  4. 4
    Windows Memory Mapped File IO
    2 people · 63 points · first shared 2024 · 15 comments on HN
  5. 5
    Thoughts on the Cpp Graphics Proposal
    2 people · 21 points · first shared 2018 · 1 comments on HN
  6. 6
    Interviewing Graphics Programmers
    2 people · 3 points · first shared 2023 · discussion on HN
  7. 7
    Evaluating Game Engines
    2 people · 3 points · first shared 2023 · discussion on HN
  8. 8
    Geometry potpourri
    2 people · first shared 2020
  9. 9
    Graphics Pipelines for Young Bloods
    1 people · 136 points · first shared 2021 · 17 comments on HN
  10. 10
    The C++20 Naughty and Nice List for Game Devs
    1 people · 132 points · first shared 2023 · 103 comments on HN
  11. 11
    Dual Quaternions for Mere Mortals
    1 people · 3 points · first shared 2019 · discussion on HN
  12. 12
    Learn to read dissasembly
    1 people · 3 points · first shared 2014 · discussion on HN
  13. 13
    Interfacing Lua with templates in C++
    1 people · 2 points · first shared 2014 · discussion on HN
  14. 14
    Grokking Big Unfamiliar Codebases
    1 people · 2 points · first shared 2023 · discussion on HN
  15. 15
    Optimizing C++ by Avoiding Moves
    1 people · 2 points · first shared 2019 · discussion on HN

What HN people wrote when they linked it

DrDroop · 2023-09-24
Some GA libraries[1][2] define types for the different kind of objects (grades), although they are time consuming to implement and fixed in the number of dimensions they describe. But you are right that the most implementation combine all grades into a single array, but the biggest problem with those is that the size of the array in 2^n with n the number of dimensions. To work in 3D you probably want to use R(3,0,1) for all rigid transformation or even R(4,0,1), but that brings the total number of 16 or 32 floats to just represent a point. Imho the biggest problem in GA for CS is the lack of a good ecosystem of tools. Ganja.js is nice, probably the best in class when it comes to API design, but is completely useless when trying to work with other JS libraries because ganja.js has it's own weird transpiler. [1]https://www.jeremyong.com/klein/ [2]https://github.com/wrnrlr/g3
creata · 2020-11-18
Do you have some before-and-after code that you can share? I've seen two other efforts in that general direction: * "Let's Remove Quaternions from Every 3D Engine"[0], which was underwhelming: let's ask other people to rename existing code for no practical benefit? * "Klein"[1], a projective geometric algebra library that is amazingly nice to use, and claims to be very fast. [0]: https://marctenbosch.com/quaternions/ [1]: https://www.jeremyong.com/klein/
wnoise · 2020-11-28
I don't have a book recommendation handy. It's "just" a combination of two neat techniques. Get books on each of those and understand them each, and you have the combination. GA has been well discussed here, so, the other half: Projectivization is a fairly standard trick even for normal geometry. It's adding an additional dimension, which is in most contexts just set to 1. (Projective actually just means treating all points on a ray as equivalent; this loses the dimension you just gained It lets rotations and translations be treated in a nearly uniform manner, and lets you do rotations around points that aren't the origin. It's used all over the place in much graphics code (usually under the name homogeneous coördinates). The last section of https://en.wikipedia.org/wiki/Homogeneous_coordinates discusses this briefly. For online resources for the combination: another commenter has recommended https://bivector.net/ , and it looks okay, with sections specifically on 2 and 3 dimensional projective geometric algebra. There is also the nice C++ header library klein: https://www.jeremyong.com/klein/
ninepoints · 2020-03-22
Thanks for the questions. > re: introductory materials The 3 links I compiled here (https://www.jeremyong.com/klein/references/) I consider an absolute must for starting to consume GA. The book (ref #3) has one chapter undergoing revision regarding the usefulness of the degenerate metric for modeling projective geometry. My understanding is the chapter will be released for free once finished. From this alone, I was able to piece together enough to write one working implementation of GA that I was able to use to verify the computations and my understanding. Klein is my third GA library which I wrote once I was pretty sure I was comfortable with the formalism. Another great set of resources is anything posted on bivector.net. > re: question 2 The elegance of the math does help me identify better optimizations in a number of cases, but in other cases, it makes a whole series of operations well-defined (for which there was no good analog before). I posted some examples in another comment, but essentially, quats and dual-quats generally only work on points, and in a somewhat awkward manner. I can't easily compose 2 rotations, a translation, a dual quat, and a quat, and then expect it to work on a line for example. In GA, this is ... completely trivial. And because it all fits nicely in the framework, all the above benefits from the same SIMD optimizations. I believe the reason GA was not considered well-suited for production/perf reasons is twofold. First, prior art focused…
xeonmc · 2025-05-20
> (mmap's created could only be as large as the file's current size as in Windows, while Linux/BSD semantics allows for a mmap larger than the file that's usable without constant remapping as the file grows). I thought you could do it using ntdll functions, no? https://www.jeremyong.com/winapi/io/2024/11/03/windows-memory-mapped-f…
wrnr · 2021-12-10
Something like that exists in C++ and Rust: * https://www.jeremyong.com/klein/ * https://github.com/wrnrlr/g3
modeless · 2020-12-06
Clearly the generic n-dimensional GA libraries out there have little use for real time graphics, but projects like https://www.jeremyong.com/klein/ that are specialized to 3D with a focus on efficiency look promising.
enkimute · 2020-11-30
That is correct - matrices are the natural companion of the general linear group. The GA representation exists, and is called 'the mother algebra', for general 4x4 matrices the GA equivalent is R4,4. (where general linear transformations are versors). For other subgroups GA reps will also exist. (like e.g. if one wants to include projective transformations as versors, that would be the projective group (which preserves the cross ratio of 4 points), and has a GA representation in R3,3). These spaces quickly become so big that efficient numerical implementations (while not impossible with enough symbolic work at compilation time, see e.g. https://www.jeremyong.com/gal/) are difficult. Other advantages of GA do of course remain.
robaye · 2023-11-25
Honestly, I couldn't say Johnny. I'm not a graphics engineer, just a hobbyist game programmer who works in construction. I did do some internet searching and came across some blogs that I found interesting and might help you. 1. Finding Your Home in Graphics Programming, https://alextardif.com/LearningGraphics.html 2. Applying for Entry Level Graphic Jobs in Games, https://alextardif.com/GraphicsJobGuide.html 3. Junior Graphics Programmer Interview Questions, https://erkaman.github.io/posts/junior_graphics_programmer_interview.h… 4. Interviewing Graphics Programmers, https://www.jeremyong.com/graphics/interviewing/2023/08/05/graphics-pr… 5. Interview Questions, https://aras-p.info/blog/2016/11/05/Interview-questions/

Keyboard shortcuts

/Search
j kNext / previous blog
EnterOpen selected blog
vVisit the blog site
fFollow / unfollow
lSwitch grid / list view
dSwitch dark mode
g hHome
g pTop posts
g tTopics
g fFollowing
g lLiked
g yHistory
g qFAQ
EscBack / close