Blender Git Commit Log

Git Commits -> Revision b25c323

Revision b25c323 by Diego Borghetti (master)
December 9, 2010, 04:36 (GMT)
Add the possibility to set a 4x4 matrix to be used on blf.

This option allow the user to set a 4x4 matrix to be
multiplied before draw the text, for example:

double *m;

/* Get the matrix or build it! */

BLF_matrix(m);
BLF_enable(BLF_MATRIX);

/* set color, size, etc and draw! */

BLF_disable(BLF_MATRIX);

You don't need the last line (disable), but remember
that if you use the font to draw in any other place,
the matrix will be used!.

The GL code is:

glPushMatrix();
glMultMatrixd(m);
glTranslatef();
glScalef();
glRotatef();

glPopMatrix();

Let's Dalai test this!!! :D

Commit Details:

Full Hash: b25c32393d42c314c073ef2244cde1fabb7b64af
SVN Revision: 33566
Parent Commit: 36175f3
Lines Changed: +41, -3

4 Modified Paths:

/source/blender/blenfont/BLF_api.h (+15, -0) (Diff)
/source/blender/blenfont/intern/blf.c (+16, -0) (Diff)
/source/blender/blenfont/intern/blf_font.c (+6, -1) (Diff)
/source/blender/blenfont/intern/blf_internal_types.h (+4, -2) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021