Esempio n. 1
0
        public static PyImage CreateImage(int width, int height, ImageType type)
        {
            string size = width.ToString() + "," + height.ToString();
            string id   = "";

            switch (type)
            {
            case ImageType.RGBA:
                id = Base.ExecuteMethod("create_image", "RGBA," + size);
                break;

            case ImageType.BGRA:
                id = Base.ExecuteMethod("create_image", "BGRA," + size);
                break;

            case ImageType.PRGBA:
                id = Base.ExecuteMethod("create_image", "PRGBA," + size);
                break;
            }
            return(new PyImage(id, type));
        }
Esempio n. 2
0
        public static Tmo CreateTmo()
        {
            string id = Base.ExecuteMethod("create_tmo", "");

            return(new Tmo(id));
        }
Esempio n. 3
0
        public static PyImage LoadHdrImage(string filename)
        {
            string id = Base.ExecuteMethod("load_hdr_image", filename);

            return(new PyImage(id, ImageType.PRGBA));
        }
Esempio n. 4
0
        public PyBGRAImage convert_to_bgra()
        {
            string id = Base.ExecuteMethod("convert_to_bgra", this.ID);

            return(new PyBGRAImage(id));
        }