Example #1
0
    //TODO: ensure generated bitmaps with transparent backgrounds applied actually work in opengl scene
    public GfxTextNode2D()
    {
        gfx_model = MatrixCollection.CreateInitialMatricies();

        Scale    = Vector3.One;
        Position = Vector3.Zero;
        Offset   = Vector2.Zero;
        text     = string.Empty;

        Font      = new Font("Times New Roman", 12.0f);
        ForeColor = Color.Yellow;
        BackColor = Color.Transparent;
    }
        static string AddMatrixParams(string url, object values)
        {
            int    index = url.LastIndexOf('?');
            string path;
            string queryString;

            if (index == -1)
            {
                path        = url;
                queryString = "";
            }
            else
            {
                path        = url.Substring(0, index);
                queryString = url.Substring(index);
            }

            var matrixParams = new MatrixCollection(values);

            return(path + matrixParams + queryString);
        }