freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Devel] pixel size, hinting and scaling


From: Gustavo J. A. M.
Subject: [Devel] pixel size, hinting and scaling
Date: 24 Jan 2003 18:37:38 +0000

  I'd just like to add this information to this thead that I found in
the archives when I wasn't subscribed.
  Regarding the subject of decomposing a transformation matrix into
(scale x rest), libart_lgpl has this function that is probably what you
want:


/**
 * art_affine_expansion: Find the affine's expansion factor.
 * @src: The affine transformation.
 *
 * Finds the expansion factor, i.e. the square root of the factor
 * by which the affine transform affects area. In an affine transform
 * composed of scaling, rotation, shearing, and translation, returns
 * the amount of scaling.
 *
 * Return value: the expansion factor.
 **/
double
art_affine_expansion (const double src[6])
{
  return sqrt (fabs (src[0] * src[3] - src[1] * src[2]));
}

  Regards.

-- 
Gustavo João Alves Marques Carneiro
<address@hidden> <address@hidden>





reply via email to

[Prev in Thread] Current Thread [Next in Thread]