get_translation_matrix(3alleg4)
β¨ NAME β¨
get_translation_matrix, get_translation_matrix_f β bestie these build you a translation matrix π« (from the Allegro game programming library, iykyk)
πΈ SYNOPSIS πΈ
#include <allegro.h>
void get_translation_matrix(MATRIX *m, fixed x, fixed y, fixed z);
void get_translation_matrix_f(MATRIX_f *m, float x, float y, float z);
π DESCRIPTION π
okay so. get_translation_matrix constructs a translation matrix and stores it in m. that's it, that's the whole vibe. π
when you apply this matrix to the point (px, py, pz), it will produce the point (px+x, py+y, pz+z) β literally just adds x to the x, y to the y, z to the z. math is so iconic sometimes.
in other words, it moves things sideways. periodt. π¦
and the_fversion? same energy, same everything, except it takesfloats and aMATRIX_finstead offixeds and aMATRIX. slay. β¨
π SEE ALSO π
apply_matrix(3alleg4)get_transformation_matrix(3alleg4)qtranslate_matrix(3alleg4)exstars(3alleg4)
go read those next bestie, they're part of the same little friend group π«Ά
written for Allegro, version 4.4.3 β no cap, that's the whole page. go translate something, you absolute main character πππ
π¦ where this page comes from
- debian bookworm: allegro4-doc 2:4.4.3.1-3 Β· Allegro-gift-ware
- debian trixie: allegro4-doc 2:4.4.3.1-5 Β· Allegro-gift-ware
- ubuntu jammy: allegro4-doc 2:4.4.3.1-2 Β· Allegro-gift-ware
- ubuntu noble: allegro4-doc 2:4.4.3.1-4.1build3 Β· Allegro-gift-ware
- ubuntu questing: allegro4-doc 2:4.4.3.1-6
- ubuntu resolute: allegro4-doc 2:4.4.3.1-7 Β· Allegro-gift-ware
- ubuntu stonking: allegro4-doc 2:4.4.3.1-9 Β· Allegro-gift-ware
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms