i am trying to uderstud...

Hello. Learning c++ i am trying to understud the "class SFML_API Glyph" of the code what is mean?

1
2
3
4
5
6
7
8
class SFML_API Glyph
{
public :
    Glyph() : Advance(0) {}
    int       Advance;   ///< Offset to move horizontically to the next character
    IntRect   Rectangle; ///< Bounding rectangle of the glyph, in relative coordinates
    FloatRect TexCoords; ///< Texture coordinates of the glyph inside the bitmap font
};
\

Also "class SFML_API Font : public Resource<Font>" and "namespace priv{class FontLoader;}" in code bellow.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
namespace sf
{
class String;
namespace priv
{
class FontLoader;
}
class SFML_API Font : public Resource<Font>
{
public :
    Font();
    bool LoadFromFile(const std::string& Filename, unsigned int CharSize = 30, const Unicode::Text& Charset = ourDefaultCharset);
    bool LoadFromMemory(const char* Data, std::size_t SizeInBytes, unsigned int CharSize = 30, const Unicode::Text& Charset = ourDefaultCharset);
    unsigned int GetCharacterSize() const;
    const Glyph& GetGlyph(Uint32 CodePoint) const;
    const Image& GetImage() const;
    static const Font& GetDefaultFont();
private :
    friend class priv::FontLoader;
    static Uint32 ourDefaultCharset[]; ///< The default charset (all printable ISO-8859-1 characters)
    Image                   myTexture;  ///< Texture holding the bitmap font
    unsigned int            myCharSize; ///< Size of characters in the bitmap font
    std::map<Uint32, Glyph> myGlyphs;   ///< Rendering settings of each character (glyph)
};


Thank's
Jim
Hello. Learning c++ i am trying to understud the "class SFML_API Glyph" of the code what is mean?


It's a class declaration of an API, the comments suggest what each method does.
Last edited on
Thank's a lot
Jim
Topic archived. No new replies allowed.