Exemple #1
0
        public FontFace(Face *face)
        {
            _face      = face;
            FontFamily = Marshal.PtrToStringAnsi(face->family_name) !;
            var style = (StyleFlags)face->style_flags;

            if (style == 0)
            {
                Style = FontStyle.Regular;
            }
            if ((style & StyleFlags.Italic) == StyleFlags.Italic)
            {
                Style |= FontStyle.Italic;
            }
            if ((style & StyleFlags.Bold) == StyleFlags.Bold)
            {
                Style |= FontStyle.Bold;
            }
        }
Exemple #2
0
 public static extern Error FT_Load_Glyph(Face *face, uint glyph_index, LoadFlags load_flags);
Exemple #3
0
 public static extern Error FT_Set_Pixel_Sizes(Face *face, uint pixel_width, uint pixel_height);
Exemple #4
0
 public static extern Error FT_Set_Char_Size(Face *face, IntPtr char_width, IntPtr char_height, uint horz_resolution, uint vert_resolution);
Exemple #5
0
 public static extern Error FT_Request_Size(Face *face, IntPtr req);
Exemple #6
0
 public void Dispose()
 {
     FT.FT_Done_Face(_face);
     _face = null;
 }
Exemple #7
0
 public static extern Error FT_Get_Glyph_Name(Face *face, uint glyph_index, IntPtr buffer, uint buffer_max);
Exemple #8
0
 public static extern Error FT_Get_Kerning(Face *face, uint left_glyph, uint right_glyph, KerningMode kern_mode, out FTVector26Dot6 akerning);
Exemple #9
0
 public static extern Error FT_Attach_Stream(Face *face, IntPtr parameters);
Exemple #10
0
 public static extern Error FT_Attach_File(Face *face, string filepathname);
Exemple #11
0
 public static extern Error FT_Open_Face(IntPtr library, IntPtr args, int face_index, out Face *aface);
Exemple #12
0
 public static extern Error FT_New_Memory_Face(IntPtr library, IntPtr file_base, int file_size, int face_index, out Face *aface);
Exemple #13
0
 public static extern Error FT_New_Face(IntPtr library, string filepathname, int face_index, out Face *aface);
Exemple #14
0
        public Mesh
        (
            uint?mPrimitiveTypes = null,
            uint?mNumVertices    = null,
            uint?mNumFaces       = null,
            System.Numerics.Vector3 *mVertices   = null,
            System.Numerics.Vector3 *mNormals    = null,
            System.Numerics.Vector3 *mTangents   = null,
            System.Numerics.Vector3 *mBitangents = null,
            Face *mFaces                       = null,
            uint?mNumBones                     = null,
            Bone **mBones                      = null,
            uint?mMaterialIndex                = null,
            AssimpString?mName                 = null,
            uint?mNumAnimMeshes                = null,
            AnimMesh **mAnimMeshes             = null,
            uint?mMethod                       = null,
            Silk.NET.Maths.Box3D <float>?mAABB = null
        ) : this()
        {
            if (mPrimitiveTypes is not null)
            {
                MPrimitiveTypes = mPrimitiveTypes.Value;
            }

            if (mNumVertices is not null)
            {
                MNumVertices = mNumVertices.Value;
            }

            if (mNumFaces is not null)
            {
                MNumFaces = mNumFaces.Value;
            }

            if (mVertices is not null)
            {
                MVertices = mVertices;
            }

            if (mNormals is not null)
            {
                MNormals = mNormals;
            }

            if (mTangents is not null)
            {
                MTangents = mTangents;
            }

            if (mBitangents is not null)
            {
                MBitangents = mBitangents;
            }

            if (mFaces is not null)
            {
                MFaces = mFaces;
            }

            if (mNumBones is not null)
            {
                MNumBones = mNumBones.Value;
            }

            if (mBones is not null)
            {
                MBones = mBones;
            }

            if (mMaterialIndex is not null)
            {
                MMaterialIndex = mMaterialIndex.Value;
            }

            if (mName is not null)
            {
                MName = mName.Value;
            }

            if (mNumAnimMeshes is not null)
            {
                MNumAnimMeshes = mNumAnimMeshes.Value;
            }

            if (mAnimMeshes is not null)
            {
                MAnimMeshes = mAnimMeshes;
            }

            if (mMethod is not null)
            {
                MMethod = mMethod.Value;
            }

            if (mAABB is not null)
            {
                MAABB = mAABB.Value;
            }
        }
Exemple #15
0
 public static extern Error FT_Load_Char(Face *face, uint char_code, LoadFlags load_flags);
Exemple #16
0
 public static extern void FT_Set_Transform(Face *face, IntPtr matrix, IntPtr delta);
Exemple #17
0
 public static extern Error FT_Reference_Face(Face *face);
Exemple #18
0
 public static extern Error FT_Get_Track_Kerning(Face *face, IntPtr point_size, int degree, out IntPtr akerning);
Exemple #19
0
 public static extern Error FT_Done_Face(Face *face);
Exemple #20
0
 public static extern uint FT_Get_Char_Index(Face *face, uint charcode);
Exemple #21
0
 public static extern Error FT_Select_Size(Face *face, int strike_index);