*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> ufmGetBitmap (3w)              


ufmGetBitmap(3w)					      ufmGetBitmap(3w)

NAME    [Toc]    [Back]

     ufmGetBitmap - get	a character bitmap

C SYNOPSIS    [Toc]    [Back]

     #include <ufm.h>

     int ufmGetBitmap(unsigned int nTypefaceHandles,
	  unsigned int *typefaceHandles, int charCodeType,
	  unsigned int nCharCodes, void	*charCodes, int	pixelSize,
	  float	angle, unsigned	int *nCharBitmaps, ufmBitmap **charBitmaps)

DESCRIPTION    [Toc]    [Back]

     ufmGetBitmap gets bitmaps for specified characters.  You can get a
     character bitmap only for those typefaces for which bitmap	or outline
     font files	were found, that is, those typefaces which have	the bit
     ufmTypefaceBitmaps	set to 1 in their data structures of the type

     nTypefaceHandles specifies	the number of entries (typeface	handles) in
     the array typefaceHandles.

     typefaceHandles specifies one or more handles for open typefaces.	Use
     the function ufmOpenTypeface to open a typeface, and get a	handle for
     that typeface.

     If	you specify more than one typeface handle, ufmGetBitmap	will look for
     bitmap fonts of the size pixelSize	in specified typefaces.	 If it does
     not find a	requested bitmap font, it will create it.  Then	it will	look
     for the bitmap of a specified character in	the bitmap font	for the	first
     specified typeface.  If it	does not find it in that font, it will look
     for that bitmap in	the next bitmap	font.  It will stop looking as soon as
     it	finds the requested character bitmap.  If it cannot find that bitmap,
     it	will return the	bitmap for the default character.  If ufmGetBitmap
     cannot find the bitmap even for the default character, it will return an
     error code.

     charCodeType specifies a 1-byte character code (UFM_BYTE1), a Unicode
     UCS-2 code	(UFM_UCS2), a Unicode UCS-4 code (UFM_UCS4), a 2-byte
     character code (UFM_BYTE2), or a 4-byte character code (UFM_BYTE4).

     nCharCodes	specifies the number of	elements in the	array charCodes.  Set
     nCharCodes	to 0 if	you want bitmaps for all characters in a specified
     typeface.	If you want bitmaps for	only some characters, use the array
     charCodes to specify the character	codes of those characters.

     pixelSize specifies the size of requested bitmaps in pixels.
     ufmGetBitmap will extract requested character bitmaps from	a bitmap font
     of	the specified pixel size.

     angle specifies the number	of degrees by which character bitmaps must be
     rotated in	a counterclockwise direction.  This is in addition to any
     rotation specified	in the header of a font.

									Page 1

ufmGetBitmap(3w)					      ufmGetBitmap(3w)

     ufmGetBitmap returns the number of	character bitmaps it finds
     (nCharBitmaps) and	the address of the array in which it stores those
     character bitmaps (ufmBitmap).

     When you are finished with	the array (ufmBitmap), you can free it by
     calling ufmFreeBitmap with	the argument values that were returned by

     A bitmap image provided by	the function ufmGetBitmap should be
     interpreted the same way as image data for	the OpenGL function
     glDrawPixels, with	width and height corresponding to the width and	height
     arguments in that function, and with type set to GL_BITMAP	and format set

     Each row of the bitmap is padded to a 4-byte boundary.  If	you want to
     use the information provided by ufmGetBitmap to create OpenGL font
     display lists, that is, to	call OpenGL functions glNewList, glBitmap, and
     glEndList,	you should start by calling glPixelStore function with the
     arguments GL_UNPACK_ALIGNMENT and 4.  For example,	if you decide to use
     the function glPixelStorei, you should specify
     glPixelStorei(GL_UNPACK_ALIGNMENT,	4).

SEE ALSO    [Toc]    [Back]

     ufmGetTransformedBitmap(3w), ufmFreeBitmap(3w).

DIAGNOSTICS    [Toc]    [Back]

     If	ufmGetBitmap is	not able to allocate the memory	it needs, it will
     return the	value UFM_OUT_OF_MEMORY.  If the values	of one or more
     arguments are not valid, ufmGetBitmap will	return the value
     in	the header file	<ufm.h>.

									PPPPaaaaggggeeee 2222
[ Back ]
 Similar pages
Name OS Title
ufmGetTransformedBitmap IRIX get a transformed character bitmap
ufmFreeBitmap IRIX free a character bitmap
glBitmap Tru64 draw a bitmap
glbitmap IRIX draw a bitmap
bitmap Linux Define a new bitmap from a Tcl script
ipaint IRIX Paint using bitmap images as brushes
MrmFetchBitmapLiteral IRIX Fetches a bitmap literal from a hierarchy
MrmFetchBitmapLiteral Tru64 Fetches a bitmap literal from a hierarchy
MrmFetchBitmapLiteral HP-UX Fetches a bitmap literal from a hierarchy
pbm IRIX portable bitmap file format
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service