Willkommen ~Gast!
Registrieren || Einloggen || Hilfe/FAQ || Staff
Probleme mit der Registrierung im Forum? Melde dich unter registerEin Bild.
Autor Beitrag
000
01.09.2002, 13:33
Marcelo



Hallo,
ich nutze die Funktion "getglyphoutline".
Es wäre schön, wenn mir einer helfen könnte, mein Wunsch umzusetzen. Ich habe in einer Variable den Buchstaben stehen. In einer anderen den Schriftartenname. Jetzt möchte ich mit der Funktion die Vektorinformationen einer Schriftart zu diesem Buchstaben auslesen. Diese Information müßten erstmal in einer Textdatei gespeichert werden, damit ich diese Daten dann in CNC-Code umwandeln kann.
Wäre super, wenn mir einer helfen würde.
Oder gibts irgendwo eine Hilfe?
Oder vielleicht kann mir jemand die Mailadresse zu einem guten C++-Coder geben. Ist wichtig.

MfG
Marcel

--

zum Seitenanfang zum Seitenende Profil || Suche
001
03.09.2002, 19:57
static_caster



ich weiß zwar nicht, was du machen willst, aber ich helf dir ehrlich gerne.

--

zum Seitenanfang zum Seitenende Profil || Suche
002
04.09.2002, 14:18
[RMen]OneStone



Hmm, wenn du dich mal zu Programmiersprache / API äußern würdest, würd' ich dir auch helfen. =)

--

georg-wicherski@pixel-house.net | http://www.pixel-house.net/ - Coding Resource| http://www.google.de/

zum Seitenanfang zum Seitenende Profil || Suche
003
04.09.2002, 17:27
theDon



Zitat:
[RMen]OneStone postete
Hmm, wenn du dich mal zu Programmiersprache / API äußern würdest, würd' ich dir auch helfen. =)

programmiersprache schein wohl c++ zu sein

--

\o tanz den naziprau! o/

And more than ever, I hope to never fall,
Where enough is not the same it was before

zum Seitenanfang zum Seitenende Profil || Suche
004
04.09.2002, 17:30
Marcelo



Zitat:
theDon postete
Zitat:
[RMen]OneStone postete
[i]Hmm, wenn du dich mal zu Programmiersprache / API äußern würdest, würd' ich dir auch helfen. =)

programmiersprache schein wohl c++ zu sein[/i]

richtig! ich brauche immer noch Hilfe.

MfG
Marcel

--

zum Seitenanfang zum Seitenende Profil || Suche
005
04.09.2002, 17:48
[RMen]OneStone



MSDN:

GetGlyphOutline
The GetGlyphOutline function retrieves the outline or bitmap for a character in the TrueType font that is selected into the specified device context.

DWORD GetGlyphOutline(
HDC hdc, // handle to device context
UINT uChar, // character to query
UINT uFormat, // format of data to return
LPGLYPHMETRICS lpgm, // pointer to structure for metrics
DWORD cbBuffer, // size of buffer for data
LPVOID lpvBuffer, // pointer to buffer for data
CONST MAT2 *lpmat2 // pointer to transformation matrix structure
);

Parameters
hdc
Handle to the device context.
uChar
Specifies the character for which data is to be returned.
uFormat
Specifies the format of the data that the function retrieves. Use one of the following values: Value Meaning
GGO_BITMAP The function retrieves the glyph bitmap. For information about memory allocation, see the following Remarks section.
GGO_NATIVE The function retrieves the curve data points in the rasterizer's native format and uses the font's design units. When this value is specified, any transformation specified in the lpMatrix parameter is ignored.
GGO_METRICS The function only retrieves the GLYPHMETRICS structure specified by lpgm. The other buffers are ignored. This value affects the meaning of the function's return value upon failure; see the following Return Value section.
GGO_GRAY2_BITMAP The function retrieves a glyph bitmap that contains 5 levels of gray.
GGO_GRAY4_BITMAP The function retrieves a glyph bitmap that contains 17 levels of gray.
GGO_GRAY8_BITMAP The function retrieves a glyph bitmap that contains 65 levels of gray.

Note that, for the GGO_GRAYn_BITMAP values, the function retrieves a glyph bitmap that contains n^2+1 (n squared plus one) levels of gray.

lpgm
Pointer to the GLYPHMETRICS structure describing the placement of the glyph in the character cell.
cbBuffer
Specifies the size of the buffer where the function is to copy information about the outline character. If this value is zero, the function returns the required size of the buffer.
lpvBuffer
Pointer to the buffer where the function is to copy information about the outline character. If this value is NULL, the function returns the required size of the buffer.
lpmat2
Pointer to a MAT2 structure specifying a transformation matrix for the character.
Return Values
If GGO_BITMAP, GGO_GRAY2_BITMAP, GGO_GRAY4_BITMAP, GGO_GRAY8_BITMAP, or GGO_NATIVE is specified and the function succeeds, the return value is greater than zero; otherwise, the return value is GDI_ERROR. If one of these flags is specified and the buffer size or address is zero, the return value specifies the required buffer size, in bytes.

If GGO_METRICS is specified and the function fails, the return value is GDI_ERROR.

Windows NT: To get extended error information, callGetLastError.

Remarks
The glyph outline returned by the GetGlyphOutline function is for a grid-fitted glyph. (A grid-fitted glyph is a glyph that has been modified so that its bitmapped image conforms as closely as possible to the original design of the glyph.) If an application needs an unmodified glyph outline, it can request the glyph outline for a character in a font whose size is equal to the font's em unit. The value for a font's em unit is stored in the otmEMSquare member of the OUTLINETEXTMETRIC structure.

The glyph bitmap returned by GetGlyphOutline when GGO_BITMAP is specified is a doubleword-aligned, row-oriented, monochrome bitmap. When GGO_GRAY2_BITMAP is specified, the bitmap returned is a doubleword-aligned, row-oriented array of bytes whose values range from 0 to 4. When GGO_GRAY4_BITMAP is specified, the bitmap returned is a doubleword-aligned, row-oriented array of bytes whose values range from 0 to 16. When GGO_GRAY8_BITMAP is specified, the bitmap returned is a doubleword-aligned, row-oriented array of bytes whose values range from 0 to 255.

An application can rotate characters retrieved in bitmap format by specifying a 2-by-2 transformation matrix in the lpMatrix parameter.

QuickInfo
Windows NT: Requires version 3.1 or later.
Windows: Requires Windows 95 or later.
Windows CE: Unsupported.
Header: Declared in wingdi.h.
Import Library: Use gdi32.lib.
Unicode: Implemented as Unicode and ANSI versions on Windows NT.

See Also
Fonts and Text Overview, Font and Text Functions, FORM_INFO_1, GetOutlineTextMetrics, GLYPHMETRICS, MAT2, OUTLINETEXTMETRIC, POINT

--

georg-wicherski@pixel-house.net | http://www.pixel-house.net/ - Coding Resource| http://www.google.de/

zum Seitenanfang zum Seitenende Profil || Suche