diff options
author | The Android Open Source Project <initial-contribution@android.com> | 2009-03-18 22:20:25 -0700 |
---|---|---|
committer | The Android Open Source Project <initial-contribution@android.com> | 2009-03-18 22:20:25 -0700 |
commit | 0a9d06e2b5cf75c3d6ba958026bfdf4745f576d6 (patch) | |
tree | bda73f0de3896a97ff4231e4600fccd89a3f9118 /src/base/ftglyph.c | |
parent | 049d6fea481044fcc000e7782e5bc7046fc70844 (diff) | |
download | android_external_freetype-0a9d06e2b5cf75c3d6ba958026bfdf4745f576d6.tar.gz android_external_freetype-0a9d06e2b5cf75c3d6ba958026bfdf4745f576d6.tar.bz2 android_external_freetype-0a9d06e2b5cf75c3d6ba958026bfdf4745f576d6.zip |
auto import //branches/master/...@140412
Diffstat (limited to 'src/base/ftglyph.c')
-rw-r--r-- | src/base/ftglyph.c | 64 |
1 files changed, 1 insertions, 63 deletions
diff --git a/src/base/ftglyph.c b/src/base/ftglyph.c index db0e79f..4130cb1 100644 --- a/src/base/ftglyph.c +++ b/src/base/ftglyph.c @@ -4,7 +4,7 @@ /* */ /* FreeType convenience functions to handle glyphs (body). */ /* */ -/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2007 by */ +/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2007, 2008 by */ /* David Turner, Robert Wilhelm, and Werner Lemberg. */ /* */ /* This file is part of the FreeType project, and may only be used, */ @@ -48,68 +48,6 @@ /*************************************************************************/ /*************************************************************************/ /**** ****/ - /**** Convenience functions ****/ - /**** ****/ - /*************************************************************************/ - /*************************************************************************/ - - - /* documentation is in ftglyph.h */ - - FT_EXPORT_DEF( void ) - FT_Matrix_Multiply( const FT_Matrix* a, - FT_Matrix *b ) - { - FT_Fixed xx, xy, yx, yy; - - - if ( !a || !b ) - return; - - xx = FT_MulFix( a->xx, b->xx ) + FT_MulFix( a->xy, b->yx ); - xy = FT_MulFix( a->xx, b->xy ) + FT_MulFix( a->xy, b->yy ); - yx = FT_MulFix( a->yx, b->xx ) + FT_MulFix( a->yy, b->yx ); - yy = FT_MulFix( a->yx, b->xy ) + FT_MulFix( a->yy, b->yy ); - - b->xx = xx; b->xy = xy; - b->yx = yx; b->yy = yy; - } - - - /* documentation is in ftglyph.h */ - - FT_EXPORT_DEF( FT_Error ) - FT_Matrix_Invert( FT_Matrix* matrix ) - { - FT_Pos delta, xx, yy; - - - if ( !matrix ) - return FT_Err_Invalid_Argument; - - /* compute discriminant */ - delta = FT_MulFix( matrix->xx, matrix->yy ) - - FT_MulFix( matrix->xy, matrix->yx ); - - if ( !delta ) - return FT_Err_Invalid_Argument; /* matrix can't be inverted */ - - matrix->xy = - FT_DivFix( matrix->xy, delta ); - matrix->yx = - FT_DivFix( matrix->yx, delta ); - - xx = matrix->xx; - yy = matrix->yy; - - matrix->xx = FT_DivFix( yy, delta ); - matrix->yy = FT_DivFix( xx, delta ); - - return FT_Err_Ok; - } - - - /*************************************************************************/ - /*************************************************************************/ - /**** ****/ /**** FT_BitmapGlyph support ****/ /**** ****/ /*************************************************************************/ |