Getting DirectWrite Direct2D Glyph's outline information

Started by
9 comments, last by kaush 13 years, 11 months ago
Quote:Original post by Anon Mike
You're not even using iGlyphCntr. That code is calling GetGlyphRunOutline multiple times with the exact same data.

What you need is something like:
hr = glyphRun->fontFace->GetGlyphRunOutline(        glyphRun->fontEmSize,        glyphRun->glyphIndices + iGlyphCntr,  // current glyph        glyphRun->glyphAdvances + (glyphRun->glyphAdvances ? iGlyphCntr : 0),  // if glyphAdvances in NULL leave it that way        glyphRun->glyphOffsets + (glyphRun->glyphOffsets ? iGlyphCntr : 0),  // same        1,  // one glyph only        glyphRun->isSideways,        glyphRun->bidiLevel % 2,        pSink);


This will get the outline info for just one glyph. Do whatever you want with that info. Then move on to the next one.


i am extremely sorry for my stupid mistake, i pasyted the wrong code while editing.
yes boss you are right i got the glyph data by same technique.
Now do we have better solution, because its very time consuming.

This topic is closed to new replies.

Advertisement