Extensions/ImageGlass.Core/Img.cs

(开头部分) 4KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

/*
 * imaeg - generic image utility in C#
 * Copyright (C) 2010  ed <tripflag@gmail.com>
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License v2
 * (version 2) as published by the Free Software Foundation.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, refer to the following URL:
 * http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
 */
using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;

namespace ImageGlass.Core
{
    public class Img
    {
        Image bm;
        string path;
        bool _finished, _failed;
        public Img(string path)
        {
            this.path = path;
            Dispose();
            //Program.dbg("Img instance created");
        }

        /// <summary>
        /// Load image from file
        /// </summary>
        /// <param name="root">Parent folder for instance path</param>
        public void Load(string root)
        {
            Image im = null;
            try
            {
                im = Interpreter.load(root + path);
            }
            catch { }
            Set(im);
        }

        /// <summary>
        /// Load image from file, applying filter filter
        /// </summary>
        /// <param name="root">Parent folder for instance path</param>
        /// <param name="filter">The ImgFilter to pass image through</param>
        public void Load(string root, ImgFilter filter)
        {
            Image im = null;
            try
后面还有 106 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。